Jump to content
Sign in to follow this  
Kreator

Cut ennemy fingers script

Recommended Posts

Hi there, I'm looking for a script that will allow a specific faction (FIA in my case) to cut one of the finger of a dead body from another faction (it must be dead).

I spend my afternoon looking and turning around but I can't find a clue, maybe someone can help me ?

Cheers ;)

Share this post


Link to post
Share on other sites

Here's a simple pseudo method. There may be some syntax errors as i can't test it atm and I'm pretty rusty too. At any rate...

//Add to the init line of the unit. The one who's finger you want to cut off. 
this addAction [
     "Cut Off Finger", 
     {hint "The finger has been stored in your bags"}, 
     [], 
     6, 
     true, 
     true, 
     "", 
     "!alive _target && {faction _this == 'IND_G_F'}" //condition for action to appear
];

Edited by Iceman77

Share this post


Link to post
Share on other sites

If you want to see the finger missing from the body , there's no possible way .

For just a finger in front of you maybe an addaction opening a gui menu with an imported finger image ... :j:

Share this post


Link to post
Share on other sites

Yup, i'll try your script tomorrow Iceman, but i've to give the finger to a pnj in order to validate the mission how can i script that ?

Share this post


Link to post
Share on other sites

You essentially want to cut the finger off of a corpse and give it to another person back at base to complete the objective? I hope I'm on target here...

dead guy

this addAction [
     "Cut Off Finger", 
     {hint "You've cut off the finger and stored in your bags.";gotFinger=true;publicVariable "gotFinger";}, 
     [], 
     6, 
     true, 
     true, 
     "", 
     "!alive _target && {faction _this == 'IND_G_F'}" //wait until the unit is dead and run a faction check before the action may be used 
];

Officer back at base

this addAction [
     "Give The Finger To The Officer", 
     {hint "You've given the finger to the officer. Objective completed."; objDone=true; publicVariable "objDone";}, 
     [], 
     6, 
     true, 
     true, 
     "", 
     "gotFinger" //wait for the variable -gotFinger- to become true before the action is visible
];

Obviously you can use your own variables and even run different code. ie; for updating your briefing / objectives. Hope that helps.

Edited by Iceman77

Share this post


Link to post
Share on other sites

Sorry for using the world "pnj", its NPC in english and pnj in frencch, but thanks a lot, I'll give it a try this morning, i'll keep you posted :)

EDIT : Working like a charm, thanks a lot bro :D

Too bad that you're that far i would offer you a beer xD

Edited by Kreator
Working :D

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×