dribs and drabs

Ask and answer questions about making games and related topics. Unrelated topics go in that other forum.

Moderators: marionline, SDHawk

Post Reply
User avatar
sotrain515
Red Slime
Posts: 59
Joined: Wed Dec 26, 2012 3:23 pm

dribs and drabs

Post by sotrain515 »

1.) First, a general thank you to Bob and TMC for all their responses to my other threads (:slime-doffing-its-cap:)

2.) I might be crazy but I swear that the text slices in the slice collection editor used to automatically update their widths when you would type in/delete text from them. This made it much easier to line things up when they were set to be centered for example. When setting the text in the code (e.g. "set slice text(some_centered_text_slice, string:hello_world)"), the width *does* seem to update properly and the text centers as you would expect.

3.) I can't reliably reproduce this but I've seen a crashing error in custom sometimes when I am in the slice collection editor. It seems to crop up if I zip through the collections really fast (i.e. holding left or right when the slice collection number is highlighted) or when going from 0 left to whatever the highest numbered one is. (I am using etheldreme)

4.) Is there a "pad string to length" function (with option to supply the padding character)? I checked around in the plotscripting dictionary but did not see it.

Thanks again!
TMC
Metal King Slime
Posts: 4308
Joined: Sun Apr 10, 2011 9:19 am

Re: dribs and drabs

Post by TMC »

sotrain515 wrote:2.) I might be crazy but I swear that the text slices in the slice collection editor used to automatically update their widths when you would type in/delete text from them.
Sorry, RMZ already reported this one, no bughunting bounty points to award!

It's fixed as of two days ago.
3.) I can't reliably reproduce this but I've seen a crashing error in custom sometimes when I am in the slice collection editor. It seems to crop up if I zip through the collections really fast (i.e. holding left or right when the slice collection number is highlighted) or when going from 0 left to whatever the highest numbered one is. (I am using etheldreme)
Hmm, probably going to be really hard to track this one down. Has this happened only after actually using the slice editor to edit for a bit, or does it also happen right after entering the collection editor?
4.) Is there a "pad string to length" function (with option to supply the padding character)? I checked around in the plotscripting dictionary but did not see it.
There's no standard function. The closest thing to is is that "append number" has some options to add padding. I nearly added some script commands for padding

So you'll just have to use a script. Pretty easy to write. Do you want me to show you? Do you want left or right padding?
User avatar
sotrain515
Red Slime
Posts: 59
Joined: Wed Dec 26, 2012 3:23 pm

Post by sotrain515 »

I should be good on the padding script, thanks though!

As for the crashing, I'm not totally sure but it seems to be something that happens shortly after the first time I open up the collection editor. I've never seen it after a while being in the editor. It's either there within the first few "moves" I make with it or it doesn't show up at all.
User avatar
Bob the Hamster
Lord of the Slimes
Posts: 7658
Joined: Tue Oct 16, 2007 2:34 pm
Location: Hamster Republic (Ontario Enclave)
Contact:

Post by Bob the Hamster »

If the crash happens again, can you grab a screenshot of the error message (if any) and check the last few lines of c_debug.txt ?
TMC
Metal King Slime
Posts: 4308
Joined: Sun Apr 10, 2011 9:19 am

Post by TMC »

There could be something helpful in your c_debug_archive.txt file, if it hasn't been filled with lots of other stuff (it has a maximum size). But even if that were the case, the other error messages might be interesting!
c_debug_archive.txt gets appended to either if Custom crashed last time it ran (so didn't clean up its debug log), or if some significant error message was logged to it.
Last edited by TMC on Fri Feb 09, 2018 8:36 am, edited 2 times in total.
User avatar
sotrain515
Red Slime
Posts: 59
Joined: Wed Dec 26, 2012 3:23 pm

Post by sotrain515 »

Okay, I will post that stuff next time I see it.

Interestingly, the last few times I saw something like this, custom seemed to kind of freeze for a while on the slice collection menu and I thought "okay, here it comes, get your prntscrn ready" but eventually it came back and then worked normally. Not sure what's going on.
User avatar
sotrain515
Red Slime
Posts: 59
Joined: Wed Dec 26, 2012 3:23 pm

Post by sotrain515 »

Okay, got the crash again. This time I know exactly what I did.

1.) Opened custom.exe
2.) Loaded the game I'm working on (file named "a_tactics.rpg")
3.) Navigated right to Slice Collection Editor.
4.) In the Collection Editor moved down to the "<- Slice Collection ->" picker part.
5.) Typed "2", "6" as I wanted to navigate right to collection 26.
6.) Custom crashed right out to desktop with no error message.

Here's a copy of c_debug.txt:

Code: Select all

 ----Starting OHRRPGCE Custom----
02-16-2018 09&#58;36&#58;23
OHRRPGCE etheldreme 20171203.9852 gfx_directx+sdl+fb/music_sdl FreeBASIC 1.05.0 &#40;01-31-2016&#41; x86   Win32 32-bit
exepath&#58; C&#58;\Documents and Settings\msmithjones\Desktop\msmithjones\test, exe&#58; C&#58;\Documents and Settings\msmithjones\Desktop\msmithjones\test\custom.exe
Runtime info&#58;   music_sdl, SDL 1.2.15, SDL_Mixer 1.2.12  Windows 5.1.2600 &#40;XP&#41; Service Pack 3
documents_dir&#58; C&#58;\Documents and Settings\msmithjones\My Documents
Initialising gfx_sdl...
SDL&#58; screen size 1280x1024
setvideomode zoom=2 w*h = 640*400
gfx_sdl&#58; created screensurface size=640*400 depth=32 flags=0x0 R=0xFF0000 G=0xFF00 B=0xFF
gfx_sdl "SDL 1.2.15 &#40;0 joysticks&#41; Driver&#58;windib"
music_sdl, SDL 1.2.15, SDL_Mixer 1.2.12
unlock_resolution&#40;320,200&#41;
setvideomode zoom=2 w*h = 640*400
gfx_sdl&#58; created screensurface size=640*400 depth=32 flags=0x10 R=0xFF0000 G=0xFF00 B=0xFF
music_sdl, SDL_Mixer 1.2.12 &#40;22050Hz, Music decoders&#58;WAVE,MODPLUG,NATIVEMIDI,OGG,MP3 Sample decoders&#58;WAVE,AIFF,VOC,OGG&#41;
mersenne_twister seed=7000733.921703041
Working in C&#58;\Documents and Settings\msmithjones\Application Data\OHRRPGCE\working0.tmp
check_ok_to_open...
pid_current_exe = \Device\HarddiskVolume1\Documents and Settings\msmithjones\Desktop\msmithjones\test\custom.exe
prev_session.workingdir = C&#58;\Documents and Settings\msmithjones\Application Data\OHRRPGCE\working0.tmp
prev_session.info_file_exists = YES
prev_session.pid = 18944 &#40;exe = \Device\HarddiskVolume1\Documents and Settings\msmithjones\Desktop\msmithjones\test\custom.exe&#41;
prev_session.running = YES
prev_session.partial_rpg = NO
prev_session.fresh_danger_tmp = NO
prev_session.sourcerpg = 
prev_session.sourcerpg_old_mtime = 0
prev_session.sourcerpg_current_mtime = 0
prev_session.session_start_time = 2018 Feb 16 09&#58;36&#58;23
prev_session.last_lump_mtime = 0
end_debug&#58; no debug/error messages during startup &#40;skipping rest of startup&#41;

 ----Loading a game----
