Posts for RainbowSprinklez
Experienced Forum User
Joined: 10/2/2015
Posts: 91
well, it's supposed to display speed and position on screen. instead, it falls in an infinite loop of some sort. so something is obv wrong in my syntax/code
I didn't kill donkey, I saved it. Current projects: Misc Donkey hacks :) Past projects: Pacifist DKC1 DKC1 Entrance randomizer DKC2 Entrance randomizer DKDC (a troll hack of DKC1) DKC1 Enemy randomizer (among other things)
Experienced Forum User
Joined: 10/2/2015
Posts: 91
thx! btw, this is the code im using: Download this.lua
Language: lua

local front = 0x056F local frontVal local xDiddySpeed = 0x0E8D local xDidSpdVal local xDiddyPosition = 0x0B1D local xDidPos memory.usememorydomain("WRAM") -- just in case while true do frontVal = memory.readbyte(front) if (frontVal == 2) then xDidSpdVal = memory.read_s16_le(xDiddySpeed) gui.text(0, 50, "Speed - "..xDidSpdVal) xDidPos = memory.read_s16_le(xDiddyPosition) gui.text(0, 65, "Position - "..xDidPos) end emu.frameadvance() end
Why wont this work??
I didn't kill donkey, I saved it. Current projects: Misc Donkey hacks :) Past projects: Pacifist DKC1 DKC1 Entrance randomizer DKC2 Entrance randomizer DKDC (a troll hack of DKC1) DKC1 Enemy randomizer (among other things)
Experienced Forum User
Joined: 10/2/2015
Posts: 91
[string domain = null]) <- what do i replace that with?
I didn't kill donkey, I saved it. Current projects: Misc Donkey hacks :) Past projects: Pacifist DKC1 DKC1 Entrance randomizer DKC2 Entrance randomizer DKDC (a troll hack of DKC1) DKC1 Enemy randomizer (among other things)
Experienced Forum User
Joined: 10/2/2015
Posts: 91
no, i looked at your references shortly after posting. im using memory.read_s16_le now. it works for 1 ram value but not for 2
I didn't kill donkey, I saved it. Current projects: Misc Donkey hacks :) Past projects: Pacifist DKC1 DKC1 Entrance randomizer DKC2 Entrance randomizer DKDC (a troll hack of DKC1) DKC1 Enemy randomizer (among other things)
Experienced Forum User
Joined: 10/2/2015
Posts: 91
thanks! sorry for my noobiness!
I didn't kill donkey, I saved it. Current projects: Misc Donkey hacks :) Past projects: Pacifist DKC1 DKC1 Entrance randomizer DKC2 Entrance randomizer DKDC (a troll hack of DKC1) DKC1 Enemy randomizer (among other things)
Experienced Forum User
Joined: 10/2/2015
Posts: 91
thanks for noticing the typo. the code works perfectly well with snes9xrr, but still throws an error on bizhawk :/ the current error is an infinite loop
I didn't kill donkey, I saved it. Current projects: Misc Donkey hacks :) Past projects: Pacifist DKC1 DKC1 Entrance randomizer DKC2 Entrance randomizer DKDC (a troll hack of DKC1) DKC1 Enemy randomizer (among other things)
Experienced Forum User
Joined: 10/2/2015
Posts: 91
my computer is poop. it's very bad. i am having trouble with playback when i open the ram watch viewer, but not running lua scripts. my question is, what syntax is wrong here? Download test.lua
Language: lua

