legbop 0.9

Discuss other PoP1 related things here.
User avatar
Norbert
The Prince of Persia
The Prince of Persia
Posts: 5761
Joined: April 9th, 2009, 10:58 pm

legbop 0.9

Post by Norbert »

Here's legbop, the level editor of Prince of Persia for the Game Boy Color.

Download links for version 0.9:
- Windows (mirror)
- GNU/Linux (mirror)

Two things I want to add for version 1.0 are:
1. Add a way to modify guard skills on the EXE screen. These skills are not part of the regular level data, I haven't found their offsets in the ROM yet.
2. For playtesting, launch straight into the active level. I'll ask Kaslghnoon, who helped me with something similar last year, about this; or maybe someone else knows.
salvadorc17
Calif
Calif
Posts: 553
Joined: August 27th, 2011, 2:04 am

Re: legbop 0.9

Post by salvadorc17 »

Good work, is really an apoplexy clone, easy to use for tiles..
David
The Prince of Persia
The Prince of Persia
Posts: 2863
Joined: December 11th, 2008, 9:48 pm
Location: Hungary

Re: legbop 0.9

Post by David »

A custom tiles button would be useful.
User avatar
Norbert
The Prince of Persia
The Prince of Persia
Posts: 5761
Joined: April 9th, 2009, 10:58 pm

Re: legbop 0.9

Post by Norbert »

David wrote:A custom tiles button would be useful.
Unless I misunderstand you, this is what you can use:

Image
(image mirror)
David
The Prince of Persia
The Prince of Persia
Posts: 2863
Joined: December 11th, 2008, 9:48 pm
Location: Hungary

Re: legbop 0.9

Post by David »

Umm, yes. I guess I was expecting the gear button...
salvadorc17
Calif
Calif
Posts: 553
Joined: August 27th, 2011, 2:04 am

Re: legbop 0.9

Post by salvadorc17 »

Can you help me finding the hex values for the game, so i can use to make achievements for Retro achievements site: http://retroachievements.org/Game/1402
User avatar
Norbert
The Prince of Persia
The Prince of Persia
Posts: 5761
Joined: April 9th, 2009, 10:58 pm

Re: legbop 0.9

Post by Norbert »

salvadorc17 wrote:Can you help me finding the hex values for the game, so i can use to make achievements for Retro achievements site: http://retroachievements.org/Game/1402
I don't know how (and I'm busy with other things), sorry...
By the way, for various things the Game Boy version may not be the same as the Game Boy COLOR version. ;)
David
The Prince of Persia
The Prince of Persia
Posts: 2863
Joined: December 11th, 2008, 9:48 pm
Location: Hungary

Re: legbop 0.9

Post by David »

salvadorc17 wrote:Can you help me finding the hex values for the game, so i can use to make achievements for Retro achievements site: http://retroachievements.org/Game/1402
Do you mean things like "Where is the current level number stored in RAM?" and the like?

They have some tutorials about how to make new achievements, by the way: http://retroachievements.org/viewforum.php?f=5
salvadorc17
Calif
Calif
Posts: 553
Joined: August 27th, 2011, 2:04 am

Re: legbop 0.9

Post by salvadorc17 »

David wrote: Do you mean things like "Where is the current level number stored in RAM?" and the like?

They have some tutorials about how to make new achievements, by the way: http://retroachievements.org/viewforum.php?f=5
Yes, i know about that, i have made achieves for my snes mod Castle Evolution, just wanted to know Norbert info about game values, so i can easy make for the Gbc version..
David
The Prince of Persia
The Prince of Persia
Posts: 2863
Joined: December 11th, 2008, 9:48 pm
Location: Hungary

Re: legbop 0.9

Post by David »

I think the formats of the GBC version should be documented on Princed Wiki as well.
Like the DOS, SNES, and SEGA Genesis versions already are: http://www.princed.org/wiki/Documents
(I edited that page just now, to separate DOS stuff from others.)
User avatar
Norbert
The Prince of Persia
The Prince of Persia
Posts: 5761
Joined: April 9th, 2009, 10:58 pm

Re: legbop 0.9

Post by Norbert »

David wrote:I think the formats of the GBC version should be documented on Princed Wiki as well.
Yes, another item on the/my TODO list.
David
The Prince of Persia
The Prince of Persia
Posts: 2863
Joined: December 11th, 2008, 9:48 pm
Location: Hungary

