Changing the prince

Discussions about all other tools (CusPop, SAV/HOF editors) and hex editing.
Post Reply
ShaggyNerd
Scholar Scribe
Scholar Scribe
Posts: 1
Joined: June 20th, 2011, 1:13 am

Changing the prince

Post by ShaggyNerd »

Is there a tool that will let me edit how the prince himself (kid.dat) and the sword looks, possibly like a Microsoft Paint type of a thing? Everybody uses all these level editors (don't get me wrong, these are cool), but where are are the object editors? Thanks if you can find (or make) one!
User avatar
Norbert
The Prince of Persia
The Prince of Persia
Posts: 5745
Joined: April 9th, 2009, 10:58 pm

Re: Changing the prince

Post by Norbert »

User avatar
Norbert
The Prince of Persia
The Prince of Persia
Posts: 5745
Joined: April 9th, 2009, 10:58 pm

Re: Changing the prince

Post by Norbert »

The following is not meant as an actual suggestion. Merely a flight of fancy.
ShaggyNerd wrote: June 20th, 2011, 1:57 amIs there a tool that will let me edit how the prince himself (kid.dat) [...]
I don't know if maybe I already created a thread or post about this the the past, but in theory a program should be able to auto-generate all the prince (kid) images after reading and processing only a single (2D) base image of the prince. The standing pose (SDLPoP's data/KID/res415.png or PR export's kid/normal.bmp) could be a suitable base image, although it only includes two limbs of the prince, which means a running frame might be a better pick. For each target image, the movement - and possibly dual usage, or removal - of each pixel from the base image would need to be decided.

Code: Select all

/*** http://sdl.beuc.net/sdl.wiki/Pixel_Access ***/
SDL_Surface *image = IMG_Load ("in.png");
/*** Lock and unlock may not be necessary if (SDL_MUSTLOCK (*surface) == 0). ***/
SDL_LockSurface (SDL_Surface *surface);
/*** Read/write surface->pixels, using the surface->format pixel format. ***/
SDL_UnlockSurface (SDL_Surface *surface);
IMG_SavePNG (image, "out.png");
SDL_FreeSurface (image);
This would be pretty insane to implement in practice, but I think it's interesting to contemplate whether this would be possible in theory.
Attachments
pixel_movement.png
pixel_movement.png (1.33 KiB) Viewed 2539 times
David
The Prince of Persia
The Prince of Persia
Posts: 2848
Joined: December 11th, 2008, 9:48 pm
Location: Hungary

Re: Changing the prince

Post by David »

Norbert wrote: January 12th, 2019, 2:58 pm I don't know if maybe I already created a thread or post about this the the past, but in theory a program should be able to auto-generate all the prince (kid) images after reading and processing only a single (2D) base image of the prince.
Yes, you have already posted about this here: viewtopic.php?p=22351#p22351
I have even responded to it. :)
User avatar
Norbert
The Prince of Persia
The Prince of Persia
Posts: 5745
Joined: April 9th, 2009, 10:58 pm

Re: Changing the prince

Post by Norbert »

David wrote: January 13th, 2019, 12:21 pmYes, you have already posted about this here: viewtopic.php?p=22351#p22351
I have even responded to it. :)
Oh, yeah.
I vaguely remembered writing about it, but couldn't find the post.
I see it was the "Various" thread.
Post Reply