Home   Help Search Login Register  

Author Topic: Respawn "side" BUGS ???  (Read 2101 times)

0 Members and 1 Guest are viewing this topic.

Offline laggy

  • Members
  • *
  • "Behold a pale horse"
Respawn "side" BUGS ???
« on: 26 Feb 2010, 00:26:52 »
Hello all,

Wondering about this:

Respawn "side" is in my opinion a great addition to the BIS series, and now it actually works with MP teamswitch and everything. However, since I started using this feature I have noticed issues with my MP missions which never occurred before.


For example:

1- When a player JIP, the mission ends for him instantly, even though the other players are playing along happily. He can't join the mission, since it is "finished" on his computer. See here.

2- Not sure about this, but I think publicVariable commands might be affected as well, see here.
    This question/issue is explained in detail here.


No matter what, I'm curious if any other mission designers or players have noticed issues with respawn "side", or know for a fact that it is bugged.

Thanks in advance,

Laggy

« Last Edit: 26 Feb 2010, 00:29:55 by laggy »
And I looked and beheld a pale horse and his name that sat on him was Death and Hell followed with him.

Offline kju

  • Members
  • *
    • PvPScene - The ArmA II multiplayer community
Re: Respawn "side" BUGS ???
« Reply #1 on: 26 Feb 2010, 08:09:06 »
Linking to the posts does not really help. You should list the details briefly in here.

to 2) You are aware that JIP get the latest value of a public variable on connect.
This means you need to init GVs this way:

Code: [Select]
//init.sqf
if (isNil "TAG_Var") then
{
string TAG_Var = "";
};

to 1) Problem seems to be a not good design of your end conditions.
I suggest you not to use editor triggers but scripted triggers.

Also shuko gives you great points.  :good:

Overall you problems have no relation to side respawn. Side works fine.  :)

Offline laggy

  • Members
  • *
  • "Behold a pale horse"
Re: Respawn "side" BUGS ???
« Reply #2 on: 28 Feb 2010, 11:57:58 »
Thanks a lot kju,

Code: [Select]
//init.sqf
if (isNil "TAG_Var") then
{
string TAG_Var = "";
};

Are you saying that to make a JIP recognize any value that has been PVd, you first have to define it as "" for that player locally, ONLY if the value isNil on JIP, or in general?

Quote
to 1) Problem seems to be a not good design of your end conditions.
I suggest you not to use editor triggers but scripted triggers.

That is the weird thing, because I don't use end triggers anymore (as in end1). I use the endMission "END1" variable and it is put at the end of the outro camera script. How on earth can that be active for a JIP that hasn't even seen the outro??? I am going crazy over this...

On the action script ending:

I usually use global triggers to broadcast important (mission function) variables. I just don't see how marginally reducing the script/trigger chain (like Shuko says) would be much better than having just one trigger that is started by two PV values (broadcasted from scripts) in the first place. A bit more effective, yes, but making the whole difference between a working or not working solution? Am I crazy if I say No?

Not arguing here, just curious as I might be missing some understanding of game engine priority or similar. Also still wondering about the ArmA2 reduced channel for custom scripts.

Thanks again both of you,

Laggy
« Last Edit: 28 Feb 2010, 12:40:40 by laggy »
And I looked and beheld a pale horse and his name that sat on him was Death and Hell followed with him.

Offline kju

  • Members
  • *
    • PvPScene - The ArmA II multiplayer community
Re: Respawn "side" BUGS ???
« Reply #3 on: 28 Feb 2010, 16:50:56 »
We have the same problem in AAS. It happens very rarely for JIP people.
Rejoining does not help. It does not bother me much to debug it.  :whistle:

laggy what you need to understand is that JIP players automatically received
the latest value sent via JIP - this happens before init.sqf is processed!
This means the normal init.sqf GV init overwrites the latest JIP value and can
lead to all sorts of issues.

So:
DS + 1 client

