Bug #21982

PostInit does not run correctly when JIPing in as a seagull or spectator

Added by jaynus almost 4 years ago. Updated about 3 years ago.

Status:Closed Start date:07/07/2011
Priority:Normal Due date:09/24/2011
Assignee:Sickboy % Done:

100%

Category:XEH
Target version:-
Component:extended_eventhandlers Affected Version:
Close Reason:

Description

When JIPing into a mission where it is no-JIP (you JIP in as a seagull or spectator). The PostInit functions do not execute correctly.

[28246,647.127,0,"XEH: PreInit Started. v3.0.6"]
[28246,647.144,0,"MISSINIT","spec_test","Desert_E",true,false,false]
[28246,660.198,0,"XEH: PreInit Finished"]
[28246,660.212,0,"XEH: VehicleCrewInit: 0"]
[28246,655.803,0,"x\ace\addons\sys_wounds\XEH_preInit.sqf:8","WARNING: Enhanced Armor difficulty options enabled - this is not recommended in conjunction with ACE Wounds!"]
creating seagull (no person)
[28805,670.38,42.347,"WARNING: PostInit did not finish in a timely fashion"]
Creating debriefing

Notice above, there is no appropriate "PostInit Started" displayed. strictly that PostInit did not finish.

Associated revisions

Revision b39e6ae1
Added by Sickboy over 3 years ago

~ CHANGED: When PostInit times out on a client machine, probably due to no player object available (e.g spawned as seagul), continue PostInit regardless. closes #21982

Revision b39e6ae1
Added by Sickboy over 3 years ago

~ CHANGED: When PostInit times out on a client machine, probably due to no player object available (e.g spawned as seagul), continue PostInit regardless. closes #21982

History

Updated by jaynus almost 4 years ago

Oh, as a basic repro. Just JIP in with ACE spectator on.

Updated by Sickboy almost 4 years ago

  • Due date set to 07/07/2011
  • Category set to XEH
  • Status changed from New to Feedback
  • Assignee set to Sickboy
  • % Done changed from 0 to 10

This is by design. PostInit implies player-ready on a client, where-as player-object null implies JIP and waitUntil not null.
As soon as there is a valid player object, it will initialize.

Changing this behavior might violate scripts that depend on this.

Perhaps knowing this, you could take it into account.
But if it is a real problem I suppose we could whip up a PostInit flag or another EH class that would run regardless of the player object ready-ness on a client.

Updated by Sickboy almost 4 years ago

Alternatively, as a seagull is a valid object as well (much like any other animal), we could perhaps point the player variable to the seagull object if we could reliably determine and isolate the "NoJip" scenario.

This way, the PostInit would run and your requirements are met, while there is a valid object available as 'player', so scripts relying on this would still work properly as well.

Updated by jaynus almost 4 years ago

I think an extra set of classes would work. (XEH_always_postinit?)

We would strictly just move ACRE over to that new set of init types.

Updated by Sickboy almost 4 years ago

  • Due date changed from 07/07/2011 to 09/24/2011

Updated by Sickboy over 3 years ago

Does anyone have a reliable way of detecting when "Player has spawned as a seagull"?
As opposed to being JIP and player object not being ready yet... (aka, isNull player isn't going to cut it)

Updated by jaynus over 3 years ago

Read the missionNamespace description variable for respawn type, if not defined or is the seagull type, then you know if they are a seagull or not.

Updated by Nou over 3 years ago

Sickboy, any progress on this? Do you want me to look at it?

Updated by Sickboy over 3 years ago

  • Status changed from Feedback to Resolved
  • % Done changed from 10 to 100

Updated by Sickboy over 3 years ago

Hows this?

Updated by Sickboy about 3 years ago

  • Status changed from Resolved to Closed

Also available in: Atom PDF