Welcome!

Join our community of MMO enthusiasts and game developers! By registering, you'll gain access to discussions on the latest developments in MMO server files and collaborate with like-minded individuals. Join us today and unlock the potential of MMO server development!

Join Today!

How to send/spawn custom FSM to client?

Newbie Spellweaver
Joined
Mar 7, 2018
Messages
12
Reaction score
2
I need to change original brain_player_client.fsm in init_newBody.sqf to custom from server.
Original brain_player_client.fsm execute on client from client side addons.

Code:
[_id] spawnForClient compile "player execFSM '\dz\modulesDayZ\fsm\brain_player_client.fsm'";

I need to send custom fsm from server to client
like this

Code:
brainPlayerFSM = compile preprocessFileLineNumbers "scripts\fsm\brain_player_client.fsm";
[_id,brainPlayerFSM] spawnForClient {
 _brainPlayerFSM = _this select 1;
 player execFSM _brainPlayerFSM;
};

but it does not work

How do it?

THANX!
 
Newbie Spellweaver
Joined
May 28, 2017
Messages
95
Reaction score
23
Code:
brainPlayerFSM = compile preprocessFileLineNumbers "scripts\fsm\brain_player_client.fsm";
[_id,brainPlayerFSM] spawnForClient {
 _brainPlayerFSM = _this select 1;
 player execFSM _brainPlayerFSM;
};

Using this code, the player will read this like this:
Code:
player execFSM compile preprocessFileLineNumbers "scripts\fsm\brain_player_client.fsm";

And the usage of this function is:

Code:
(argumment) ExecFSM (file);


I don't know if has some way for do this... But you can continue to trying...
 
Newbie Spellweaver
Joined
Mar 7, 2018
Messages
12
Reaction score
2
Originally in init_newBody

[_id] spawnForClient compile "player execFSM '\dz\modulesDayZ\fsm\brain_player_client.fsm'";

This call brain_player_client.fsm on client from client files (pbo)

...


I need to send custom brain_player_client.fsm from server and exec this on client
 
Back
Top