init.sqf:
MyTest = 1;

some script:
MyTest = MyTest + 1;
pV "MyTest";

JIP guy joining. he receives
MyTest = 2;
now init.sqf runs:
MyTest = 1; => 2->1 BADDDDDDDDDDDD

with proper design
if (isNil "MyTest") then
{
   MyTest = 1;
};

for JIP MyTest is already defined, so the inner part is not run and the latest value remains used.

Offline laggy

  • Members
  • *
  • "Behold a pale horse"
Re: Respawn "side" BUGS ???
« Reply #4 on: 28 Feb 2010, 17:12:31 »
Thanks again kju  :good:

Very good info on how PVs are given to JIPs before init.sqf is read.

In my case I still don't see why the mission should end directly for a JIP. Must be a bug  :scratch:

1-13 Red Mercury init.sqf (complete)
Code: [Select]
setviewdistance 2500;
nil = [] execVM "briefing.sqf";
[] exec "briefingnukemarkerupdate.sqs";
[] exec "briefingdisarmupdate.sqs";
BriefedUnits = [];
BriefedUnitsUpd1 = [];
BriefedUnitsUpd2 = [];
1 setRadioMsg "null";
2 setRadioMsg "null";
if (isServer) then {[] execVM "laggy_acmScript.sqf"};
if (isServer) then {nil = execVM "selectnukepos.sqf"};
if (isServer) then {nil = execVM "selectnukedisarm.sqf"};
if (isServer) then {casmissiondone = false; publicVariable "casmissiondone"};

private ["_showIntro"];

if (isMultiplayer) then
{
  // Multiplayer get choice, but never see it if JIP.
  _showIntro = (param2 == 0) AND (! isNull player OR isServer);
}
else
{
  // Single player people like intros.
  _showIntro = true;
};

if (isMultiplayer) then
{
if (param1 == 0) then {skiptime 0.25};
if (param1 == 1) then {skiptime 0};
if (param1 == 2) then {skiptime - 0.25};
if (param1 == 3) then {skiptime - 0.5};
};

if (_showIntro) then {[] exec "film.sqs"} else {if (isServer) then {introdone = true; publicVariable "introdone"}};

I always use the server to broadcast variables from the init.sqf and I don't see how anything in this init could create the mission ending issue. Glad to hear I'm not the only one having problems though  :P

Regards,

Laggy
« Last Edit: 28 Feb 2010, 17:15:12 by laggy »
And I looked and beheld a pale horse and his name that sat on him was Death and Hell followed with him.

Offline kju

  • Members
  • *
    • PvPScene - The ArmA II multiplayer community
Re: Respawn "side" BUGS ???
« Reply #5 on: 28 Feb 2010, 18:36:56 »
Please post the code of your end condition(s).  :)

Offline laggy

  • Members
  • *
  • "Behold a pale horse"
Re: Respawn "side" BUGS ???
« Reply #6 on: 28 Feb 2010, 20:25:01 »
Win trigger

condition:
Code: [Select]
! (isNil "nukedisarmer") AND (disarmPerformed == correctDisarm) AND isNil "screwup"activation:
Code: [Select]
hint "Task completed."; tskObj4 setTaskState "SUCCEEDED"; goodend = true; [] exec "winoutro.sqs"
winoutro.sqs
Code: [Select]
0 fademusic 1
{_x allowdamage false} forEach units heroes
{_x allowdamage false} forEach units helogroup

titleText ["","BLACK OUT", 4]

~ 5

_camera = "camera" CamCreate [0,0,0]
_camera CamSetTarget [getpos nukepos select 0, getpos nukepos select 1, 0]
_camera CamSetRelPos [300, - 700, 150]
_camera CamSetFOV 1.0
_camera CameraEffect ["internal","back"]
_camera CamCommit 0

titleText ["","BLACK IN", 4]