local ramAddress = 0x7E0577 local ramValue while true do ramValue = memory.readbyte(ramAddresss) gui.text(0,0, ramValue) emu.frameadvance() end
ultimately, i want to write a script that displays things like speed and position on the screen. this will circumvent playback issues.
I didn't kill donkey, I saved it. Current projects: Misc Donkey hacks :) Past projects: Pacifist DKC1 DKC1 Entrance randomizer DKC2 Entrance randomizer DKDC (a troll hack of DKC1) DKC1 Enemy randomizer (among other things)
Experienced Forum User
Joined: 10/2/2015
Posts: 91
"$0100 - $01FF is Stack that is also used for temporary needs." lol i was thrown off by the $ is all... only place i see that is jQuery and money
I didn't kill donkey, I saved it. Current projects: Misc Donkey hacks :) Past projects: Pacifist DKC1 DKC1 Entrance randomizer DKC2 Entrance randomizer DKDC (a troll hack of DKC1) DKC1 Enemy randomizer (among other things)
Experienced Forum User
Joined: 10/2/2015
Posts: 91
Thank you bobo! Yeah, I was a bit overwhelmed. Thanks for the encouragement, dude!
I didn't kill donkey, I saved it. Current projects: Misc Donkey hacks :) Past projects: Pacifist DKC1 DKC1 Entrance randomizer DKC2 Entrance randomizer DKDC (a troll hack of DKC1) DKC1 Enemy randomizer (among other things)
Experienced Forum User
Joined: 10/2/2015
Posts: 91
What if iI told you speed worked at first but upon loading a movie file wouldn't? And how can I check speed? Do you know? And snes9xrr worked for speed :/
I didn't kill donkey, I saved it. Current projects: Misc Donkey hacks :) Past projects: Pacifist DKC1 DKC1 Entrance randomizer DKC2 Entrance randomizer DKDC (a troll hack of DKC1) DKC1 Enemy randomizer (among other things)
Experienced Forum User
Joined: 10/2/2015
Posts: 91
so, if i understand correctly, $1FF0 is the last of the zero pages in smb? What does the article mean by 'page'? "The third page is frequently used for sprite data, you can notice that by the specific nature of how they values change." edit: is every 1k a new page?
I didn't kill donkey, I saved it. Current projects: Misc Donkey hacks :) Past projects: Pacifist DKC1 DKC1 Entrance randomizer DKC2 Entrance randomizer DKDC (a troll hack of DKC1) DKC1 Enemy randomizer (among other things)
Post subject: Bizhawk troubles
Experienced Forum User
Joined: 10/2/2015
Posts: 91
I'm really showing my newbie colors here... BUT I used bizhawk on my desktop just fine under default settings. Installed it on my laptop and I am having BIG problems. The speed for me is not working. I could do frame advance no problem but I can't seem to alter emu speed. What am I doing wrong?
I didn't kill donkey, I saved it. Current projects: Misc Donkey hacks :) Past projects: Pacifist DKC1 DKC1 Entrance randomizer DKC2 Entrance randomizer DKDC (a troll hack of DKC1) DKC1 Enemy randomizer (among other things)
Experienced Forum User
Joined: 10/2/2015
Posts: 91
i did read the article. i would be lying if i said i completely understood. i downloaded fceux and smb to try and follow along, but i was lost at the Zero Page... $0000? What does $ refer to?
I didn't kill donkey, I saved it. Current projects: Misc Donkey hacks :) Past projects: Pacifist DKC1 DKC1 Entrance randomizer DKC2 Entrance randomizer DKDC (a troll hack of DKC1) DKC1 Enemy randomizer (among other things)
Experienced Forum User
Joined: 10/2/2015
Posts: 91
oh god, there are rom values too?? o.o didn't even know. thanks for the advice!
I didn't kill donkey, I saved it. Current projects: Misc Donkey hacks :) Past projects: Pacifist DKC1 DKC1 Entrance randomizer DKC2 Entrance randomizer DKDC (a troll hack of DKC1) DKC1 Enemy randomizer (among other things)
Post subject: Ok. New mindset = new thread
Experienced Forum User
Joined: 10/2/2015
Posts: 91
I've kinda missed the point so far as ti what this website is about. Now I want to fix that! I am working on a TAS. But to make it easier for me, how do I find a hitbox and display it with lua in bizhawk? Ram search I am fairly comfortable with, but so far I mostly have found basic stuff (ie. inputs, facing, lives). How can I go about finding the harder stuff like say, a group of ram values that make up a hitbox? And then, how does bizhawk differ from snes9x in lua?
I didn't kill donkey, I saved it. Current projects: Misc Donkey hacks :) Past projects: Pacifist DKC1 DKC1 Entrance randomizer DKC2 Entrance randomizer DKDC (a troll hack of DKC1) DKC1 Enemy randomizer (among other things)
Experienced Forum User
Joined: 10/2/2015
Posts: 91
i'm sorry guys. i've been acting silly. i got caught up on hacks that i pushed TAS to the side, which I shouldn't have. it's just that making a TAS is a huge undertaking while hacks... aren't. i'm sorry. i goofed. plus, i'm in a very large shadow. however, one thing you guys MAY find interesting is i found a ram value that simulates a B press in a stage, so i'm sure there must be others. this is useful in that you could write code that fires ONLY when the game allows input. edit: i found this ram value: 7E16E7. it's roll with diddy. if you force to 1 you cant roll. it's 1 byte.
I didn't kill donkey, I saved it. Current projects: Misc Donkey hacks :) Past projects: Pacifist DKC1 DKC1 Entrance randomizer DKC2 Entrance randomizer DKDC (a troll hack of DKC1) DKC1 Enemy randomizer (among other things)
Experienced Forum User
Joined: 10/2/2015
Posts: 91
i really don't consider myself a TASer as i've not made any TAS yet... so i just clung to the idea of a hacker...
I didn't kill donkey, I saved it. Current projects: Misc Donkey hacks :) Past projects: Pacifist DKC1 DKC1 Entrance randomizer DKC2 Entrance randomizer DKDC (a troll hack of DKC1) DKC1 Enemy randomizer (among other things)
Experienced Forum User
Joined: 10/2/2015
Posts: 91
ok, i'll research separately. :D just checking
I didn't kill donkey, I saved it. Current projects: Misc Donkey hacks :) Past projects: Pacifist DKC1 DKC1 Entrance randomizer DKC2 Entrance randomizer DKDC (a troll hack of DKC1) DKC1 Enemy randomizer (among other things)
Experienced Forum User
Joined: 10/2/2015
Posts: 91
good idea! hey, does anybody know how to inject this in a ROM? itd be easier to show my friends without providing them more steps.
I didn't kill donkey, I saved it. Current projects: Misc Donkey hacks :) Past projects: Pacifist DKC1 DKC1 Entrance randomizer DKC2 Entrance randomizer DKDC (a troll hack of DKC1) DKC1 Enemy randomizer (among other things)
Experienced Forum User
Joined: 10/2/2015
Posts: 91
also, https://www.youtube.com/watch?v=9ZVwJfkM0Eg Download xtofly.lua
Language: lua

while true do table = joypad.get(1) if (table.X) then memory.writeword(0x7E0EF5, 1000) local reads = memory.readword(0x7E0EF5) local curse = reads + 4 memory.writeword(0x7E0EF5,curse) end emu.frameadvance() end
I didn't kill donkey, I saved it. Current projects: Misc Donkey hacks :) Past projects: Pacifist DKC1 DKC1 Entrance randomizer DKC2 Entrance randomizer DKDC (a troll hack of DKC1) DKC1 Enemy randomizer (among other things)
Experienced Forum User
Joined: 10/2/2015
Posts: 91
i have a question that may enhance it. is there anyway to recognize when a game turns off the inputs so i can do the same?
I didn't kill donkey, I saved it. Current projects: Misc Donkey hacks :) Past projects: Pacifist DKC1 DKC1 Entrance randomizer DKC2 Entrance randomizer DKDC (a troll hack of DKC1) DKC1 Enemy randomizer (among other things)
Experienced Forum User
Joined: 10/2/2015
Posts: 91
i got that, thanks. but my if clause is never entered. why? Download speed.lua
Language: lua

local count = 0 local timer while true do local status= memory.readbyte(0x7E1B03) table = joypad.get(1) if (status == 1) then count = count + 1 --This is to force if when stage entered. if (count == 1) then timer = emu.framecount() + 60 --Increments timer to 60 more than frame count on stafe entrance end if (timer == emu.framecount()) then if table.Y then if table.right then memory.writeword(0x7E0E8B, 3) memory.writeword(0x7E0E8D, 2000) elseif table.left then memory.writeword(0x7E0E8B, -3) memory.writeword(0x7E0E8D, -2000) end else if table.right then memory.writeword(0x7E0E8B, 2) elseif table.left then memory.writeword(0x7E0E8B, -2) end end end count = 0 end emu.frameadvance() end
-edit: i hate notepad++. it is formatted right when i send it im guessing tabs arent counted? ---edit:i added this code towards the end, replacing count = 0
elseif status == 0 then
		count = 0
		end
but it doesnt solve my problem -----edit: I SOLVED IT!!! Download speed.lua
Language: lua

local count = 0 local timer local setup while true do local status= memory.readbyte(0x7E1B03) table = joypad.get(1) if (status == 1) then count = count + 1 --This is to force if when stage entered. if (count == 1) then timer = emu.framecount() + 60 --Increments timer to 60 more than frame count on stafe entrance end if timer == emu.framecount() then setup = 1 end if (setup == 1) then if table.Y then if table.right then memory.writeword(0x7E0E8B, 3) memory.writeword(0x7E0E8D, 2000) elseif table.left then memory.writeword(0x7E0E8B, -3) memory.writeword(0x7E0E8D, -2000) end else if table.right then memory.writeword(0x7E0E8B, 2) elseif table.left then memory.writeword(0x7E0E8B, -2) end end end count = 5 elseif status == 0 then count = 0 setup = 0 end emu.frameadvance() end
I didn't kill donkey, I saved it. Current projects: Misc Donkey hacks :) Past projects: Pacifist DKC1 DKC1 Entrance randomizer DKC2 Entrance randomizer DKDC (a troll hack of DKC1) DKC1 Enemy randomizer (among other things)
Experienced Forum User
Joined: 10/2/2015
Posts: 91
ok, makes sense. but frameadvance is a nil value? should i instead use get.frameadvance?
I didn't kill donkey, I saved it. Current projects: Misc Donkey hacks :) Past projects: Pacifist DKC1 DKC1 Entrance randomizer DKC2 Entrance randomizer DKDC (a troll hack of DKC1) DKC1 Enemy randomizer (among other things)
Experienced Forum User
Joined: 10/2/2015
Posts: 91
is there any wait command in lua as i need to wait about a second from entering the stage to activate my speedhack or the camera freezes
I didn't kill donkey, I saved it. Current projects: Misc Donkey hacks :) Past projects: Pacifist DKC1 DKC1 Entrance randomizer DKC2 Entrance randomizer DKDC (a troll hack of DKC1) DKC1 Enemy randomizer (among other things)
Experienced Forum User
Joined: 10/2/2015
Posts: 91
Thanks! I should probably have done that, huh?
I didn't kill donkey, I saved it. Current projects: Misc Donkey hacks :) Past projects: Pacifist DKC1 DKC1 Entrance randomizer DKC2 Entrance randomizer DKDC (a troll hack of DKC1) DKC1 Enemy randomizer (among other things)