Skip navigation
NintendoAge
Welcome, Guest! Please Login or Join
Loading...

Game Hack Request: Tetris + DAS Meter Looking for a hack or game genie code to show current DAS meter.

Mar 15, 2016 at 7:54:10 PM
KittyFae (0)

< Cherub >
Posts: 3 - Joined: 07/06/2014
Alabama
Profile
Looking for someone way smarter than myself to add in a DAS meter for the Nintendo/BPS (Non-Tengen) Tetris. Either a hack or a game genie code would be appreciated, just looking for something to play on original hardware. There is a script below that will show a meter with FCEUX, but I'd rather not emulate.

This code wasn't written by me and taken from this youtube video: 


Code:
local cnt = {};
for i=0,18 do
	cnt[i] = 0;
end;

local prev; local pieces;

while (true) do local das = memory.readbyte(0x0046); --delay is gravity and ARE counter local delay = memory.readbyte(0x0045); prev = pieces; pieces = memory.readbyte(0x001A); local test = memory.readbyte(0x0019); if(pieces ~= prev) then cnt[test] = cnt[test] + 1; end; gui.text(100,16,"Gravity/ARE: "..delay..""); gui.text(100,8,"Next Piece: "..test..""); gui.text(200,0,"Pieces: "..pieces..""); for i=0,18 do gui.text(220,(i+1)*8,i..": "..cnt[i]..""); end; gui.drawbox(5, 0, 7+4*16, 5, "magenta"); for i=1,4 do gui.drawbox(6, i, 6+4*das, i, "green"); end; gui.drawbox(5+4*10, 1, 5+4*10, 4, "white");

local inp1 = joypad.read(1); if(inp1.left) then gui.text(5,8,"<L"); elseif(inp1.right) then gui.text(5,8,"R>"); else gui.text(5,8,"--"); end; FCEU.frameadvance(); end;

 

Mar 15, 2016 at 9:24:54 PM
dougeff (13)
avatar
< Eggplant Wizard >
Posts: 349 - Joined: 12/29/2015
Profile
If you want a game genie code, it's going to have to replace something that's already on screen and updated regularly. Like one of the statistics numbers, or at the top where it says 'lines'.

Which would you prefer?

-------------------------
nesdoug.com -- blog/tutorial on programming for the NES


Edited: 03/15/2016 at 09:31 PM by dougeff

Mar 15, 2016 at 11:03:57 PM
KittyFae (0)

< Cherub >
Posts: 3 - Joined: 07/06/2014
Alabama
Profile
Replacing any or all of the statistics would be awesome. If just one though, then probably the line/ I piece.


Edited: 03/15/2016 at 11:04 PM by KittyFae

Mar 15, 2016 at 11:10:34 PM
dougeff (13)
avatar
< Eggplant Wizard >
Posts: 349 - Joined: 12/29/2015
Profile
Try these...

TEVOAIIZ
TGEPPVEZ

Replaces the 'Level' with 0x46, listed in the code above as 'DAS'
Best I could do in a half an hour.

-------------------------
nesdoug.com -- blog/tutorial on programming for the NES

Mar 15, 2016 at 11:20:14 PM
dougeff (13)
avatar
< Eggplant Wizard >
Posts: 349 - Joined: 12/29/2015
Profile
Or these..

TEOPPIPI
TKXPLIPY

Replaces the first 0 of 'Lines' with 0x46, listed above as 'DAS'

-------------------------
nesdoug.com -- blog/tutorial on programming for the NES

Mar 15, 2016 at 11:42:39 PM
KittyFae (0)

< Cherub >
Posts: 3 - Joined: 07/06/2014
Alabama
Profile
Woah sweet, the one at the level area is fantastic! Thank you very very much, I am new to this forum is there any way I can give you props or anything?

Mar 16, 2016 at 12:31:13 AM
dougeff (13)
avatar
< Eggplant Wizard >
Posts: 349 - Joined: 12/29/2015
Profile
Thanks is enough.

You'd be surprised how many people I've helped on various forums, who didn't say 'thanks'.

To me, it was like you gave me a little Sudoku puzzle, it kept my mind occupied for a little while, and I love Tetris, btw.

-------------------------
nesdoug.com -- blog/tutorial on programming for the NES


Edited: 03/16/2016 at 12:33 AM by dougeff