Whenever my Secondary world connects to the main world, I always see the following message:
Quotecomponent hauntable already exists on entity 106997 - multiplayer_portal_moonrock! scripts/prefabs/multiplayer_portal.lua:47 in (upvalue) OnGetPortalRez (Lua) <45-54>
The complete log for this part is:
Quote[00:00:38]: [SyncWorldSettings] recieved world settings from master shard. true
[00:00:38]: [SyncWorldSettings] applying krampus = never from master shard.
[00:00:38]: [SyncWorldSettings] applying portalresurection = always from master shard.
[00:00:38]: component hauntable already exists on entity 106997 - multiplayer_portal_moonrock! scripts/prefabs/multiplayer_portal.lua:47 in (upvalue) OnGetPortalRez (Lua) <45-54>
[00:00:38]: [SyncWorldSettings] applying ghostsanitydrain = none from master shard.
[00:00:38]: [SyncWorldSettings] applying resettime = none from master shard.
[00:00:38]: [SyncWorldSettings] applying basicresource_regrowth = always from master shard.
[00:00:38]: [SyncWorldSettings] recieved world settings from master shard. true
[00:00:38]: [SyncWorldSettings] applying krampus = never from master shard.
[00:00:38]: [SyncWorldSettings] applying portalresurection = always from master shard.
[00:00:38]: component hauntable already exists on entity 106997 - multiplayer_portal_moonrock! scripts/prefabs/multiplayer_portal.lua:47 in (upvalue) OnGetPortalRez (Lua) <45-54>
[00:00:38]: [SyncWorldSettings] applying ghostsanitydrain = none from master shard.
[00:00:38]: [SyncWorldSettings] applying resettime = none from master shard.
[00:00:38]: [SyncWorldSettings] applying basicresource_regrowth = always from master shard.
[00:00:39]: [Shard] secondary shard LUA is now ready!
[00:00:39]: Synchronizing forward to master snapshot 557
[00:00:39]: Available disk space for save files: 110065 MB
[00:00:40]: Serializing world: session/31FA69AA36254471/0000000557
Analysis:
I have configured portalresurection="always" in the leveldataoverride.lua of both shards. When the secondary connects, the main will sync this setting to the secondary, which causes the hauntable component to be repeatedly added to the multiplayer_portal. This also results in the HAUNT Action being repeatedly added to the actioncomponents.
Quote[00:10:41]: RemoteCommandInput: "dumptable(c_findnext("multiplayer_portal_moonrock").actioncomponents)"
[00:10:41]: Finding a multiplayer_portal_moonrock
[00:10:41]: Found 106997 (1/1)
[00:10:41]: K: 1 V: 33
[00:10:41]: K: 2 V: 91
[00:10:41]: K: 3 V: 91
[00:10:41]: K: 4 V: 91
Possible solution:
In the OnGetPortalRez function of multiplayer_portal.lua, before adding the hauntable component, check if the component already exists. The possible modification is as follows:
local function OnGetPortalRez(inst, portalrez) if portalrez then if inst.components.hauntable == nil then inst:AddComponent("hauntable") end inst.components.hauntable:SetHauntValue(TUNING.HAUNT_INSTANT_REZ) inst:AddTag("resurrector") elseif inst.components.hauntable then inst:RemoveComponent("hauntable") inst:RemoveTag("resurrector") end end
I hope this problem will be solved officially, thanks.
as mentioned above
There are no comments to display.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now