Re: legbop 0.9

Post by David »

Norbert wrote:
David wrote:I think the formats of the GBC version should be documented on Princed Wiki as well.
Yes, another item on the/my TODO list.
I already started it: viewtopic.php?p=20009#p20009

By the way, the editor should not put a 0xFF tile in the top-left corner of empty rooms.
User avatar
Norbert
The Prince of Persia
The Prince of Persia
Posts: 5761
Joined: April 9th, 2009, 10:58 pm

Re: legbop 0.9

Post by Norbert »

David wrote:I already started it: viewtopic.php?p=20009#p20009
In its "Various hacks" section, the article contains a footnote "found in the "First One" mod by Norbert". You appear to have made a conscious decision to document where/how the location of these particular bytes was found. Did you mean to write "modified in" instead of "found in"? If you meant "modified", I think maybe it's unnecessary to document who modified certain bytes in which mods. If you meant "found", it reads as if the writer (you) is documenting where he found the information. This begs the question: is this a general article about the GB(C) format or does it also document the writer's personal quest? If it's not about the writer, the footnote is still peculiar. Is it supposed to document where information was first found, regardless of the initial discoverer? If we're documenting who found what where when - which I do not object to - legbop's release date and lack of any other public documents/files at the time could also be mentioned.
David wrote:By the way, the editor should not put a 0xFF tile in the top-left corner of empty rooms.
I think maybe you mean "could be modified to not" instead of "should not"?
My code deliberately does not remove 0xFF tiles from empty rooms, and it adds them as soon as rooms are being moved into the side pane.
David
The Prince of Persia
The Prince of Persia
Posts: 2863
Joined: December 11th, 2008, 9:48 pm
Location: Hungary

Re: legbop 0.9

Post by David »

Norbert wrote:1. Add a way to modify guard skills on the EXE screen. These skills are not part of the regular level data, I haven't found their offsets in the ROM yet.
Do they even have different skills?

Actually, I found something that might be just that.
* 0x00041..0x00047: guard colors, indexed by HP
* 0x000BA..0x000CC: guard HPs, indexed by level
* 0x000CD..0x000DF: guard move(?) probability, indexed by level
* 0x000E0..0x000F2: guard move(?) delay, indexed by level

Norbert wrote:2. For playtesting, launch straight into the active level.
A bit late, but here it is:
1. First, change the level number for training: Change 0x0664 to the level number - 1 (from 0x10).
2. Then, force the game to start that level instead of the intro: Change 0x02E3 to C3 63 06 (from CD 5F 20).
3. To skip even the Red Orb screen: Change 0x023E to 18 19 (from 38 F7)

In the disassembly:

Code: Select all

1.
0663: 3E 10      LD A,10h ; level number - 1 <-- we change this
0665: EA 49 C1   LD (C149h),A ; current level (next-1)
0668: EA 4A C1   LD (C14Ah),A ; current level (curr)
066B: CD 70 20   CALL 2070h ; load level?
066E: C3 0C 08   JP 080Ch ; reset HP + start next level

2.
show credits loop:
02E3: CD 5F 20   CALL 205Fh ; read joypad 2 ; <-- we change this to JP 0663h
02E6: 20 58      JR NZ,0340h ; show language room

3.
wait before Red Orb scroll:
0232: 3E B4      LD A,B4h
0234: EA 0B C1   LD (C10Bh),A ; timer delay length
0237: 21 0B C1   LD HL,C10Bh
023A: FA 0A C1   LD A,(C10Ah) ; timer counter
023D: BE         CP A,(HL)
023E: 38 F7      JR C,0237h ; <-- we change this to JR 0259h
...
wait for keypress after Red Orb scroll:
0254: CD 5F 20   CALL 205Fh ; read joypad 2
0257: 28 FB      JR Z,0254h ; wait for keypress after Red Orb scroll
0259: CD D8 12   CALL 12D8h ; screen off
025C: AF         XOR A,A
025D: E0 42      LD (FF42h),A ; SCY - Scroll Y   (R/W)
EDIT: Updated the wiki: http://www.princed.org/wiki/Game_Boy_format
User avatar
Norbert
The Prince of Persia
The Prince of Persia
Posts: 5761
Joined: April 9th, 2009, 10:58 pm

Re: legbop 0.9

Post by Norbert »

Thanks.
It'll be a while before I look into legbop again, but when I do I'll use this information.
Locked