02-16-2018 09&#58;36&#58;25
curdir&#58; C&#58;\Documents and Settings\msmithjones\Desktop\msmithjones\test
tmpdir&#58; C&#58;\Documents and Settings\msmithjones\Application Data\OHRRPGCE\
settings_dir&#58; C&#58;\Documents and Settings\msmithjones\Application Data\OHRRPGCE
Editing game C&#58;\Documents and Settings\msmithjones\Desktop\msmithjones\test\a_tactics.rpg &#40; &#41;
Full game data upgrade...
Last edited by&#58; &#91;&#91;OHRRPGCE etheldreme 20171203.9852 gfx_directx+sdl+fb/music_sdl FreeBASIC 1.05.0 &#40;01-31-2016&#41; x86    Win32 32-bit&#93;&#93;
archinym creation info&#58; OHRRPGCE beelzebufo 20130410
SETVISPAGE&#40;gfx_present&#41; took 106ms
SETVISPAGE&#40;&#41; took 214ms
"C&#58;\Documents and Settings\msmithjones\Desktop\msmithjones\test\hspeak.exe" -k > "C&#58;\Documents and Settings\msmithjones\Application Data\OHRRPGCE\temp_stdout.246539.tmp" 2> "C&#58;\Documents and Settings\msmithjones\Application Data\OHRRPGCE\temp_stderr.694814.tmp"
hspeak version '3Tf'
spawn_and_wait "C&#58;\Documents and Settings\msmithjones\Desktop\msmithjones\test\hspeak.exe" -y --include "a_tactics.hsi" "a_tactics-script.txt"
SETVISPAGE&#40;gfx_present&#41; took 100ms
SETVISPAGE&#40;&#41; took 201ms
SETVISPAGE&#40;gfx_present&#41; took 144ms
SETVISPAGE&#40;&#41; took 290ms
SETVISPAGE&#40;gfx_present&#41; took 219ms
SETVISPAGE&#40;&#41; took 438ms
SETKEYS&#40;0&#41; took 11ms
SETVISPAGE&#40;gfx_present&#41; took 70ms
SETVISPAGE&#40;&#41; took 142ms
SETVISPAGE&#40;gfx_present&#41; took 126ms
SETVISPAGE&#40;&#41; took 253ms
UPDATE_MOUSE_STATE&#40;0&#41; took 24ms
SETVISPAGE&#40;gfx_present&#41; took 94ms
SETVISPAGE&#40;&#41; took 188ms
Let me know if I can give you any other info.
TMC
Metal King Slime
Posts: 4308
Joined: Sun Apr 10, 2011 9:19 am

Post by TMC »

Thanks for the detail. How many slice collections do you have?

Unfortunately this is far from enough information to solve this. But I have a plan; I'm adding a crash handler to the engine. I'll get back to you tomorrow with instructions. Since you're using Etheldreme rather than nightlies (and assuming you don't want to use nightlies), I can easily backport the crash handler to Etheldreme.
User avatar
sotrain515
Red Slime
Posts: 59
Joined: Wed Dec 26, 2012 3:23 pm

Post by sotrain515 »

26, that was the most recent one I had added.

I am willing to use nightlies. Let me know what to do.
TMC
Metal King Slime
Posts: 4308
Joined: Sun Apr 10, 2011 9:19 am

Post by TMC »

OK. Though if you're fond of full spriteset import/export in the spriteset editor you won't want to use the nightlies right now, as those features are temporarily missing. Also the ability to jump straight from certain editors to others (eg Enemy to Attack).

Right, I finally have some working crash logging. (Previously, we would ask people to download gdb and run that to get this information, but that's burdensome) Instructions:
-Either wait at least 15 hours from now and then download the debug nightly build: http://hamsterrepublic.com/ohrrpgce/nig ... -debug.zip or else download this early build I've uploaded here: http://tmc.castleparadox.com/ohr/temp/o ... -debug.zip
-Download https://github.com/jrfonseca/drmingw/re ... 2-win32.7z
If you can't open .7z files, I'll repackage it for you. I'll probably do that anyway.
-Take all the .dll files from the drmingw-0.8.2-win32/bin/ folder in the .7z file and put them in the same folder as game/custom.exe
-Use game/custom normally
-If a fatal error occurs you should see a messagebox pop up, telling you that a crash log was saved to custom-crash-report.txt

Because this build contains extra error checking, it might throw a fatal error earlier than before, possibly somewhere completely different.
Last edited by TMC on Mon Feb 19, 2018 6:38 pm, edited 1 time in total.
User avatar
sotrain515
Red Slime
Posts: 59
Joined: Wed Dec 26, 2012 3:23 pm

Post by sotrain515 »

Sorry I didn't get back to you sooner, I've been otherwise busy.

I actually do use the spriteset importing/exporting quite a bit, should I hold off on testing until that feature is re-enabled in the nightly?
TMC
Metal King Slime
Posts: 4308
Joined: Sun Apr 10, 2011 9:19 am

Post by TMC »

Sure, I'm planning to get to it soon. Maybe even today.
Post Reply