Jump to content

Need help spawning an event container.


Recommended Posts

Heya folks,

 

I've been trying to spawn a container along with the aliens (Wild Wasteland encounter) north of the Horowitz Farmstead.

I've added a custom container, placed it next to the aliens, renamed the referance and added it to the event script

(VERT5AlienWWScript) but still it seems stubborn and simply won't spawn.

 

I was hoping one of you guys happen to know why (or possibly see a flaw in the script).

 

Any help would be very much apreciated ^^

 

 

Scn VERT5AlienWWScript
; - Jorge

Short bPlayerEnters
Short bEventFound
Short bEventFinished
Short iCount

Float fTimer



Begin OnLoad

If bEventFinished != 1
Set bPlayerEnters to 1
Else
Disable
MarkForDelete
Endif

End


Begin GameMode

If bEventFinished != 1
If bPlayerEnters == 1
If Player.HasPerk WildWasteland == 1
If bEventFound != 1
If GetDistance Player >= 6000 || VERT5AlienShipREF.GetDisabled != 1
Set fTimer to ( fTimer + GetSecondsPassed )
If iCount < 1
VERT5AlienShipREF.Enable
Set iCount to 1
Elseif iCount == 1 && fTimer >= 0.5
VERT5AlienCaptainREF.Enable
Set iCount to 2
Return
Elseif iCount == 2 && fTimer >= 1
VERT5Alien01REF.Enable
Set iCount to 3
Return
Elseif iCount == 3 && fTimer >= 1.5
VERT5Alien02REF.Enable
Set bEventFound to 1
Set iCount to 4
Return
Elseif iCount == 4 && fTimer >= 2
VERT5StarkCrateREF.Enable
Set bEventFound to 1
Set iCount to 0
Return

Endif
Endif
Else
If Player.GetItemCount 00StarkWeapTheFirelance >= 1
Set bEventFinished to 1
Endif
Endif
Elseif Player.HasPerk WildWasteland != 1
If bEventFound != 1
If GetDistance Player >= 6000 || VERT5MercBossREF.GetDisabled != 1
Set fTimer to ( fTimer + GetSecondsPassed )
If iCount < 1
VERT5MercBossREF.Enable
Set iCount to 1
Elseif iCount == 1 && fTimer >= 0.5
VERT5Merc01REF.Enable
Set iCount to 2
Return
Elseif iCount == 2 && fTimer >= 1
VERT5Merc02REF.Enable
Set iCount to 3
Return
Elseif iCount == 3 && fTimer >= 1.5
VERT5Merc03REF.Enable
Set iCount to 4
Return
Elseif iCount == 4 && fTimer >= 2
VERT5Merc04REF.Enable
Set bEventFound to 1
Set iCount to 0
Return
Endif
Endif
Else
If Player.GetItemCount WeapNVGaussRifleUnique >= 1
Set bEventFinished to 1
Endif
Endif
Endif
Endif
Endif

End

 

 

 

Ps: Also, does anyone know how to end the event after picking up multiple items instead of just the one?

Edited by Guest
Link to comment
Share on other sites

You forgot to delete "Set bEventFound to 1" in the elseif block just before your own. As soon as bEventFound is set, "If bEventFound != 1" prevents the block from running again and will end the event instead.

 

As for ending the event after picking up multiple items, just add some additional conditions to "If Player.GetItemCount 00StarkWeapTheFirelance >= 1", and separate them by || (or-operators).

Link to comment
Share on other sites

Oh wow, I must've missed that bEventFound line =/ Thanks! ^^

 

I have tried duplicating the If player.GetItemCount 00StarkWeapTheFirelance >=1 both using the || seperators and using new lines, but the script wouldn't save (and the GECK doesn't show script errors =/).

 

 

Else
If Player.GetItemCount WeapAlienBlaster >= 1
Elseif
If Player.GetItemCount 00StarkWeapTheFirelance >= 1
Elseif
If Player.GetItemCount 00StarkArmor >= 1
Elseif
If Player.GetItemCount 00StarkGlasses >= 1
Elseif
If Player.GetItemCount 00StarkHeadWrap >= 1
Set bEventFinished to 1

 

 

 

Else
If Player.GetItemCount WeapAlienBlaster >= 1 || If Player.GetItemCount 00StarkWeapTheFirelance >= 1 || If Player.GetItemCount 00StarkArmor >= 1 || If Player.GetItemCount 00StarkGlasses >= 1 || If Player.GetItemCount 00StarkHeadWrap >= 1
Set bEventFinished to 1

 

 

And sorry for al the questions, I'm kinda noobish when it comes to scripting =P

 

 

Edit: (Second spoiler) Deleted the If's of the seperated lines following the first line, that seems to have done it.

Edited by Guest
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...