PoP1-Total Pack: New version development

A user-friendly interface for downloading, tweaking and playing mods.
User avatar
starwindz
Sultan
Sultan
Posts: 133
Joined: March 8th, 2009, 4:48 pm

Re: PoP1-Total Pack: New version development

Post by starwindz »

salvadorc17 wrote:Can you explain more of the mod maker?? this does also include snes version??
Development of Mod Maker is currently suspended. But instead of Mod Maker, I am planning to develop new 'Random level generator for SNES PoP1' (It would be included to Total Pack 4.0.)

However, there are some technical issues for programming Total Pack since SNES rom image is compressed and I am not good at use C++ or C#. (I am using Delphi for developing Total Pack).
1. It is very difficult to modify levels data such as Level 1, 2 and so on in Delphi programming.
2. It is very difficult to modify level setting such as level type, music and guard type in Delphi programming.
3. It is very difficult to modify hack data in Delphi programming.
(Above features are already done in SNES level editor)

Therefore, following three command-line utilities are needed for above features. Following ultities can be run externally under Total Pack.
1. snes_levels.exe export [rom_image] [level_name] [level_filename]
snes_levels.exe import [rom_image] [level_name] [level_filename]
(ex) snes_levels.exe export PoP1_EU_headered.smc "LEVEL 1" level1.dat
(ex) snes_levels.exe import PoP1_EU_headeres.sms "LEVEL 1" level1.dat
2. snes_setting [rom_image] [level setting file]
(ex) snes_setting.exe PoP1_EU_headeres.sms level_setting.ini
3. snes_hack [rom_image] [hack seeting file]
(ex) snes_hack.exe PoP1_EU_headeres.sms hack.ini

If you provide me the above utilities, technical issues will be solved for me to develop new random level generator for SNES PoP1.
How about that? and could you join me this project?

(P.S.) Furthermore all snes mods would be run under the next version of total pack. (Maybe 4.01 or something...)
salvadorc17
Calif
Calif
Posts: 553
Joined: August 27th, 2011, 2:04 am

Re: PoP1-Total Pack: New version development

Post by salvadorc17 »

starwindz wrote:
However, there are some technical issues for programming Total Pack since SNES rom image is compressed and I am not good at use C++ or C#. (I am using Delphi for developing Total Pack).

(P.S.) Furthermore all snes mods would be run under the next version of total pack. (Maybe 4.01 or something...)

That is not even needed to achieve, all mods edited with David PR1Snes editor have uncompressed level data, only the original rom is the one that need to care about decompression. So will be easy to use a default version to achieve the level generator, instead i will recommend try to get hex editing to modify snes version general settions like for Dos version.
User avatar
starwindz
Sultan
Sultan
Posts: 133
Joined: March 8th, 2009, 4:48 pm

Re: PoP1-Total Pack: New version development

Post by starwindz »

salvadorc17 wrote:That is not even needed to achieve, all mods edited with David PR1Snes editor have uncompressed level data, only the original rom is the one that need to care about decompression.
Really? I heard that snes levels in the rom file are compressed. (Please refer to this link, http://www.princed.org/wiki/SNES_format#Levels ) Anyway I will check it out again. Thank you.
salvadorc17 wrote:Can you explain more of the mod maker?? this does also include snes version??
Total pack 4.0 WILL have snes mod support such as the attached screenshot. :)
Attachments
snes support 1.png
snes support 2.png
snes support 3.png
David
The Prince of Persia
The Prince of Persia
Posts: 2846
Joined: December 11th, 2008, 9:48 pm
Location: Hungary

Re: PoP1-Total Pack: New version development

Post by David »

salvadorc17 wrote: That is not even needed to achieve, all mods edited with David PR1Snes editor have uncompressed level data, only the original rom is the one that need to care about decompression.
Not true, all PoP1 SNES mods have compressed level data.
However, the editor can export/import levels to/from an uncompressed form.
starwindz wrote: 2. It is very difficult to modify level setting such as level type, music and guard type in Delphi programming.
3. It is very difficult to modify hack data in Delphi programming.
Those are not compressed.
starwindz wrote: snes_levels.exe export [rom_image] [level_name] [level_filename]
snes_levels.exe import [rom_image] [level_name] [level_filename]
I will try to make something like that now...
David
The Prince of Persia
The Prince of Persia
Posts: 2846
Joined: December 11th, 2008, 9:48 pm
Location: Hungary

