You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
entity.transform = newtransform only works on client. Seems like it's readonly on server. As a testmod you can use https://github.com/3ti65/BlueprintManagerTest with https://github.com/Powback/BlueprintManager , spawn and type in chat spawnrp server and then moverp server. You can see that the client truck moves on client but not on server (the collision doesnt move). Use XP3_Shield ConquestLarge0 2
The text was updated successfully, but these errors were encountered:
This is only an issue for GameObjects that should move dynamically, like windmill blades which doesn't have collision in retail, I suspect that it's intended.
As a workaround for the map editor, we can simply destroy the old GameObject and replace it with a new one. This doesn't work if the GameObject has damage-states, but that's not supported right now anyway.
Spawning an object does indeed create the StaticPhysicsEntity on both the server and the client, but it isn't caught by the EntityFactory hook, and it doesn't seem to be added to the entity list when spawned using EntityManager:CreateServerEntitiesFromBlueprint.
By using raycasts I can successfully catch and move the collision clientside.
So it seems like we need a way to access the physics entity that's connected to the spawned GameObject somehow.
Similarly, it would be useful if the PhysicsEntity could be connected to the GameObject. That way we could use raycasting to select and move GameObjects. Right now, raycasts only hit the PhysicsEntities, which is expected.
Also, when moving PhysicsEntities, it seems like the transform is updated ingame, but entity.transform outputs the same.
Bypassed by doing
:FireEvent("Disable")
:FireEvent("Enable")
Changing transform works for entities that are supposed to move.
Pretty sure this is vanilla behavior, since the windmill blades don't have collision either.
entity.transform = newtransform
only works on client. Seems like it's readonly on server. As a testmod you can use https://github.com/3ti65/BlueprintManagerTest with https://github.com/Powback/BlueprintManager , spawn and type in chatspawnrp server
and thenmoverp server
. You can see that the client truck moves on client but not on server (the collision doesnt move). UseXP3_Shield ConquestLarge0 2
The text was updated successfully, but these errors were encountered: