Angband.oook.cz
Angband.oook.cz
AboutVariantsLadderForumCompetitionComicScreenshotsFunniesLinks

Go Back   Angband Forums > Angband > Development

Reply
 
Thread Tools Display Modes
Old March 26, 2009, 11:06   #1
PaulBlay
Knight
 
Join Date: Jan 2009
Posts: 657
PaulBlay is on a distinguished road
'object.txt' format suggestion

Suggestion: Add ':potion' (etc.) to the N: line.

It makes it more obvious that

N:433:Detection:rod
G:-:d
I:66:4:0

is a rod (not a wand) and it allows the 'name' line to be unique even without the number (does not apply to certain artifacts). The latter would come in handy if it is ever decided to re-order the list (between versions or between variants). It would also make it consistent with monster.txt where the monster name should be unique.
__________________
Currently turning (Angband) Japanese.
PaulBlay is offline   Reply With Quote
Old March 28, 2009, 23:59   #2
zaimoni
Knight
 
zaimoni's Avatar
 
Join Date: Apr 2007
Posts: 590
zaimoni is on a distinguished road
Eh...what would really be helpful when reordering the list, is obliterating the index number outright and just going off of sval/tval indexing. I'd be fine with changing sval to a textual representation as well, for readability (but I think that might be in V SVN already).

It's not that difficult a change (pushed through in Zaiband 3.0.9). Easy way to do it is to make the k_idx an internal detail handled when loading the file, that never reaches the savefile or the object.txt file.
zaimoni is offline   Reply With Quote
Old March 29, 2009, 01:08   #3
PaulBlay
Knight
 
Join Date: Jan 2009
Posts: 657
PaulBlay is on a distinguished road
Quote:
Originally Posted by zaimoni View Post
(but I think that might be in V SVN already).
Not when I downloaded it a short while back.

I think you're right about just using the tval and sval. If a single number is really needed you could just have TTTSSS (e.g. tval * 1000 + sval). That would allow easy ordering and a unique number while still preserving the tval and sval information.
__________________
Currently turning (Angband) Japanese.
PaulBlay is offline   Reply With Quote
Old March 30, 2009, 03:23   #4
zaimoni
Knight
 
zaimoni's Avatar
 
Join Date: Apr 2007
Posts: 590
zaimoni is on a distinguished road
Currently, the single number that is needed is an array index into the reference data for the standard objects. Eliminating this number from the object.txt configuration files was easy.

Eliminating this number from the monster.txt files: not so easy; I don't see a good hook for doing this. But that would also be very convenient.
zaimoni is offline   Reply With Quote
Reply


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

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
3.1.0 bug - object knowledge menu Skelwing Vanilla 2 January 18, 2009 13:04
forum format is handheld-unfriendly Pete Mack Oook! 1 September 21, 2008 02:59
Something odd about monster.txt Magnate Vanilla 2 August 3, 2008 02:25
DaJAngband: new object question will_asher Variants 4 December 13, 2007 04:18
Object Stacking bug 309 APWhite Vanilla 3 October 23, 2007 11:04


All times are GMT +1. The time now is 19:43.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2018, vBulletin Solutions Inc.