OFPEC Forum
Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: FLBEE on 22 Apr 2004, 03:42:52
-
In a cutscene i want a guy to get shot in the face.
I can setdammage him, but the dammage textures show over all his body before he colapses.
Is there a way to get the dammage texture to show on his face like he got shot there?
thx
-
You could use custom faces for that: one with and one without
blood textures.
Off course you would need to setup a face addon, but that's
not too complicated anymore nowadays. Check out the addons
complete section at the official BIS forums for a thread being
called: custom faces (started by liquid_snake).
~S~ CD
-
just an idead...
mayhaps you could look in the particular addon for the texture of that units particular body part and then change thier face texture somehow
ie: i know the adf troops use have left leg right leg... etc defined as well as when they get damaged in that region....
so i dunno you could try that... like changing the units texture files somehow... like i said just an idea...
it'd probably be easier just to get him shot in the face...
-
If you played around with camcreate a bit, you could camcreate a bullet (one with no tracer, otherwise you get strange looking trails) at head level. You would probably have to adjust the variables some, but it should work.
To beta test, you could set up a camera with a setAcctime .5 and see where the bullet is impacting.
Heres an untested script that should get you started
_victim=targetname
_bullet="insertbulletnamehere"
;play with this value to change height
_iheight=1.75
;ensure target is standing
_victim setunitpos "up"
_dir=getdir _victim
_pos=getpos _victim
_px=_pos select 0
_py=_pos select 1
;Create bullet 2m front of target's head
_npx=_px+(2*(cos _dir))
_npy=_py+(2*(sin _dir))
_bullet camcreate [_npx,_npy,_iheight]
;Send bullet back towards target
_newdir=_dir-180
_xvel=(200*(cos _newdir)
_yvel=(200*(sin _newdir)
_bullet setvelocity [_xvel,_yvel,0]
exit
Don't know if it will work, and the cos/sin might be switched around, but give it a try...
-Grendel
-
THX! ;D
Ill give it a try soon.