_camera CamSetTarget [getpos nukepos select 0, getpos nukepos select 1, 600]
_camera CamSetRelPos [50, - 1200, -350]
_camera CamCommit 30

~ 5

titleCut ["The nuclear bomb was disarmed.","PLAIN", 5]

~ 10

titleText ["","BLACK OUT", 3]

~ 3

titleCut ["","PLAIN", 5]

? ! isDedicated : _camera CamSetTarget vehicle player
? ! isDedicated : _camera CamSetRelPos [1, 1, 2]
? ! isDedicated : _camera CamCommit 0

? ! isDedicated : _camera CamSetTarget vehicle player
? ! isDedicated : _camera CamSetRelPos [1, 0.5, 1]
? ! isDedicated : _camera CamCommit 20

~ 1

titleText ["","BLACK IN", 5]

~ 5

titleCut ["MISSION ACCOMPLISHED","PLAIN", 5]

~ 10

titleText ["","BLACK OUT", 5]

~ 6

_camera Cameraeffect ["Terminate", "Back"]
CamDestroy _camera

endMission "END1"

exit



Loose trigger

condition:
Code: [Select]
! (isNil "nukedisarmer") AND (disarmPerformed != correctDisarm)activation:
Code: [Select]
screwup = true; nukedisarmer sideRadio "ra6"; armageddon = true; [] exec "looseoutro.sqs"; nukepos say "nukebeep"
Alternate loose trigger solution

Server trigger

condition:
Code: [Select]
dayTime >= 12 AND isServer AND isNil "goodend"activation:
Code: [Select]
toolate = true; publicVariable "toolate"
Global trigger

condition:
Code: [Select]
toolateactivation:
Code: [Select]
armageddon = true; [] exec "looseoutro.sqs"; leader heroes sideRadio "ra6"
looseoutro.sqs
Code: [Select]
0 fademusic 1
{_x allowdamage false} forEach units heroes
{_x allowdamage false} forEach units helogroup

titleText ["","BLACK OUT", 4]

~ 5

_camera = "camera" CamCreate [0,0,0]
_camera CamSetTarget [getpos nukepos select 0, getpos nukepos select 1, 20]
_camera CamSetRelPos [300, - 700, 100]
_camera CamSetFOV 1.0
_camera CameraEffect ["internal","back"]
_camera CamCommit 0

titleText ["","BLACK IN", 4]

_camera CamSetTarget [getpos nukepos select 0, getpos nukepos select 1, 600]
_camera CamSetRelPos [50, - 1200, -350]
_camera CamCommit 30

~ 5

nil = [] execVM "nuke.sqf"

~ 2

playsound "nukesound"

~ 18

dummyguy sideradio "ra11"

~ 10

leader heroes sideradio "ra12"

~ 5

titleCut ["MISSION FAILED","PLAIN", 5]

~ 20

titleText ["","BLACK OUT", 5]

~ 6

endMission "END2"

_camera Cameraeffect ["Terminate", "Back"]
CamDestroy _camera

exit

That's it  :)

Laggy
« Last Edit: 28 Feb 2010, 20:41:08 by laggy »
And I looked and beheld a pale horse and his name that sat on him was Death and Hell followed with him.

Offline kju

  • Members
  • *
    • PvPScene - The ArmA II multiplayer community
Re: Respawn "side" BUGS ???
« Reply #7 on: 28 Feb 2010, 23:17:23 »
Can you reproduced it 100% or very often?

Do you get the win or lost ending?

Offline laggy

  • Members
  • *
  • "Behold a pale horse"
Re: Respawn "side" BUGS ???
« Reply #8 on: 28 Feb 2010, 23:59:18 »
Have to test some more, can't tell for sure yet if it is 100%.

So you don't find any obvious mistakes ?

Thanks kju,

Laggy
« Last Edit: 01 Mar 2010, 00:02:26 by laggy »
And I looked and beheld a pale horse and his name that sat on him was Death and Hell followed with him.