Home   Help Search Login Register  

Author Topic: a few more questions  (Read 438 times)

0 Members and 1 Guest are viewing this topic.

Offline Tim Pink

  • ECP Team &
  • Former Staff
  • ****
  • "Down with a bang and that'll be the end"
a few more questions
« on: 06 Jun 2003, 15:11:21 »
Hi again everyone, LCD, Macguba, Sui, Tomb
How r we this evening?

Ok my first question, when using the sidechat function can u change the identity that is at the beggining of the line?
eg
Bravo Black 1 : "your too far ahead stay back"
is there a way to change the Bravo black bit to anyhitng you want?

my second question is in relation to my never ending quest for the smokeshell and helo answer

i found this in the command reference

HasWeapon

Description : Indicates whether or not a unit is carrying a specific weapon type.

Syntax :unitName hasWeapon  "weaponName" unitName is the name of the unit to checkweaponName is the name of the weapon (need to have quotes!). For a list of weapons refer to the Weapon/Ammo List

Returns :TorF true indicates the unit has that weapon typefalse indicates the unit does not have that weapon type

Example :?(MyGuy hasWeapon  "M16"):MyGuy sidechat "I've got an M16!"

is there any way i could use this so that when you throw your smoke shell which is the only one you have the trigger returns false and this in turn sets the helo"S fuel to full and it comes to pick u up?

Thanx
"Whoever said nothing is impossible, never tried slamming a revolving door."

asmodeus

  • Guest
Re:a few more questions
« Reply #1 on: 06 Jun 2003, 15:26:30 »
Hey there!

For your first question, check out Toadlife's Custom Callsign Tutorial up there ^ in the ed depot.   :-*

2nd question

I think they are implementing it in snYpir's SP/MP support pack maybe...  It's definately doable..  (Maybe it would be easier with an eventhandler) I'm not too sure, maybe one of the other people will have the specifics on how to do this for ya!   ;)

Asmo

Offline macguba

  • Former Staff
  • ****
    • macguba's operation flashpoint page
Re:a few more questions
« Reply #2 on: 06 Jun 2003, 15:55:32 »
1.    The command you want is setGroupId ... check the old online command reference for details.     Search the FAQ for how to get "Papa Bear".    Use toadlife's tute to change Papa Bear to something else.     Use the command setIdentity to give a name to a particular unit.      

However, if you want to give the group (or unit) a name to use in scripts, none of the above will help you.     Write in the init field of the group leader:-

grp1 = group this



2.   The answer to your never ending quest is to understand eventhandlers.    Once you understand how to use the eventhandler "fired", everything else will fall into place.  :)  

The hasWeapon method you have identified might work in principle, except that smokeshells - I think - are ammo and not weapons.    Worth a try though, something like

? not (MyGuy hasWeapon "smokeshellred"): MyGuy sidechat "Smoke out!"

that's only a guess though.
Plenty of reviewed ArmA missions for you to play