| 12-14-2003, 04:24 AM | #1 |
can someone make me a trigger so that if a player types: "effect 01 ____ create" (without the "") it crates a especial effect on the unit. (needs to be able to create most or all effects) the ____ means it could be any spell. 01 means on its head. BTW: what im aming 4 is like in koolers's revenge 4 RoC. when a player would type in "effect 01 purge create" it would make the purge effect on the unit's head. |
| 12-14-2003, 04:44 AM | #2 |
You'll need a big table of strings to enter and their corresponding model file paths... That's gonna be a royal pain, man. But have it so it sets up two arrays at start - one FXString() and one FXPath(). Keep the number of entries in the arrays as MaxFXIndex. Put the first 5 letters of each FX entry string into FXString and the actual paths of the models into FXPath. Then E - player types chat string matching "effect " as a substring C - A - for A = 1 to MaxFXIndex do: if substring(entered chat string, 8,12) = FXString(Integer A) then set Index = Integer A A - pick all units selected by triggering player and attach special effect to head of picked unit with model path FXPath(Index) Or something... |
| 12-14-2003, 01:03 PM | #3 |
i dont really know what reals are or how they work but cant you use real comparisons to do this ? it would be a much smaller trigger heres what i mean: this is a screen of the trigger to spawn any unit the player wants (NOTE this isnt my trigger) i uses real comparisons (i think) |
