OFPEC Forum
Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: bedges on 25 Oct 2007, 10:47:15
-
i have a mission here where i need to create a corpse. simple, you might think - just setdamage to 1, what's the problem?
the problem is that the above method creates a corpse that looks like it's been run over by an exploding lawnmower. what i need is a body that is 'dead' but unmarked.
what i have so far is a unit which has been given a "combatdead" switchmove, i've set the facemimic to stop the changing expressions, and i've set the face animation to stop him blinking. it looks splendid: the only problem now is that if you shoot the 'dead' loon, he says "ouch! stop that!"
any ideas?
-
createVehicle the unit and switchmove it.
This way you create an empty shell of a soldier looking dead, if you shoot it it bleeds but doesn't shout anything..
-
Hi all,
well, all animation figures are blinking.
createVehicle the unit and switchmove it.
Why didn't you write your code? ???
I did this
_soldier = "SoldierWB" createVehicle getmarkerpos "tankFactory"and got that
_soldier = "SoldierWB" createVehicle getmarkerpos "tankFactory" : ERROR local variable in global space
:(
Then I did this
_soldier = "SoldierWB" createVehicle getmarkerpos "tankFactory"; this PlayMove "CombatDead"and didn't get an ERROR. :good:
But the soldier didn't dy.
Here is my dead animation as zip file which I did for simular purpose.
Regards limmy3
Edit: attachment (Switch- PlayMove commands.Intro.zip) lost in the crash of 2009 - WEK
-
What happens if you use camCreate?
-
Why didn't you write your code?
Because I was answering to bedges and I know he knows what to do :D
And besides, you learn when trying to figure things out by yourself, not by someone telling you "do this, don't care why" :P
Where did you put your creation code?
The 'global space' suggests you used it in either a unit's init field or in a trigger where local variables (with the underscore, such as your _soldier) do not work.
As for the anim not working, use switchMove, not playMove.
Because some anims work with switchmove only, and it's possible that createVehicled unit doesn't comply with playmove..
Then I did this
Which makes no sense.
First you create a soldier referenced with variable _soldier and then you playMove something referenced with this.
If that code was in a trigger or in a unit's init field this refers to the trigger/unit, not the created soldier..
If you wish to use the trigger/unit's init field
someloon="SoldierWB" createVehicle someposition; someloon switchMove "combatdead"In a script executed from somewhere
_soldier = "SoldierWB" createVehicle someposition
_soldier switchMove "combatdead"
-
Hello,
And besides, you learn when trying to figure things out by yourself, not by someone telling you "do this, don't care why" :P
Sure but I never had the feeling that it was that easy with "do this, don't care why" :scratch:
Then I did this
Which makes no sense.
There's a lot more to clearn for me.
Finding your code would be playing lotto for me. :whistle:
Regards limmy3
-
Any of the above examples work for you?
-
i'm without my pc for the time being, so i'll give these suggestions a try when i am reunited with my love.
thanks meantime gents. :good:
-
If they you don't mind a single wound, you could camcreate a bullet inside them. They won't look all bloody, except where the bullet was, and they certainly won't blink.