BT 1 file list on CBM64

Any developer realated stuff
User avatar
Twoflower
Posts: 128
Joined: Thu Mar 19, 2009 12:40 am
Location: Haarlem, NL
Contact:

Post by Twoflower »

Just checked it and I can verify that NM05-NM08 are the dungeon-wall gfx. The colorcoding seems to be stored in the main-program though, not in the graphics-files. If you for instance loads the graphics to Mangars Tower in the Sewers, you'll get sewer-colored Mangar-walls.
/Twoflower
User avatar
ZeroZero
Posts: 286
Joined: Tue Mar 10, 2009 9:10 pm
Location: Germany

Post by ZeroZero »

Twoflower wrote:The main program uses a JSR to $B600 as entrypoints to certain locations like Kylearan's Tower, Garth's, The Guild, the Sewers, etc.
Just load the correct adress in A and do a JSR.
I thought I mailed you that the city events are loaded to B600 instead of BB00, so just + $8000 from file load address. Else they are simply like dungeon events, same logic, same text offsets and everything.

What do we do about the dungeon wall colors, can anything be done? Btw, if you change wall set by changing the byte in the dungeon layout, it changes perfectly both, walls and color. Anyway color table and walls file seem to be related to each other. Good job here!
User avatar
Twoflower
Posts: 128
Joined: Thu Mar 19, 2009 12:40 am
Location: Haarlem, NL
Contact:

Post by Twoflower »

Yep, I guess that the color of the dungeon walls are set by either by a colortable in the dungeon-program or a subroutine which you call with the colors stored in the accumulators A,X and Y (or more probably two of these). From what I can understand from the graphics, you have a standard color-setup (dark blue, red and white), and then you can choose to "wash" the graphics with certain colorsets - like f.ex replacing the red with green. Take Garth's Equipment Shoppe as an example.

EDIT:

The colors are definitly set in a table located in the main program. If you replace the Garth-graphics with another graphicsfile, it renders it green.
I guess I need to follow the $0803 routine to see where it fetches the colors. The changes might even be limited to one single color, but i'm not sure about that.


EDIT 2:

Found it! There is a table setting the two colors for each file, located at $0D99. "26" will render the image white, red and blue. "58" will render it white, green and orange. I bet there is a similar one in the dungeon-engine which sets the wall-colors. What worries me about the above table is that it is limited to 48 values. :-/ On the positive side - this means that imported graphics from f.ex BT II and III easily can be washed in the correct colors.
/Twoflower
User avatar
ZeroZero
Posts: 286
Joined: Tue Mar 10, 2009 9:10 pm
Location: Germany

Post by ZeroZero »

Excellent job!
User avatar
Twoflower
Posts: 128
Joined: Thu Mar 19, 2009 12:40 am
Location: Haarlem, NL
Contact:

Post by Twoflower »

Well, it don't stop there. I have been examining NM04 a bit closer and i've also managed to locate that the city-setup is much the same in BT II. Right now I believe I can state the following:

1) The BT II city graphics can be applied almost directly to Skara Brae. I've ripped out the same part of the memory from BT II and have managed to get the city graphics to work quite allright (house-facades, etc). EDIT: I have now managed to transfer the city-graphics from Tangramayne, and it works decently. Something isn't as it should, but I can't really tell. Shall look into it a little more and then put up a diskimage for you folks.

2) The problem is that some kind of city event table are located in NM04 aswell. The city graphics seems to be located at the first 1800 bytes of NM04, and the tables for the city-events are located after that. I haven't really looked up how they work. Some in-depth analyzis of this file should give some answers. EDIT: I should really learn to think before I post. Looking closely at the data after the graphics - this must be the city map, in two incarnations?. It matches 30X30 = 384 bytes - and i've just checked that the bytes align with the graphical map perfectly.

The map for the graphical representation is the first one - it runs from start to end, 30 bytes a row. One char per building/space. Tangramayne, here I come. .-)
/Twoflower
User avatar
Twoflower
Posts: 128
Joined: Thu Mar 19, 2009 12:40 am
Location: Haarlem, NL
Contact:

Post by Twoflower »

Well. As the rest of you probably did know, Tangramayne and the other cities in BT II are dungeon-sized (16X16). Mere villages compared to Skara Brae. If you are interested, they are loaded onto $C400 in BT II, followed by the wilderness which is much too big (32X48, as I could understand). :-)

All quite unusable for this project.

Eventhough the BT II maps proved unusable, I did some edits on the Skara Brae-map - and now I got three Guilds in a row. Yay. Only problem is that you end up outside the middle one no matter which one you exit.
/Twoflower
User avatar
ZeroZero
Posts: 286
Joined: Tue Mar 10, 2009 9:10 pm
Location: Germany

Post by ZeroZero »

Where you end up will depend from the exit coordinates... I assume that you must check within the Guild event, on what square you are and move the party accordingly, how else would you get out of any tavern in the right place...
User avatar
Twoflower
Posts: 128
Joined: Thu Mar 19, 2009 12:40 am
Location: Haarlem, NL
Contact:

Post by Twoflower »

ZeroZero:

You're right. I didn't really concider that the game only was constructed for having one fixed Guild.
I figure that the Guild event could be rewritten to mirror the taverns behavior. But now...

A short summary of the NM04 file:

Code: Select all

1000 - 1D00 - City 3D graphics.
1D00 - 1F00 - NM5A
1F00 - 2100 - NM5B
2100 - 2300 - NM5C
2300 - 2516 - NM5D
2516 - 2600 - Trash. Can probably be zeroed out.
2600 - 2800 - No idea. Byte by byte identical in BT2.
2800 - 2B84 - Visual 30X30 city map.
2C00 - 2f84 - Event 30X30 city map.
This file loads itself to E000. I figure that the NM-files might be replaced by their night-varieties when night falls.
/Twoflower
User avatar
ZeroZero
Posts: 286
Joined: Tue Mar 10, 2009 9:10 pm
Location: Germany

