Loftar,
Coming from someone who can't code, on behalf of someone who can:
If we were looking to match the stone and ore stockpile textures to those of the stone/ore, or its wall textures prior mining, we run into the problem that in the case of mixed stockpiles, there is no current code that dictates how to handle the differentiation. So if we could code client side, the logic of "If all = same<stone> then <stone texture>, else <texture black>", however that might read in code, we would need the information from the server side.
1. Is the required information sent to the client from the server in order to do the coding client side? If not, is it hard to and would you consider that it is sent?
2. If this is not very hard or time consuming at all, would you consider coding it server side if you prefer not to send this information to the client?
I hope that made sense.
-
Sarge
- Posts: 2059
- Joined: Fri Oct 09, 2009 3:41 am
Custom Clients - Stockpile Textures (Stone & Ore)
factnfiction101 wrote:^I agree with this guy.
-
APXEOLOG
- Posts: 1300
- Joined: Fri Apr 23, 2010 7:58 am
- Location: Somewhere on Earth
Re: Custom Clients - Stockpile Textures (Stone & Ore)
NoSarge wrote:1. Is the required information sent to the client from the server in order to do the coding client side?
W10 Meme Plot | W9 Mantis Garden | W8 Core | W7 Ofir | W6 the City of Dis | W5 Vitterstad | W4 A.D. | W3 Mirniy
jorb wrote:All your characters will be deleted, and I will level every village any one of them were ever members of.
-
Granger
- Posts: 9255
- Joined: Mon Mar 22, 2010 2:00 pm
Re: Custom Clients - Stockpile Textures (Stone & Ore)
@Loftar: Sending the whole list might be a bit on the high side traffic wise (as there could be quite some piles within render range), but maybe it could be possible to send a single byte, useable as an index into a lookup table for materials, that tells the client the material of a single (first or last put in) item within the pile?Sarge wrote:2. If this is not very hard or time consuming at all, would you consider coding it server side if you prefer not to send this information to the client?
⁎ Mon Mar 22, 2010 ✝ Thu Jan 23, 2020
-
loftar
- Posts: 9093
- Joined: Fri Apr 03, 2009 7:05 am
- Location: Your character database
Re: Custom Clients - Stockpile Textures (Stone & Ore)
Sending the information to the client isn't the problem (I already have a general mechanism where I use 2-byte IDs to identify resources), it's more the matter that:Granger wrote:send a single byte
- I think it's kind of ugly to just let the first/last inserted item affect the entire stockpile; and
- I'm concerned what variable materials on stockpiles might do for client performance, as sprites with different materials can't be instantiated in rendering.
"Object-oriented design is the roman numerals of computing." -- Rob Pike
-
Granger
- Posts: 9255
- Joined: Mon Mar 22, 2010 2:00 pm
Re: Custom Clients - Stockpile Textures (Stone & Ore)
My suggestion would be to send the data then, post the lookup table (or don't in case the client alreads translates it), let the custom client makers work with in and in case it turns out good (performance wise) backport it.loftar wrote:Sending the information to the client isn't the problem (I already have a general mechanism where I use 2-byte IDs to identify resources), it's more the matter that:Granger wrote:send a single byte
- I think it's kind of ugly to just let the first/last inserted item affect the entire stockpile; and
- I'm concerned what variable materials on stockpiles might do for client performance, as sprites with different materials can't be instantiated in rendering.
You could also, in case it isn't costly on the server, send the material that has the majority inside the stockpile - but IMHO even one (first or last) would do the trick so we can evaluate the performance impact on rendering.
⁎ Mon Mar 22, 2010 ✝ Thu Jan 23, 2020