Jump to content
Sign in to follow this  
andysim

Command for cam.sqs

Recommended Posts

Hi im going to need to write a short script that will exec a camera script, when an enemy unit fires one shot from his weapon but cant find the a command in the 1.85 command referance.

Please help.

Share this post


Link to post
Share on other sites

What I am trying to do is have an enemy unit fire on my unit and just as he does a camera script cuts in and I see my unit get shot , then use a slow-mo to see my unit falling to his death. I know how to script a cutscene and will use

"enemyunit dofire Myunit" and so. How do I get the cutscene to start when the first shot is fired?.

Please help.

Andrew

Share this post


Link to post
Share on other sites

You could save the ammount of ammo from the enemy unit

into a variable.

ammoA = enemyunit ammo "magazinename"

Then you create a trigger where you will start your script

from.

condition: ammoA > enemyunit ammo "magazinname"

And here is the syntax explanation (taken from the official comref).

</span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Code Sample </td></tr><tr><td id="CODE">unit ammo magazine

Operand types:

unit: Object

magazine: String

Type of returned value:

Number

Description:

Count how many shots are left for given magazine type.

Example:

player ammo "M16"

<span id='postcolor'>

~S~ CD

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  

×