Get money for killing AI

Get money for killing AI

« posted: Apr 24, 2018, 06:40 PM »
Is there a way to get money for killing AI ?
  • Offline Mokey
  • Fractured Wasteland
  • Elite
  • ******
  • Posts: 606
  • Https://Fractured-Gaming.com

Re: Get money for killing AI

« Reply #1 posted: Apr 24, 2018, 07:08 PM »
Yes.
Posts once, edits post 40 times in 60 seconds. STUPID FAT FINGERS!
  • Offline AgentRev
  • Developer
  • Veteran
  • ******
  • Posts: 2490

Re: Get money for killing AI

« Reply #2 posted: Apr 25, 2018, 12:32 AM »
https://github.com/A3Wasteland/ArmA3_Wasteland.Altis/blob/dev/server/functions/fn_entityKilled.sqf#L23

Code: [Select]
[_entity, effectiveCommander _killer, effectiveCommander _presumedKiller] call A3W_fnc_serverPlayerDied;
[effectiveCommander _killer, 1000] call A3W_fnc_setCMoney;
};

Add the second line above and tweak the amount as you wish.

Re: Get money for killing AI

« Reply #3 posted: Apr 25, 2018, 08:13 PM »
Many thanks awesome !

Hmm must be me but  i am not getting any money when i kill a AI  :(

I have added a few other AI on a custom mission would i need to add a EH onto my AI for it to work ?

Re: Get money for killing AI

« Reply #4 posted: May 03, 2018, 06:02 PM »
Still no Joy any help would really be appreciated !
  • Offline Mokey
  • Fractured Wasteland
  • Elite
  • ******
  • Posts: 606
  • Https://Fractured-Gaming.com

Re: Get money for killing AI

« Reply #5 posted: May 06, 2018, 09:23 PM »
What is your issue, supply code snippets of what you have.
Posts once, edits post 40 times in 60 seconds. STUPID FAT FINGERS!

Re: Get money for killing AI

« Reply #6 posted: May 07, 2018, 09:47 AM »
OK solved  -- sorry i was not using the latest Version hence no A3W_fnc_setCMoney    ::)

Updated  and all works now !


What is the best way to show  a message that you just recived x amount ?

hintBroadcast ?  can i make it disappear within a few seconds ?