Forum

> > Stranded II > Scripts > Molotov-style script. Possible?
Forums overviewStranded II overview Scripts overviewLog in to reply

English Molotov-style script. Possible?

5 replies
To the start Previous 1 Next To the start

old Molotov-style script. Possible?

pupp3tStudios
User Off Offline

Quote
Alright, so I'm working on Pupp3t's Mod, and I thought of an idea.
Is it possible that you can throw the proposed bottle at a unit so it can obtain the "flame" state, and the "flame" state can spread to surrounding objects/units/items via the blast radius?

old Re: Molotov-style script. Possible?

Hurri04
Super User Off Offline

Quote
oh yeah, with this command at least the loop for all the objects inrange wouldn't be necessary any more.

though the description says that it only works for objects so you'd still need to loop the units and the items if you also want them to catch fire.

old Re: Molotov-style script. Possible?

Hurri04
Super User Off Offline

Quote
actually you just have to use it twice, for the units and for the items (since you can use s2 cmd areal_state for the objects).
all the repetition is done by the s2 cmd loop command.

to get the ID of the current unit/item you can use the command s2 cmd loop_id.

in order to have something to compare with I'd advise you to use the s2 cmd create command and create e.g. a flag-info at the position of the impact, then use its ID as the second ID in the s2 cmd inrange command.

after all the loops are done you can delete the flag again with s2 cmd free.
To the start Previous 1 Next To the start
Log in to reply Scripts overviewStranded II overviewForums overview