Home   Help Search Login Register  

Author Topic: SetPos a trigger!?!  (Read 1041 times)

0 Members and 1 Guest are viewing this topic.

Offline Captain Crunch

  • Members
  • *
SetPos a trigger!?!
« on: 04 Jun 2003, 14:20:49 »
Hi amigos! :afro:

  I'm wondering if it's possible to fix a trigger to a moving object.

For example a "PlaneFire" which is fixed on "MyPlane", "MyPlane" crashes, "PlaneFire" is lit and if anyone gets close to "PlaneFire", they take dammage.

  I got the script working fine, but I can't position the trigger. It always stays to its original Editor position.

Can anyone help me, this would be great and nice! 8)



   c    ru   n   c    h
Back to the forest!

Offline macguba

  • Former Staff
  • ****
    • macguba's operation flashpoint page
Re:SetPos a trigger!?!
« Reply #1 on: 04 Jun 2003, 14:25:11 »
Yes it is.   Name the trigger and have a looping script (or cycling gamelogic)

trigger1 setpos getpos myplane
Plenty of reviewed ArmA missions for you to play

Offline Messiah

  • Honourary OFPEC Patron & Drinking Buddy of Wolfsbane
  • Honoured Contributor
  • ***
  • OFPEC Veteran
    • Project UK Forces
Re:SetPos a trigger!?!
« Reply #2 on: 04 Jun 2003, 14:29:22 »
well.... make a trigger which checks the damage of the plane...

Code: [Select]
not(alive plane)
then make the fire trigger thing (u've made it so it kills yeah?) and name the trigger whatever u want... Trig_1 prehaps (original hey)

then for the onactivation of the trigger which checks if the plane is dead, write:

Code: [Select]
Trig_1 setpos (getpos plane)
now... one problem that could occur is that the plane bounces along, or dies in mid air... so maybe add to the trigger the conditon:

Code: [Select]
(getPos plane select 2 >0)
which will make sure its on the ground before the trigger is moved to the plane.

hope that helps a little  ;)
Proud Member of the Volunteer Commando Battalion

Offline Messiah

  • Honourary OFPEC Patron & Drinking Buddy of Wolfsbane
  • Honoured Contributor
  • ***
  • OFPEC Veteran
    • Project UK Forces
Re:SetPos a trigger!?!
« Reply #3 on: 04 Jun 2003, 14:30:46 »
looking at mac's answer... combine the two replies and i think u'll be sorted :thumbsup:
Proud Member of the Volunteer Commando Battalion

Offline Captain Crunch

  • Members
  • *
Re:SetPos a trigger!?!
« Reply #4 on: 04 Jun 2003, 15:46:17 »
YEAH BABY!!!!!! :) ;) :D ;D :o 8)


   It works! :P

Thank You very much my friends!!!

Now that it works fine, lets make it better!

Messiah is right, the plane does, sometimes, bounce around on the ground. Any ways to fix this? How about to wait a little after the plane has crashed and then activate this script:

_X = (GetPos Plane) Select 0
_Y = (GetPos Plane) Select 1
_Z = (GetPos Plane) Select 2

#Loop
Plane SetPos [_X, _Y, _Z]
GoTo "Loop"


???

...actully...  ...let me check it! ::)


Oh and Messiah, yes I made so it kills. It's pretty nice too, it doesn't kill instantly but instead gives a bit dammage as long as the unit stays close to the fire. If You're interested, I'll give it to You.

Maybe I should post some of the scripts I've made but I'm not too sure about that. Maybe they are not worth wasting the site's place! If someone who knows the site pretty good and wants to try them, sorta have a second opinion.

Back to the forest!

Offline Messiah

  • Honourary OFPEC Patron & Drinking Buddy of Wolfsbane
  • Honoured Contributor
  • ***
  • OFPEC Veteran
    • Project UK Forces
Re:SetPos a trigger!?!
« Reply #5 on: 04 Jun 2003, 15:55:38 »
i'm using BAS's version of the fire script (taken from their chopper addons) so i'm sorted fella... as for submiting them... as long as they work as they should, then submit them - i used to be on the editors depot team, and trust me... if its worth putting up, then it will be.

glad i could have helped :thumbsup:
Proud Member of the Volunteer Commando Battalion