Go Back   RunUO - Ultima Online Emulation > RunUO > Core Modifications > Other

Other Cant find a category above, use this one! Core mods not listed above go here!

Reply
 
Thread Tools Display Modes
Old 08-20-2005, 08:20 AM   #1 (permalink)
Forum Novice
 
Join Date: Oct 2003
Location: Vienna, Austria
Age: 22
Posts: 127
Send a message via ICQ to Arahil
Default Offset on Tile.ID

on every instance of the class Tile there is an offset of 0x4000 on the ID-property. with this offset the id points to the index in tiledata.mul - which is in my point of view completely unneccessary, because every time the id is accessed there are binary operations to "reduce" the id back to the real value.

so, why is this offset on the id-property?
Arahil is offline   Reply With Quote
Old 08-20-2005, 09:43 AM   #2 (permalink)
Account Terminated
 
Join Date: Sep 2002
Age: 26
Posts: 3,846
Send a message via ICQ to Phantom Send a message via AIM to Phantom Send a message via MSN to Phantom
Default

Quote:
Originally Posted by Arahil
on every instance of the class Tile there is an offset of 0x4000 on the ID-property. with this offset the id points to the index in tiledata.mul - which is in my point of view completely unneccessary, because every time the id is accessed there are binary operations to "reduce" the id back to the real value.

so, why is this offset on the id-property?
Because thats how the mul file is setup?

What does it matter....exactly?
Phantom is offline   Reply With Quote
Old 08-20-2005, 09:57 AM   #3 (permalink)
Forum Novice
 
Join Date: Oct 2003
Location: Vienna, Austria
Age: 22
Posts: 127
Send a message via ICQ to Arahil
Default

i found it while moving the size restriction of tiledatato a higher value, since we have way to much new graphics on our shard, an with our custom client it is no problem to support such a high number of graphics.

i was just curious why this offset is there - maybe there's a reason i do not see yet...
Arahil is offline   Reply With Quote
Old 08-20-2005, 10:11 AM   #4 (permalink)
Account Terminated
 
Join Date: Sep 2002
Age: 26
Posts: 3,846
Send a message via ICQ to Phantom Send a message via AIM to Phantom Send a message via MSN to Phantom
Default

Quote:
Originally Posted by Arahil
i found it while moving the size restriction of tiledatato a higher value, since we have way to much new graphics on our shard, an with our custom client it is no problem to support such a high number of graphics.

i was just curious why this offset is there - maybe there's a reason i do not see yet...
Its the mul file...I hope you understand if you release your client and are using code from RunUO the client has to be under the GPL license
Phantom is offline   Reply With Quote
Old 08-20-2005, 10:12 AM   #5 (permalink)
Forum Newbie
 
Join Date: Nov 2002
Posts: 89
Default terrain and art tiles

The first 0x4000 tiles in tiledata are the terrain tiles, and their tiledata record structure is different then the art tile data structures in the mul file.. In addition, the artidx.mul is in terms of absolute tile ids.
punt59 is offline   Reply With Quote
Old 08-20-2005, 10:21 AM   #6 (permalink)
Forum Novice
 
Join Date: Oct 2003
Location: Vienna, Austria
Age: 22
Posts: 127
Send a message via ICQ to Arahil
Default

the client does not use runuo code in any way.


i know the file format of the tiledata.mul and about the landtiles. i also do know, that Tile.ID obviously points to the index in tiledata.mul, i just do not really get why, since every time Tile.ID is used (for example, to fetch information from the tiledata) the array is accessed with index Tile.ID & 0x3FFF.
the problem is, that i do not see any sense in this offset.
Arahil is offline   Reply With Quote
Old 08-20-2005, 10:49 AM   #7 (permalink)
Forum Newbie
 
Join Date: Nov 2002
Posts: 89
Default end of file

Quote:
Originally Posted by Arahil
the problem is, that i do not see any sense in this offset.

Ok, undertand your question better. I guess Runuo could check to ensure it doesn't go past the tiledata end of file instead. The OSI tiledata going past 0x3fff would exceed, and you would get an error on the seek() to the file. Clearly one could check there as well I suppose.
punt59 is offline   Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off



Powered by vBulletin® Version 3.7.0
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0 RC5