Post by ZeroZero »

As for the NM04 city maps, I checked them before and it seems that the first map, which, other than the dungeons, is build up north to south, not south to north, reflects the buildings and empty spaces, while the second map has the street name flags and probably the event flags... would be interesting to find out, how the teleport is made on sinister street... I am afraid we are missing a table here UNLESS that is an unique occurance and hardcoded in main.
@ Twoflower
I like to stress your attention onto the 6k hidden file on the boot disk. It contains essential parts of the BT OS/engine. If we want to extend the events table, we must reassemble that file with new offsets, IF there is some space left in it at all... Dang we are close before disassembling the whole stuff and remake it, rofl. The garbage in the NM04 might be a placeholder for stuff to be loaded there later, e.g. the cities event tables, from whatever file that might be. As well we still lack the monsters and items, so I will have a look into NM02.... if that fails only the main stuff is left... :(
User avatar
Darendor
Posts: 1502
Joined: Wed Jan 14, 2009 1:53 am
Location: Red Deer, Alberta, Canada

Post by Darendor »

You guys have been quite busy!
Twoflower wrote:Well. As the rest of you probably did know, Tangramayne and the other cities in BT II are dungeon-sized (16X16). Mere villages compared to Skara Brae. If you are interested, they are loaded onto $C400 in BT II, followed by the wilderness which is much too big (32X48, as I could understand). :-)

All quite unusable for this project.

Eventhough the BT II maps proved unusable, I did some edits on the Skara Brae-map - and now I got three Guilds in a row. Yay. Only problem is that you end up outside the middle one no matter which one you exit.
Horpner and I were discussing making the 8 Bit Editor for the BTII engine, rather than the BTI engine as BTII is larger and more advanced.

Do you two feel that this is still viable, or did you want to focus on the BTI engine?
User avatar
ZeroZero
Posts: 286
Joined: Tue Mar 10, 2009 9:10 pm
Location: Germany

Post by ZeroZero »

well after all BT II offers wilderness too.... but the cities are smaller like villages.... Is BT III the same engine as BT II or larger wilderness and larger cities?
User avatar
Darendor
Posts: 1502
Joined: Wed Jan 14, 2009 1:53 am
Location: Red Deer, Alberta, Canada

Post by Darendor »

ZeroZero wrote:well after all BT II offers wilderness too.... but the cities are smaller like villages.... Is BT III the same engine as BT II or larger wilderness and larger cities?
BTIII is radically different. Better, but slower in some ways.

It's more complex. :?
User avatar
ZeroZero
Posts: 286
Joined: Tue Mar 10, 2009 9:10 pm
Location: Germany

Post by ZeroZero »

I updated the file list. NM02 turned out to be the other half of the BT OS routines from ae00. The first part with the 0800 is in the hidden file of 6k. This leaves the impression, that the "main program" is merely a data container with all data we miss yet, items, monsters, spells etc etc.
User avatar
Darendor
Posts: 1502
Joined: Wed Jan 14, 2009 1:53 am
Location: Red Deer, Alberta, Canada

Post by Darendor »

ZeroZero wrote:I updated the file list. NM02 turned out to be the other half of the BT OS routines from ae00. The first part with the 0800 is in the hidden file of 6k. This leaves the impression, that the "main program" is merely a data container with all data we miss yet, items, monsters, spells etc etc.
Does this mean the event table is split across both files too?
User avatar
Twoflower
Posts: 128
Joined: Thu Mar 19, 2009 12:40 am
Location: Haarlem, NL
Contact:

Post by Twoflower »

Darendor wrote:You guys have been quite busy!

---

Horpner and I were discussing making the 8 Bit Editor for the BTII engine, rather than the BTI engine as BTII is larger and more advanced.

Do you two feel that this is still viable, or did you want to focus on the BTI engine?
To be honest - i'd love to focus on the BT II engine, and in all honesty - everything we do on a BT I editor can be used on BT II, with modifications in size as about the only different aspect to concider. Everything is similar and easy to grasp since most stuff are variations of BT I. A city editor does only need to have the size changed - I actually concidered to manually edit Tangramayne into the center of Skara Brae today.

Bard's Tale III is even better. That engine is outright brilliant and I believe you actually could make near-perfect emulations of the first two games in that one, although with a way better engine. This one seems to add a new level of complexity, though, and much work needs to be done from scratch.

But - there is a problem.

The reason why things have progressed rapidly with the Bard's Tale I engine is mainly that we have access to the files. The filesystem is open, we can see what does what and we know where files start and end. This is not the case with Bard's Tale II, which is completely protected by Pirateslayer. There are no track/sectorchain to follow, everything on the disks are encoded and everything hangs up if you attempt to use a freezer. My extractions from that engine so far is based on qualified guesses and approximations.

To be able to work with the BT II engine we need all the files. All cracks so far have worked with the copy-protection and have circumvented it rather than removing it. To make things worse, I only know 4 persons who have cracked this kind of really nasty protection (Fungus, Sailor, GRG and Antitrack) and I don't think I could raise intrest in any of them in doing this. BT III is similarly closed, and is protected by Prodos and the codewheel. I know of one crack with codewheel removal and non which have removed the copy-protection. The only viable option is recieving the unprotected files for these games from an infrequent forumvisitor we all admire. .-)
/Twoflower
Post Reply