Does SDLPoP recording works when cheats on?
Does SDLPoP recording works when cheats on?
Hi,
I noticed that my recording does not work with cheats on, at least in this example.
My intention was to obtain something like this (captured via dosbox):
I noticed that my recording does not work with cheats on, at least in this example.
My intention was to obtain something like this (captured via dosbox):
- atrueprincefanfrom18
- Site Shah
- Posts: 1786
- Joined: January 21st, 2020, 2:53 pm
- Contact:
Re: Does SDLPoP recording works when cheats on?
You would have to turn the cheats on with Backspace -> General -> Turn cheats on (or something similar). SDLPoP replays all the inputs so if you press "R" to Revive Prince, as the game doesn't have cheats enabled, it won't happen.
Hope that helped?
Hope that helped?
Re: Does SDLPoP recording works when cheats on?
So I launch the .p1r file, pause it before the prince starts running and enable cheats. but still he falls down and dies. did my .p1r file work for you?
- atrueprincefanfrom18
- Site Shah
- Posts: 1786
- Joined: January 21st, 2020, 2:53 pm
- Contact:
Re: Does SDLPoP recording works when cheats on?
Enable cheats, CTRL + R, and then load the file.
No I didn't try it running even though I downloaded it.
Is it possible to just double click it and run it directly in SDLPoP on Linux? I'm using Ubuntu 18.04.
No I didn't try it running even though I downloaded it.
Is it possible to just double click it and run it directly in SDLPoP on Linux? I'm using Ubuntu 18.04.
Re: Does SDLPoP recording works when cheats on?
No, SDLPoP does not (currently) record cheat keys, therefore it can't play them back.atrueprincefanfrom18 wrote: ↑July 20th, 2020, 10:57 am You would have to turn the cheats on with Backspace -> General -> Turn cheats on (or something similar). SDLPoP replays all the inputs so if you press "R" to Revive Prince, as the game doesn't have cheats enabled, it won't happen.
Right-click any P1R file, then select "Open with..." or "Open With Other Application..." (or something similar).atrueprincefanfrom18 wrote: ↑July 21st, 2020, 5:22 am Is it possible to just double click it and run it directly in SDLPoP on Linux? I'm using Ubuntu 18.04.
In the window that opens, browse to the SDLPoP executable.
I think you also need to check a checkbox saying you always want to open this type of file with this application.
(Sorry for being so uncertain, but I don't have any Linux installed currently, so I'm writing this from memory.)
- atrueprincefanfrom18
- Site Shah
- Posts: 1786
- Joined: January 21st, 2020, 2:53 pm
- Contact:
Re: Does SDLPoP recording works when cheats on?
Oh, I remember playing them back, but it's not clear to me yet. But if you confirm, then it should be true. So I am sorry for wrong info supplied...
Don't know how that's done. If you find a demonstration video, please let me know.David wrote: ↑July 25th, 2020, 10:16 am[...]atrueprincefanfrom18 wrote: ↑July 21st, 2020, 5:22 am Is it possible to just double click it and run it directly in SDLPoP on Linux? I'm using Ubuntu 18.04.
Re: Does SDLPoP recording works when cheats on?
At what point are you stuck?atrueprincefanfrom18 wrote: ↑July 25th, 2020, 2:07 pm Don't know how that's done. If you find a demonstration video, please let me know.
Anyway, I tried this on a computer with XUbuntu installed.
(It's like Ubuntu but with XFCE. This might mean that the things on my screenshots don't match your OS.)
There the menu item is called "Open With Other Application...". The window which it opens looks like this: At the bottom it's possible to use a custom command. I entered the full path to the SDLPoP executable there (not shown).
However! As the text at the top says, clicking "Open" now will associate SDLPoP with all "unknown" files, not just *.p1r files!
To add a new filetype for *.p1r files, do the following:
(Note: This is new for me as well. I figured things out from web searches, man pages, and from the existing files under ~/.local/share/mime/ .)
Create a file called user-extension-p1r.xml with the following content:
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<mime-info xmlns="http://www.freedesktop.org/standards/shared-mime-info">
<mime-type type="application/x-extension-p1r">
<comment>SDLPoP replay file</comment>
<glob pattern="*.p1r"/>
</mime-type>
</mime-info>
Code: Select all
xdg-mime install user-extension-p1r.xml
Code: Select all
xdg-icon-resource install --context mimetypes --size 32 SDLPoP/data/icon.png application-x-extension-p1r
The association can also be done with a command if SDLPoP has a desktop file installed:
Code: Select all
xdg-mime default /usr/share/applications/SDLPoP.desktop application/x-extension-p1r
Code: Select all
xdg-mime default ~/.local/share/applications/SDLPoP.desktop application/x-extension-p1r
I guess I should add this to make install.
Update: I did it on a new branch: https://github.com/NagyD/SDLPoP/commit/ ... 23492fa373
By the way, make install is usually ran with sudo.
But if I run the above xdg-mime install command with sudo then it takes a rather long time.
I'm not sure why, maybe this way it looks through the system-wide installed filetypes?
For this reason, I changed the location of the SDLPoP.desktop file to the per-user path in the commit above so it can be used without sudo.
Re: Does SDLPoP recording works when cheats on?
I also had problems with recordings when I introduced a key to manually take out and quickly take down the sword. It also did not replay kid's moves correctly with fake tiles implemented in the SDLPoP code. So I had to disable it in my mod.
- atrueprincefanfrom18
- Site Shah
- Posts: 1786
- Joined: January 21st, 2020, 2:53 pm
- Contact:
Re: Does SDLPoP recording works when cheats on?
Maybe because the new key doesn't get written/recorded in p1r file? We don't even know the format of p1r. Maybe David could explain it?
Re: Does SDLPoP recording works when cheats on?
New keys are not recorded automatically into the P1R file.atrueprincefanfrom18 wrote: ↑January 3rd, 2021, 7:16 amMaybe because the new key doesn't get written/recorded in p1r file?
Any new key has to be explicitly handled when recording and when playing back.
You can see here how I made SDLPoP record and replay such a key.
I made a short documentation based on the SDLPoP source.atrueprincefanfrom18 wrote: ↑January 3rd, 2021, 7:16 am We don't even know the format of p1r. Maybe David could explain it?
See the attachment.
Can you post an example?