Page 1 of 1

Spectaculator Script

Posted: Fri Sep 13, 2013 3:30 am
by millansoft
Hello,

I wanted to do a script for Spectaculator, so when it opens the emulator, it opens with the model (48k/128k/+3a) that support the game, to avoid crashes with some games, but I can't find any command line switch for Spectaculator, anyone knows if Spectaculator has command line switchs parameters?

Posted: Fri Sep 13, 2013 6:40 pm
by .mad.
no it doesn't have a command-line.
it saves the last machine setting used to the registry.

Code: Select all

Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\Software\spectaculator.com\Spectaculator\Settings]
"Show Welcome Dlg"=dword:00000000
"Show Exit Dlg"=dword:00000000
"Show Reset Dlg"=dword:00000000
"Mimic TV Screen"=dword:00000000
"Border Type"=dword:00000000
"Mute Sound"=dword:00000000
"Full Screen"=dword:00000000
"Width"=dword:000001a2
"Height"=dword:0000013f
"Left"=dword:00000232
"Top"=dword:000000fd
"Model v6+"=dword:00000002
"CPU Model"=dword:00000001
"CPU Speed"=dword:00000001
"Break On Unhandled"=dword:00000000
"48k ROM"=""
"128k ROM"=""
"Plus 2 ROM"=""
"Plus 2A ROM"=""
"Pentagon ROM"=""
"Scorpion ROM"=""
"Quick Save Folder"=""
"Toolbar"=dword:00000001
"StatusBar"=dword:00000001
"Use Ctrl Key"=dword:00000001
Machine settings
---------------------------------------------
16k - "Model v6+"=dword:00000000
48k - "Model v6+"=dword:00000001
128k - "Model v6+"=dword:00000002
+2 - "Model v6+"=dword:00000003
+2A - "Model v6+"=dword:00000004
+3 - "Model v6+"=dword:00000005
Pentagon - "Model v6+"=dword:00000006
Scorpion - "Model v6+"=dword:00000007
-----------------------------------------------

you need to make batch files for all the machines, so the settings can be imported into the REG before running the emulator from the script.


48k.reg

Code: Select all

Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\Software\spectaculator.com\Spectaculator\Settings]
"Model v6+"=dword:00000001
48k.bat

Code: Select all

reg import 48k.reg

128k.reg

Code: Select all

Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\Software\spectaculator.com\Spectaculator\Settings]
"Model v6+"=dword:00000002
128k.bat

Code: Select all

reg import 128k.reg
script.txt

Code: Select all

If Key_machine contains(128k)
Run_Program(%emupath%\scripts\128k.bat||||WAIT)

Else
Run_Program(%emupath%\scripts\48k.bat||||WAIT)
End If

	Add_CLP(%gamepathfile%)
	Run_Emulator()

Posted: Sun Sep 15, 2013 4:14 pm
by millansoft
Thank you .mad., awesome as always :)

Posted: Fri Oct 04, 2013 7:48 am
by dax
I've tested it and I have a message "Too many IF statements". Do You know what can be wrong, mad ? :P

Posted: Fri Oct 04, 2013 5:44 pm
by .mad.
updated!

Every IF needs an END IF.

just add the "END IF" to the bottom of the script.

This might not work in Win7, but i does in XP.

Posted: Sat Oct 05, 2013 11:47 am
by dax
No errors now, but machine model does not change to 128k. Where are "Key_machine" entries ? Asking because I want to change it manually to force running emulator in 128k mode for some games.

Posted: Sat Oct 05, 2013 1:35 pm
by .mad.
i only just made the script, so the settings won't be in YOUR gamebase.mdb file.

you will need to add them manually, for each 128k game.

1) open your gamebase and select a 128k game from the list.

2) press F2 to open GEMUS window.

in the left window type...

machine=128k

then click OK to save the setting.

3) run game.


this can be a simple copy and paste job in access. :wink:

to see if it works
run the 128k.bat, then run spectaculator.
see if machine is 128k
quit

run 48k.bat, then run spectaculator.
see if machine is 48k.

*the bat and reg files must be in the same directory.

Posted: Sat Oct 05, 2013 5:39 pm
by dax
Used Quick Filter to find 455 games with "128" phrase (Speccymania v3.5). So I'm doing it.... :P

Posted: Sun Oct 06, 2013 7:01 am
by .mad.
i have also done that! :P

a lot of 128k games need a TRDOS machine others need a +3 disk drive.
so i have updated the reg and script settings for those as well.

it's a bit flakey. But that's probably down to the AV /firewall freaking out, while i poke around with the REG.

Posted: Sat Nov 02, 2013 2:32 pm
by dax
Can You upload Your modified files, .mad. ?