Re: PoP1-Total Pack: New version development

Post by David »

Here is the program I made. (C source + Windows EXE)
SNES_level_export_import.zip
(11.99 KiB) Downloaded 166 times
While making this, I also found a small bug in the compression algorithm of Pr1SnesLevEd:
The "sequence of identical/increasing/decreasing bytes" cases skipped the last byte (i.e. the "count" was 1 less than it should have been).
This did not cause any visible error, only the compressed data was not as small as it could be.

The zip also contains a test_all.bat/sh that exports all levels, imports them, re-exports them, and compares the two exports.
User avatar
starwindz
Sultan
Sultan
Posts: 133
Joined: March 8th, 2009, 4:48 pm

Re: PoP1-Total Pack: New version development

Post by starwindz »

David wrote:
starwindz wrote: 2. It is very difficult to modify level setting such as level type, music and guard type in Delphi programming.
3. It is very difficult to modify hack data in Delphi programming.
Those are not compressed.
Oh, now I can understand it. I can hex-edit those settings in programming side.( viewtopic.php?p=10846#p10846 ) Thank you. :)
David wrote: Here is the program I made. (C source + Windows EXE)
SNES_level_export_import.zip
Thank you VERY MUCH for your quick help. It is a great help for me! :)
David wrote:Re: [HELP] Level conversion from PC to SNES for Total Pack
Postby David » November 6th, 2011, 7:34 pm

... the block_xx arrays define the 256 foreground tiles.

block_fg[256] determines what graphics to use in the layer behind the prince, but in front of the background. (3rd dropdown in the editor)
block_gg[256] determines what graphics to use in the layer in front of the prince. (4th dropdown)
block_object[256] determines what object (trap, potion, door etc.) does this tile have. For a list of object IDs see the source (the string array called "ob"). (the dropdown above the checklistbox)
block_flags_back_anim[256] determines whether this tile has a floor (1), a wall (2), or none of them (0). (the checklistbox)

foreground[24][3][10] determines for each tile of each room, which of these foreground tiles should be used. (1st dropdown)
background[24][3][10] determines the background graphics. (2nd dropdown)
modifiers[24][3][10] determines the modifier, used e.g. for buttons. (rightmost dropdown)
David wrote: From the source code of smc.h in Snes Level Editor

typedef struct{
byte background[24][3][10];
byte foreground[24][3][10];

byte modifiers[24][3][10];
byte block_gg[256];
byte block_fg[256];
byte block_object[256];
byte block_flags_back_anim[256]; // bottom 3 bits: block flags, top 6 bits: background animation group
...
}TLevel;
Unfortunately, I am still confused of level data mechanism of snes PoP1. I SHOULD understand it completely in order to make the snes random level generator.
And also is there some document of a tile combo table for snes version such as http://www.princed.org/wiki/Legacy_combos ?[/b]
Last edited by starwindz on March 20th, 2017, 7:16 am, edited 2 times in total.
salvadorc17
Calif
Calif
Posts: 553
Joined: August 27th, 2011, 2:04 am

Re: PoP1-Total Pack: New version development

Post by salvadorc17 »

