Neural Stunners

Request patches for Keens 4-6.
Post Reply
Wodd
Posts: 27
Joined: Sun Aug 13, 2017 3:37 am

Neural Stunners

Post by Wodd »

Out of curiosity, what level in Secret of the Oracle has the most neural stunners?
User avatar
Fleexy
Site Admin
Posts: 490
Joined: Fri Dec 12, 2008 1:33 am
Location: Bloogton Tower

Re: Neural Stunners

Post by Fleexy »

We can use PSThar!

Code: Select all

Get-Level | % {
	$script:stunners = 0
	$_ | %t {
		$f = $_ | Get-LevelTile $x $y 1
		$i = $_ | Get-LevelTile $x $y 2
		If ($f -in (0x67B, 0x68D)) { $script:stunners++ }
		If ($i -in (0x44, 0x22)) { $script:stunners++ }
	}
	$obj = [psobject]::new()
	$obj | Add-Member NoteProperty 'Level' ($_.Name)
	$obj | Add-Member NoteProperty 'Stunners' $stunners
	$obj
} | sort Stunners -Desc
Results:

Code: Select all

Level           Stunners
-----           --------
Sand Yego             12
Crystalus             10
Miragia               10
Pyramid_Shadows        8
Isle of Fire           7
Perilous Pit           7
DescendentsCave        6
PyramidAncients        6
HillVille              6
Chasm of Chills        6
PyramidForbid          5
Slug Village           5
Border Village         3
Isle of Tar            3
Lifewater Oasis        1
BWB Megarocket         1
HighScores             0
Well Of Wishes         0
ShadowLands            0
PyramidOfMoons         0
To ignore the "if" stunners that only appear when Keen has less than 5 ammo, we can change "-in (0x44, 0x22)" to "-eq 0x44" to get these very similar results:

Code: Select all

Level           Stunners
-----           --------
Sand Yego             10
Crystalus              9
Miragia                9
Pyramid_Shadows        7
Perilous Pit           7
HillVille              6
Isle of Fire           6
Chasm of Chills        6
DescendentsCave        6
PyramidAncients        5
PyramidForbid          5
Slug Village           5
Border Village         3
Isle of Tar            2
HighScores             0
BWB Megarocket         0
Well Of Wishes         0
ShadowLands            0
Lifewater Oasis        0
PyramidOfMoons         0
Wodd
Posts: 27
Joined: Sun Aug 13, 2017 3:37 am

Re: Neural Stunners

Post by Wodd »

Thank you for the information, Fleexy. I also see that the level names match those seen in Commander Genius. Perhaps those are the variable assignments for the levels within the game’s code. The part that players see is the output for those variables.
For example:
Dim Level As String;
If Level = PyramidForbid Then Print "Pyramid of the Forbidden";
User avatar
Fleexy
Site Admin
Posts: 490
Joined: Fri Dec 12, 2008 1:33 am
Location: Bloogton Tower

Re: Neural Stunners

Post by Fleexy »

Those are the level names in the GAMEMAPS file, visible/used in level editors like Abiathar. You can use a level editor to change them, but the game will not be affected - they're just for convenience when editing. The in-game level names are stored in a table in the EXE, essentially mapped to level IDs. You can change them with patching. I'm not sure how Commander Genius handles them, though.
User avatar
Nisaba
Posts: 320
Joined: Fri Jan 01, 2016 11:15 pm
Location: patch.pat
Contact:

Re: Neural Stunners

Post by Nisaba »

@Fleex can you please add this script to your github page as well? would be very helpful to have all scripts on one spot. thanks
Post Reply