Butko wrote:Well it can't be done without some info from devs.
The most I need is: coordinates of char GFX pieces. So when I calculate char screen position out of grid coordinates I need to know distance for each body part from that coordinates. Or maybe other way devs have done this... I dunno. It's made on server side
loftar wrote:Butko wrote:Well it can't be done without some info from devs.
The most I need is: coordinates of char GFX pieces. So when I calculate char screen position out of grid coordinates I need to know distance for each body part from that coordinates. Or maybe other way devs have done this... I dunno. It's made on server side
It's not on the server side. It's the Resource.Image.o variable (o as in offset). The only thing the server sends to the client is a list of resources to draw together; the client does all the coordinate calculation entirely on its own.
George Carlin wrote:The real reason that we can’t have the Ten Commandments in a courthouse: You cannot post “Thou shalt not steal,” “Thou shalt not commit adultery,” and “Thou shalt not lie” in a building full of lawyers, judges, and politicians. It creates a hostile work environment.
loftar wrote:Butko wrote:Well it can't be done without some info from devs.
The most I need is: coordinates of char GFX pieces. So when I calculate char screen position out of grid coordinates I need to know distance for each body part from that coordinates. Or maybe other way devs have done this... I dunno. It's made on server side
It's not on the server side. It's the Resource.Image.o variable (o as in offset). The only thing the server sends to the client is a list of resources to draw together; the client does all the coordinate calculation entirely on its own.
Butko wrote:O khere is stored offset, but where is calculated? Image constructor gets argument byte[] buf. This argument is passed to method where is only if byte is negative and it's added 256 if it is.
Where is calculation of coordinates of character pieces done? This code is very confusing and more I read less I find :S As I understand Resource class is only a class for loading and "storing" graphical objects. Actual calculations must be done somewhere else. Like to check if image is one of character pieces and if it, check which one it is and then calculate it's position relative to...?
Unreal maybe give some of those things but interface and graphics are just ugly :/
loftar wrote:Butko wrote:O khere is stored offset, but where is calculated? Image constructor gets argument byte[] buf. This argument is passed to method where is only if byte is negative and it's added 256 if it is.
Where is calculation of coordinates of character pieces done? This code is very confusing and more I read less I find :S As I understand Resource class is only a class for loading and "storing" graphical objects. Actual calculations must be done somewhere else. Like to check if image is one of character pieces and if it, check which one it is and then calculate it's position relative to...?
Sorry, I don't understand what you're asking.
Users browsing this forum: No registered users and 38 guests