Quote: --- Original message by: Halonimator
It doesn't seem possible but maybe you guys know something... You probably don't.
Is this code for something?
Wish there was a more readily available video showing the teleport on youtube. I think I remember the thing scaling down or something before doing the teleport. If you're going the script route like
ASCENDANTJUSTICE mentioned, you have access to (object_set_scale ) to simulate this. I guess for better results you could seperate the limbs as models and attach them individually to the ai so that the script can scale each part separately. idk. Most important to have set up though would be a script that checks for a trigger. That would be up to you to decide how you'd like it set up- ai status = 6 for at least a minute straight, health less than 30%, etc. Once you've got that, throw an (effect_new_on_object_marker ) and a (custom_animation ) on it as well so it looks cool. Then after however long into the animation, use (object_teleport ) to actually move the ai to whatever cutscene flag you placed. Ways around using a cutscene flag would be to create a custom vehicle to be used as the teleport destination, and have the ai (unit_enter_vehicle ) using a nonexistant, empty seat string "noseat"- this is actually how you can force a unit to exit a vehicle instantly without playing his exit animation, TMYK.
Some old video demoing this kind of teleport.
Edit- The noseat thing only works if the unit is already inside a vehicle. No idea what was done in the video. Never saved the script.
For a less scripty approach, you could probably find some success with ai command lists.

They already cover forcing an animation as well as inducing the teleport. Plus they might be able to be automatically run by ai by having their platoon maneuver when a certain portion of them are dead or something. I don't play with command lists much so if that doesn't auto trigger, it can still be called by script using (ai_command_list ). Now here's something to try- have a custom animation actually cause the unit to distort its mesh ingame. Skinning parts of the mesh's vertices to extra nodes should be able to warp the mesh in realtime when those nodes are animated, something like-

Of course, I'm no modeler and the scope of my abilities doesn't extend much further than boxes. Who knows how practical something like this even could be, considering that would end up using a LOT of nodes. Would be cool though, and might be able to be used to cause the unit to scale or morph ingame.
Edited by A Juicy Frank on Mar 23, 2016 at 10:16 PMEdited by A Juicy Frank on Mar 23, 2016 at 10:24 PM