Home   Help Search Login Register  

Author Topic: [SOLVED]Action in Vehicle  (Read 1555 times)

0 Members and 1 Guest are viewing this topic.

Offline Mad Pup

  • One Who Asks A Lot.
  • Members
  • *
  • OFPEC Is Awesome
[SOLVED]Action in Vehicle
« on: 09 Mar 2012, 02:42:14 »
I was wondering if it is possible to have a player use an action while in a vehicle.

Example:
Sport Car Yellow = car1
Civillian = civ1

civ1 is in car1

Code: [Select]
civ1 addaction ["SET UP","set.sqs"]He has to get out of the vehicle in order to see/execute this action.

Code: [Select]
car1 addaction ["SET UP","set.sqs"]
I have not tried this, but would this give this action to anybody in the car?
THANKS!

-Mad Pup
« Last Edit: 11 Mar 2012, 04:28:28 by Mad Pup »
"The object of war is not to die for your country, but to make the other poor bastard die for his" - General Patton
[SH]MadPup
[SH]Squad

Offline Gruntage

  • Missions Depot
  • Administrator
  • *****
  • How do I get outta this chickensh*t outfit?
Re: Action in Vehicle
« Reply #1 on: 09 Mar 2012, 09:03:10 »
Code: [Select]
car1 addaction ["SET UP","set.sqs"]
In theory this should give the action to anyone in the car. A car radio script that I found has:

Code: [Select]

_veh = _this select 0

_veh addaction ["Turn music player on", "PlayRoadMusic.sqs"]


So the 'action' is added to the vehicle, which means that any of the occupants can use the action.
"But one thing I can tell you from not just OFP but life in general:  criticism is directly proportional to quality. The more criticism a mission receives, the better the outcome" - macguba

Offline Mad Pup

  • One Who Asks A Lot.
  • Members
  • *
  • OFPEC Is Awesome
Re: Action in Vehicle
« Reply #2 on: 09 Mar 2012, 21:45:02 »
Sweet thanks Gruntage!

-Mad pup
"The object of war is not to die for your country, but to make the other poor bastard die for his" - General Patton
[SH]MadPup
[SH]Squad