Page MenuHomeFeedback Tracker

SetObjectTexture and SetObjectMaterial are not synced on map objects
Assigned, NormalPublic

Description

Hello,

Currently, SetObjectTexture and SetObjectMaterial are not synced on map objects.

With some thought on my side. I would sync it's due because of the full path of the texture should be synced.

With some research, it's would be easy to counter that huge sync. 95% of the time you know which path you want to assign. You just hardcode it in code.

Why not instead, make a config array of string, that reference to all possible textures you want to apply. And you create two new functions EntityAI::SetObjectTextureByIndex and EntityAI::SetObjectMaterialByIndex each one take index of the hiddenSelections at first parameter and an index to this new config array at second parameter.

It's still modding friendly, due to the += operator for array in config.cpp.

And you can easily apply quantization to this second index because you know the max he can hold.

For example if we consider one character is encoded in ASCII, 7 bits to encode a character. With the technic just above. You can have 127 different textures.

Details

Severity
Major
Resolution
Open
Reproducibility
Always
Operating System
Windows 10 x64
Category
Engine
Steps To Reproduce

Just use SetObjectTexture or SetObjectMaterial on any map object at server side that has correctly hiddenSelections setup.

Event Timeline

NiiRoZz created this task.Apr 21 2020, 9:38 PM
Arkali added a subscriber: Arkali.Apr 21 2020, 9:39 PM
Jest added a subscriber: Jest.Apr 21 2020, 9:43 PM
NiiRoZz edited Steps To Reproduce. (Show Details)Apr 21 2020, 10:29 PM
Geez changed the task status from New to Assigned.Apr 22 2020, 12:48 PM