Opened 6 years ago
Closed 6 years ago
#4900 closed defect (fixed)
[ATLAS] Errors when opening the actor viewer.
Reported by: | Stan | Owned by: | s0600204 |
---|---|---|---|
Priority: | Should Have | Milestone: | Alpha 23 |
Component: | Atlas editor | Keywords: | |
Cc: | Patch: | D1276 |
Description
When opening Atlas and using the actor viewer I get these errors.
WARNING: JavaScript warning: simulation/components/PlayerManager.js line 76 reference to undefined property this.playerEntities[0] WARNING: JavaScript warning: Script value conversion check failed: v.isNumber() (got type undefined)
Steps to reproduce
- Open Atlas
- Go to the entity tab
- Open the actor viewer
- Pick a unit
Change History (10)
comment:1 by , 6 years ago
Milestone: | Backlog → Alpha 23 |
---|
comment:2 by , 6 years ago
Blame says it's likely r18964 since those lines were introduced then. Maybe one of the resources variable is not initialized properly in Atlas.
comment:3 by , 6 years ago
How do you mean? The resource agnostic patch didn't change the PlayerManager and it doesn't complain about resources but about the gaia player entity not existing.
Here a stacktrace:
WARNING: PlayerManager.prototype.GetPlayerByID@simulation/components/PlayerManager.js:79:9 WARNING: JavaScript warning: simulation/components/PlayerManager.js line 83 reference to undefined property this.playerEntities[0] WARNING: JavaScript warning: Script value conversion check failed: v.isNumber() (got type undefined) WARNING: PlayerManager.prototype.GetPlayerByID@simulation/components/PlayerManager.js:79:9 QueryPlayerIDInterface@simulation/helpers/Player.js:212:18 QueryOwnerInterface@simulation/helpers/Player.js:200:9 ApplyValueModificationsToEntity@simulation/helpers/ValueModification.js:8:58 ValueModificationManager.prototype.ApplyModifications@simulation/components/ValueModificationManager.js:14:9 WARNING: PlayerManager.prototype.GetPlayerByID@simulation/components/PlayerManager.js:79:9 QueryPlayerIDInterface@simulation/helpers/Player.js:212:18 QueryOwnerInterface@simulation/helpers/Player.js:200:9 ApplyValueModificationsToEntity@simulation/helpers/ValueModification.js:8:58 ValueModificationManager.prototype.ApplyModifications@simulation/components/ValueModificationManager.js:14:9
comment:4 by , 6 years ago
From testing, Alpha 19 to 22 already throw the warning, but only once. It's new in svn that the warning is thrown once per selection :-/
So the revision in a23 won't help us, as the root cause existed before.
comment:5 by , 6 years ago
Thanks for investigating with your limited time ! To answer your other question I saw those lines were modified but I guess that's the code calling them that's broken.When I have more time I'll try to revert to A19 to see what introduced it. My guess is now the code is called multiple times because its probably more agnostic and so we also get the warning more than once.
comment:6 by , 6 years ago
I still don't see any change to the PlayerManager in r18964. You don't have to checkout alpha 19, the mistake seems buried far more deeply than the PlayerManager.
comment:7 by , 6 years ago
Oh I'm really sorry. Then maybe r20797 as it gets GetPlayerByID for colors. for the main issue though I don't know. I'm sure it's not called by js as putting warns don't do anything.
comment:8 by , 6 years ago
I think the core problem is due to ActorViewer
apparently having its own simulation instance (presumably so it can create and destroy entities as it chooses, and mess around with animations and speed without affecting the "main" Atlas simulation instance).
However, this "local" instance never gets any players created/initialised. Thus the PlayerManager
component of the instance does not know of, and so cannot find, any player entities for the unit/structure/whatever to belong to.
A possible solution would be to copy the "main" instance's PlayerData
to ActorViewer
's instance and initialise it.
comment:9 by , 6 years ago
Component: | UI & Simulation → Atlas editor |
---|---|
Patch: | → D1276 |
Occurs when selecting any item in the actor viewer in atlas. Sounds like a recent problem, does anyone want to find out the revision? (I guess its faster on windows without compiling)