Jump to content
Sign in to follow this  
Ilias38rus

MP unit switch.

Recommended Posts

Need a script which will switch player's unit to any other unit for any player in multiplayer game (Leaving old unit as AI and getting all game's scripts and mods working for new unit).

Share this post


Link to post
Share on other sites

Spawning other units as "Playable" and then clicking the key set for "team switch" from the controls maybe? That way they will remain AI until you or any other player unit gets control over 'em.

Share this post


Link to post
Share on other sites

Spawning other units as "Playable" and then clicking the key set for "team switch" from the controls maybe? That way they will remain AI until you or any other player unit gets control over 'em.

Team switch do not working in multiplayer.

Share this post


Link to post
Share on other sites

^ I really doubt Shay_gman does not care about his mod... maybe it's just you he doesn't care about.

 

So you expect him to give you the code to his work because it's "junked with stupid effects"?

  • Like 1

Share this post


Link to post
Share on other sites

this unit switch is like onTeamSwitch? from https://community.bistudio.com/wiki/onTeamSwitch

I like to play coop missions alone in MP, with AI teammates, and I wonder if someone could help in how to make to switch between the AI teammates.

You can use the command SilentSpike sended, if you do not have some mods or scripts which are requestting some additional work, as in my situation.

Share this post


Link to post
Share on other sites

Need a script which will switch player's unit to any other unit for any player in multiplayer game (Leaving old unit as AI and getting all game's scripts and mods working for new unit).

 

 

Know anyone how to reexecute the |examples| for new unit?

 

 

Can anyone help?

Just execute your scripts one by one again.

Or create a script which executes the other scripts / mod inits and run this on first Spawn and then after using the selectPlayer.

Share this post


Link to post
Share on other sites

Just execute your scripts one by one again.

Or create a script which executes the other scripts / mod inits and run this on first Spawn and then after using the selectPlayer.

I don't know how to reexecute: Zeus module and MCC.

Share this post


Link to post
Share on other sites

I understand why Bohemia took it out of multiplayer. Definitely some issues came with it but I wish they would have kept the option open for mission designers to allow it to be used for small coop missions. Does anyone have a good workaround to get it to work in MP and if yes a demo mission would be great.

Share this post


Link to post
Share on other sites

Need a script which after switching player's unit to any other unit for any player, getting all game's scripts and mods working for new unit again.

Create a script which executes the other scripts / mod inits and run this after using the selectPlayer.

I need to know that too  :(

Share this post


Link to post
Share on other sites

Ok, I think you have to reelaborate the question.

 

It's like: I need the script to become another person (you have it solved with the selectPlayer command) but I want to move my job, wife, kids, sexual orientation, car etc... to the new person. 

 

You have to say your job, wife, kids etc.. AFAIK there are no mentalists (some magicians yes) around the Arma scripting community...

 

An advance: if those scripts refer to the players as, yes, player, then, good news: you have to do nothing.

 

And if not, then maybe you have to ask each script author or thread about how to reinit on a new unit. There is not a "universal-transfer-the-scripts-no-matter-what" script.

 

Antistasi has this functionality (for temporal AI control) and believe me, it makes things MUCH MORE COMPLICATED!!!

Share this post


Link to post
Share on other sites

MCC have a ''Hijack' function it's working like i need, but it's junked with stupid effects and wasting minutes before working, i asked owner for code, but he is _____, do not cares at all.

I think YOU'VE just made yourself a *^^%*(*.

Share this post


Link to post
Share on other sites

this unit switch is like onTeamSwitch? from https://community.bistudio.com/wiki/onTeamSwitch

I like to play coop missions alone in MP, with AI teammates, and I wonder if someone could help in how to make to switch between the AI teammates.

 

I understand why Bohemia took it out of multiplayer. Definitely some issues came with it but I wish they would have kept the option open for mission designers to allow it to be used for small coop missions. Does anyone have a good workaround to get it to work in MP and if yes a demo mission would be great.

 

I need to know that too  :(

Happy to present:

Script executing " selectplayer " command with passing curator module access rights and supporting mods: Now: " FSF sacventral " and " TGP ". (If want some other mod to include - write, will try to help)

`Letting player jump to any unit in any game at any time.

Using:

Uncomment, marked with needeble mod names, lines to get the mod supporting.

Execute local on computer, where the needeble player is, by:

[||u| (`'new` unit)|||,|cm| (curator module)|] execVM "ss.sqf";

Examples:

[_this,cmt] execVM "ss.sqf";
[ut] execVM "ss.sqf"; //```[unit] execVM "ss.sqf"; 

Download.

(in case if anywhen the link will not work)

ss.sqf

//[|u|||,|cm||] execvm "ss.sqf";

selectplayer (_this select 0);
if((typename(_this select 1)) == "object")then{
	unassigncurator (_this select 1);
	if(typename(_this select 0) == "object")then{driver(_this select 0)}else{_this select 0} assigncurator (_this select 1);
};
for "_cn" from 0 to 1 do {
if((_this select 0) getvariable "psts")exitwith{};
/*"TGP"|1
	[] spawn TGP_fnc_addAction;
"TGP"|1*/
	if(!isDedicated)then{
/*"FSF sacventral"|2
		player setVariable ["FSFSV_BACKPACK",objNull];
		player addEventHandler ["Respawn",{player spawn FSFSV_Player_Init;}];
		[player] spawn FSFSV_Player_Init;
"FSF sacventral"|2 */
	};
	_this select 0 setvariable ["psts",true,true];
};

Share this post


Link to post
Share on other sites

Why did you make another account, Ilias38rus?

It's not his account, we writed the script together.

Share this post


Link to post
Share on other sites

Finished the second script (replacement of respawn), if some one need, write to me, i'll send it seted up.

Share this post


Link to post
Share on other sites

So, I've got the team switch working in my mp mission. But, is there a way to get the ai helicopter pilot to automatically land back at it's designated helipad?

 

For example, I'm flying in one helicopter, but need to switch to another, the ai will then just land straight down. How can i make it so they instead land back in their parking spot?

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  

×