Jump to content
Sign in to follow this  
Cryptdik

Multiplayer Animations

Recommended Posts

Looking to make simple corpses in COOP/MP missions. In SP I just used something like 

this switchMove "KIA_gunner_standup01"; this setdamage 1

Works fine, but when it comes to Multiplayer it gets a bit more difficult apparently.


SyncSwitchMove = {
	if (isDedicated) exitwith {};

	private ["_player", "_anim"];

	_player = param [0,objNull];
	_anim = param [1,""];

	_player switchMove _anim;
};

 

Tried calling it with [corpse1,"KIA_gunner_standup01"] remoteExec ["SyncSwitchMove", 0];

This doesn't work. What do I have wrong or is there an easier way?

Share this post


Link to post
Share on other sites
9 hours ago, Cryptdik said:

but when it comes to Multiplayer it gets a bit more difficult apparently

 

How?

Share this post


Link to post
Share on other sites
11 hours ago, Cryptdik said:

Looking to make simple corpses in COOP/MP missions. In SP I just used something like 

this switchMove "KIA_gunner_standup01"; this setdamage 1

Works fine, but when it comes to Multiplayer it gets a bit more difficult apparently.


SyncSwitchMove = {
	if (isDedicated) exitwith {};

	private ["_player", "_anim"];

	_player = param [0,objNull];
	_anim = param [1,""];

	_player switchMove _anim;
};

 

Tried calling it with [corpse1,"KIA_gunner_standup01"] remoteExec ["SyncSwitchMove", 0];

This doesn't work. What do I have wrong or is there an easier way?

 

 

Yes, it's hard to make that in MP. And I guess there are more than a single problem to obtain what you want!

Like you tried, you need to remoteExec a switchMove animation, because the effect is local, then only on player's PC (or server for an AI belonging to a group on server).

First test a current animation, something like:

if (local player) then {[player,"Acts_InjuredCoughRifle02"] remoteExec ["switchMove",0,true]}; // -2 for dedicated

Second, test with your specific animation but I'm not sure the setdamage 1 will not override it (but if ok in SP...)

Third, keep on mind the server/clients exchanges. I've been often disappointed with remote execution for some "heavy" sequences and switchmove doesn't help to do it light. There is no error.. but sometimes no animation if too busy.

 

I hope you'll find more constructive help. The topic is interesting.

 

 

  • Like 1

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  

×