Jump to content
Sign in to follow this  
cobra5000

Make a wounded unit to speak question

Recommended Posts

Do you know how i make a wounded unit to speak before the player kill him or let him die like those examples:

1. In "Manattan" from "Harvest Red" campaign, when Copper shoots Nikitin once, Nikiting make a wounded animation and speaks to Cooper.

2. In "Termination" from PMC campaign, Frost shoots Stranger, Stranger make a wounded animation and speaks and when he finish to speak, he died.

Share this post


Link to post
Share on other sites

I'm tried to find the script for wounded nikitin but i didn't found it and i looked at the unpbo mission but i didn't find this thing

Share this post


Link to post
Share on other sites

Hi!

I've looked it up (Manhattan)... It's pretty easy.

1. Place 2 of the same units. The one you are going to kill and his clone somewhere outside the map. The clone will be used for the animation once the original is dead.

2. Name them unit_alive and unit_dead (unit_dead is the one you place somewhere outside the map)

3. Create a trigger.

Size: 0x0

Activation: None, present

Condition: !(alive unit_alive)

On Activation: nul = execVM "deathScene.sqf";

4. Create "deathScene.sqf":

unit_dead allowDamage false; // Protect the clone
_pos = (getPos unit_alive); // position of the original
unit_alive setPos (getPos unit_dead); // move away the (dead) original
unit_dead setDir (getdir unit_alive);// set dir
_nic = [objNull, unit_dead, rPLAYMOVE, "adthpercmstpsraswrfldnon_NikitinDead"] call RE; // play animation
_nic = [objNull, unit_dead, rPLAYMOVE, "ActsPknlMstpSnonWnonDnon_TreatingInjured_NikitinDead"] call RE;
unit_dead setPos _pos; // exchange the original with the clone
["disableAI", [unit_dead]] call BIS_fnc_sceneSetBehaviour; // diable his ai
unit_dead setDammage 0.6; // make him bloody
sleep 3;
unit_dead allowDamage true; // allow damage again?

Code from Manhattan.

That's about it. :thumbsup:

Share this post


Link to post
Share on other sites

1. The animation of unit_dead didn't worked.

2. I didn't saw unit_dead speaks.

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  

×