[quote="David"
Not true, all PoP1 SNES mods have compressed level data.
However, the editor can export/import levels to/from an uncompressed form.
[/quote]

Yes, thats what i was talking about, when you import the uncompressed level data, you get to have that into the rom as uncompressed form, that way you can edit with other editor, i have tried myself here:

viewtopic.php?f=76&t=3975
User avatar
starwindz
Sultan
Sultan
Posts: 133
Joined: March 8th, 2009, 4:48 pm

Re: PoP1-Total Pack: New version development

Post by starwindz »

I have made some kind of analysis program to understand snes level data. Now I can understand the basic concept of structure of the level data such as the attached screenshot.
Attachments
capture1.PNG
User avatar
starwindz
Sultan
Sultan
Posts: 133
Joined: March 8th, 2009, 4:48 pm

Re: PoP1-Total Pack: New version development

Post by starwindz »

SNES Level Data Analyzer v2 has been done.
Attachments
capture2.PNG
salvadorc17
Calif
Calif
Posts: 553
Joined: August 27th, 2011, 2:04 am

Re: PoP1-Total Pack: New version development

Post by salvadorc17 »

starwindz wrote:SNES Level Data Analyzer v2 has been done.
Really interesting progress, i think this information deserves to be on the other topic i made about asking for total pack in snes..
User avatar
starwindz
Sultan
Sultan
Posts: 133
Joined: March 8th, 2009, 4:48 pm

Re: PoP1-Total Pack: New version development

Post by starwindz »

salvadorc17 wrote:
starwindz wrote:SNES Level Data Analyzer v2 has been done.
Really interesting progress, i think this information deserves to be on the other topic i made about asking for total pack in snes..
I agree. Even though this development would be included to Total Pack, but it is quite a SNES-specific. So I will write some posts to SNES topic. Thank you. :)
salvadorc17
Calif
Calif
Posts: 553
Joined: August 27th, 2011, 2:04 am

Re: PoP1-Total Pack: New version development

Post by salvadorc17 »

starwindz wrote: I agree. Even though this development would be included to Total Pack, but it is quite a SNES-specific. So I will write some posts to SNES topic. Thank you. :)
Will be good to create topic for the tool with download and all info included.
User avatar
starwindz
Sultan
Sultan
Posts: 133
Joined: March 8th, 2009, 4:48 pm

Re: PoP1-Total Pack: New version development

Post by starwindz »

Total Pack 3.5 has been released.

* Download link
https://drive.google.com/file/d/0Bw07W8 ... sp=sharing

* Changelog
Version history of PoP1-Total Pack
==================================

Below you find a list with the added features, changes and fixes for
each version.


Version 3.5 (2017.04.09)
-----------------------------
- Add: Support SNES Mods
- Add: Custom graphics(Dungeon, Palace, Character) (Princess of Persia)
- Fix: Search feature of User created media(YouTube) now works properly
- Enhancement: Change diffpop.exe option => start diffpop.exe with --locations or -l
- Enhancement: No longer needs to 'manually' add the original game


Version 3.01 (2017.03.03)
-------------------------
- Fix: Total pack now works properly for new mods.xml
- Fix: Mod 0000141(King of Persia) now run properly (Direct run Windows batch file)
- Fix: Mod 0000153(Secrets of Citadel) now run properly (Direct run SDLPoP.exe)
- Enhancement: Change "Use Original Graphics" to "Use Official Graphics"


Version 3.0 (2013.09.23)
------------------------
- Official release of Version 3.0


Version 3.0b1 (2013.09.13)
--------------------------
- Pre-release of Version 3.0


* End of document
User avatar
Norbert
The Prince of Persia
The Prince of Persia
Posts: 5743
Joined: April 9th, 2009, 10:58 pm

Re: PoP1-Total Pack: New version development

Post by Norbert »

I've also added it to popot.org.
malvivio
Sheikh
Sheikh
Posts: 22
Joined: March 1st, 2017, 10:41 am

Re: PoP1-Total Pack: New version development

Post by malvivio »

What a surprise Total Pack 3.5.... so this still isn't the 4.0

Is it true now we can download also King of Persia and Secrets of the citadel being able to play from Total Pack? Both 3.01 and 3.5??
Some bugs still remain also from 3.5 (Prince being cut in chompers after gone throw the door in levels 5 and 8 in New 13 Levels playing it from the start)

I see in 3.5 there are also SNES levelsets but still unable to play them also with Total Pack, so I guess this is not the final version, it's in the middle; that's why it's named 3.5
Post Reply