I've distracted myself on this game for a bit.
The resulting .fm2
I got the .fcm to sync on FCEUX -- Convert to .fm2, then insert four blank frames prior to the immediate reset.
I was making my own run without the ability to see that .fcm for a while, until I realized how to make the darn thing sync. A nice surprise, then, that I found I beat Blublu's WIP by over 700 frames by the time I collect that second fuel unit.
I've developed my own script for this game as well. It reveals locations of off-screen objects by drawing a single pixel with a specified scaling. Also, by holding down space, it blacks out the screen so that these pixels can be more easily seen.
Regardless, it reports an object that exists right above the second fuel unit in world 7. I've flown through this invisible object and shot it, and also waited around it for a while, and didn't get it to react. I have not done any digging into memory to see what makes this mystery object work. It's invisible, and resides in the empty space somewhere above the second fuel unit.
Anyway, my current script as is:
Download SJ.luaLanguage: lua
local R1u, R1s= memory.readbyte, memory.readbytesigned
local function R2u(a) return R1u(a) + R1u(a+1)*256 end
local function R2s(a) return R1u(a) + R1s(a+1)*256 end
local lastkeys, keys= input.get(), input.get()
local function UpdateKeys() lastkeys= keys; keys= input.get() end
local function Limits(V,l,h) return math.max(math.min(V,h),l) end
local Draw= {}
local Px,Li= gui.pixel, gui.line
Draw[0]= function(x,y,c)
Li(x ,y ,x ,y+4,c)
Li(x+2,y ,x+2,y+4,c)
Px(x+1,y ,c)
Px(x+1,y+4,c)
end
Draw[1]= function(x,y,c)
Li(x ,y+4,x+2,y+4,c)
Li(x+1,y ,x+1,y+3,c)
Px(x ,y+1,c)
end
Draw[2]= function(x,y,c)
Li(x ,y ,x+2,y ,c)
Li(x ,y+3,x+2,y+1,c)
Li(x ,y+4,x+2,y+4,c)
Px(x ,y+2,c)
Px(x+2,y+2,c)
end
Draw[3]= function(x,y,c)
Li(x ,y ,x+1,y ,c)
Li(x ,y+2,x+1,y+2,c)
Li(x ,y+4,x+1,y+4,c)
Li(x+2,y ,x+2,y+4,c)
end
Draw[4]= function(x,y,c)
Li(x ,y ,x ,y+2,c)
Li(x+2,y ,x+2,y+4,c)
Px(x+1,y+2,c)
end
Draw[5]= function(x,y,c)
Li(x ,y ,x+2,y ,c)
Li(x ,y+1,x+2,y+3,c)
Li(x ,y+4,x+2,y+4,c)
Px(x ,y+2,c)
Px(x+2,y+2,c)
end
Draw[6]= function(x,y,c)
Li(x ,y ,x+2,y ,c)
Li(x ,y+1,x ,y+4,c)
Li(x+2,y+2,x+2,y+4,c)
Px(x+1,y+2,c)
Px(x+1,y+4,c)
end
Draw[7]= function(x,y,c)
Li(x ,y ,x+1,y ,c)
Li(x+2,y ,x+1,y+4,c)
end
Draw[8]= function(x,y,c)
Li(x ,y ,x ,y+4,c)
Li(x+2,y ,x+2,y+4,c)
Px(x+1,y ,c)
Px(x+1,y+2,c)
Px(x+1,y+4,c)
end
Draw[9]= function(x,y,c)
Li(x ,y ,x ,y+2,c)
Li(x+2,y ,x+2,y+3,c)
Li(x ,y+4,x+2,y+4,c)
Px(x+1,y ,c)
Px(x+1,y+2,c)
end
Draw[10]=function(x,y,c)
Li(x ,y+1,x ,y+4,c)
Li(x+2,y+1,x+2,y+4,c)
Px(x+1,y ,c)
Px(x+1,y+3,c)
end
Draw[11]=function(x,y,c)
Li(x ,y ,x ,y+4,c)
Li(x+1,y ,x+2,y+1,c)
Li(x+1,y+4,x+2,y+3,c)
Px(x+1,y+2,c)
end
Draw[12]=function(x,y,c)
Li(x ,y+1,x ,y+3,c)
Li(x+1,y ,x+2,y+1,c)
Li(x+1,y+4,x+2,y+3,c)
end
Draw[13]=function(x,y,c)
Li(x ,y ,x ,y+4,c)
Li(x+2,y+1,x+2,y+3,c)
Px(x+1,y ,c)
Px(x+1,y+4,c)
end
Draw[14]=function(x,y,c)
Li(x ,y ,x ,y+4,c)
Li(x+1,y ,x+2,y ,c)
Li(x+1,y+4,x+2,y+4,c)
Px(x+1,y+2,c)
end
Draw[15]=function(x,y,c)
Li(x ,y ,x ,y+4,c)
Li(x+1,y ,x+2,y ,c)
Px(x+1,y+2,c)
end
local function __DN_AnyBase(right, y, Number, c, bkgnd, div)
if div < 2 then return end
local Digit= {}
local Negative= false
if Number < 0 then
Number= -Number
Negative= true
end
Number= math.floor(Number)
c= c or "white"
bkgnd= bkgnd or "clear"
local i= 0
if Number < 1 then
Digit[1]= 0
i= 1
end
while (Number >= 1) do
i= i+1
Digit[i]= Number % div
Number= math.floor(Number/div)
end
if Negative then i= i+1 end
local x= right - i*4
gui.box(x+1, y-1, right+1, y+5,bkgnd,bkgnd)
i= 1
while Draw[Digit[i]] do
Draw[Digit[i]](right-2,y,c)
right= right-4
i=i+1
end
if Negative then
gui.line(right, y+2,right-2,y+2,c)
right= right-4
end
return right
end
local function DrawNum(right, y, Number, c, bkgnd)
return __DN_AnyBase(right, y, Number, c, bkgnd, 10)
end
local function DrawNumx(right, y, Number, c, bkgnd)
return __DN_AnyBase(right, y, Number, c, bkgnd, 16)
end
local OC= {
[0]= "white",
"white",
"white",
"green",
"green",
"green",
"green",
"green",
"green",
"green",
"green",
"blue",
"blue",
"blue",
"blue",
"red",
"red",
"red",
"red",
"red",
"red",
"red",
"red",
"yellow",
"yellow",
"yellow",
"yellow",
"yellow",
"grey",
"grey",
"grey"
}
local function ObjRadar(Factor)
local CamX, CamY= R2u(0x004C), R2u(0x004E)
local OffX= math.floor((1-1/Factor)*128)
local OffY= math.floor((1-1/Factor)*100)
local count= 0
for i= 0, 0x1E do
if R1u(0x0317+i) ~= 0 then
count= count+1
gui.pixel(
math.floor((R1u(0x0200+i)+R1s(0x021F+i)*256-CamX)/Factor + OffX),
math.floor((R1u(0x025D+i)+R1s(0x027C+i)*256-CamY)/Factor + OffY),
OC[i]
)
end
end
DrawNum(90,12,count)
end
local function ObjCount()
local P, B, E, A, I, S= 0,0,0,0,0,0
for i= 0, 2 do
if R1u(0x0317+i) ~= 0 then
P= P+1
end
end
for i= 3, 10 do
if R1u(0x0317+i) ~= 0 then
B= B+1
end
end
for i= 11, 14 do
if R1u(0x0317+i) ~= 0 then
E= E+1
end
end
for i= 15, 22 do
if R1u(0x0317+i) ~= 0 then
A= A+1
end
end
for i= 23, 27 do
if R1u(0x0317+i) ~= 0 then
I= I+1
end
end
for i= 28, 30 do
if R1u(0x0317+i) ~= 0 then
S= S+1
end
end
gui.box(238,8,252,56,"black",0)
Draw[P](240,10,"white"); Draw[3](248,10,"white")
Draw[B](240,18,"white"); Draw[8](248,18,"white")
Draw[E](240,26,"white"); Draw[4](248,26,"white")
Draw[A](240,34,"white"); Draw[8](248,34,"white")
Draw[I](240,42,"white"); Draw[5](248,42,"white")
Draw[S](240,50,"white"); Draw[3](248,50,"white")
end
local DirX={
[0]= 0, 3, 6, 8, 11, 13, 14, 15,
16, 15, 14, 13, 11, 8, 6, 3,
0, -3, -6, -8,-11,-13,-14,-15,
-16,-15,-14,-13,-11, -8, -6, -3
}
local DirX2={
[0]= 0, 12, 24, 35, 45, 53, 59, 62,
64, 62, 59, 53, 45, 35, 24, 12,
0,-12,-24,-35,-45,-53,-59,-62,
-64,-62,-59,-53,-45,-35,-24,-12
}
local function DirPow(v)
return DirX[v], DirX[(v+8)%32]
end
local function Fn()
UpdateKeys()
if keys.space then gui.box(-1,7,256,200,"black",0) end
DrawNum( 20,10,R2u(0x00C6),"white","black")
DrawNum( 20,40,R1u(0x0374),"white","black")
DrawNum(230,10,R2u(0x004C),"white","black")
DrawNum(230,30,R1u(0x0200) + R1u(0x021F)*256,"white","black")
DrawNum(230,40,R1u(0x025D) + R1u(0x027C)*256,"white","black")
local N= 1
if R1u(0x0336) == 1 then N= -1 end
DrawNum( 20,20,(R1u(0x029B)+R1u(0x02BA)*256)*N,"white","black")
DrawNum( 40,20,DirX[R1u(0x0374)%32] ,"white","black")
DrawNum( 54,20,DirX2[R1u(0x0374)%32],"white","black")
N= 1
if R1u(0x0355) == 1 then N= -1 end
DrawNum( 20,30,(R1u(0x02D9)+R1u(0x02F8)*256)*N,"white","black")
DrawNum( 40,30,DirX[(R1u(0x0374)+8)%32] ,"white","black")
DrawNum( 54,30,DirX2[(R1u(0x0374)+8)%32],"white","black")
ObjRadar(3)
ObjCount()
end
gui.register(Fn)
local function DumpStats()
for obj= 0, 0x1E do
local color= "white"
if R1u(0x0200+obj+0x1F*9) == 0 then color= "grey" end
for st= 0, 16 do
DrawNumx(9+st*10, 9+obj*7, R1u(0x0200+obj+st*0x1F),color,"black")
end
end
end