Posts for FatRatKnight

Editor, Experienced Forum User, Published Author, Skilled player (1174)
Joined: 9/27/2008
Posts: 1085
Okay, so I didn't even come close to bothering with faster luck manipulation. However, it seems my basic plan that I'm thinking about has merit. 9 and a half minutes, even when I said "anything less than 1000 frames per reset is good," on top of other lack of optimizations. The horribly slow code I've been using to manipulate what I want is basically this:
-- This was stuck in along with my mutant RNG stat revealer code.

local Rs= {start=true,select=true,A=true,B=true}

local function ResetLoop(fn)
    while fn() do
        joypad.set(1,Rs)
        emu.frameadvance()
    end
end

local function Stuff()
    if (mutRNG.main == 0x89) then -- Or whatever insane condition...
        return false  -- Stop, we're done.
    end
    return true  -- Keep going.
end

while true do
    local z= input.get()
    if z.Z then
        ResetLoop(Stuff)
    end
    emu.frameadvance()
end
Four mutants look extremely doable, while I can still get my monster. I replaced a dead buddy with the ALBATROS with no problems. I'm finding how incorrect the disorganized notes I've posted up there are. I've got some work to do on them, it seems. Besides, they're just random notes I'm jotting down, mostly for myself. But... I just have 51 HP... I might need something more to survive SEI-RYU's first hit. Maybe another pile of cannon fodder valued ally can help me out here, since I am getting an ALBATROS anyway.
Editor, Experienced Forum User, Published Author, Skilled player (1174)
Joined: 9/27/2008
Posts: 1085
Part of the speed of my run is likely due to how swiftly I work the menus. I can imagine minutes wasted on laziness of just holding A instead. For whatever reason, I also take the time to set speed 1, in the re-order party Select menu, but I'm not sure if that saves any time. This is what my text file looks like, attempting to plan a route just getting to the P-FROG. Yes, I saved this text as part of my lua script, which is why the -- heading each line.
--Enc Denisty:
-- World 1, open land:  5
-- World 1, Forests  :  6
-- World 1, Grassy   : 13

--Enc!!!                2C                7B 95    A0             FE
--Enc!!                                                              FF
--Enc!         12    2A       37    54                B1 B9    F8
--Enc    04 0D    1D       33    48    66       96          C3

--172 (AC) steps from Tower to P-FROG bandit
--    Um, it will be difficult to learn TELEPOR within that time...
--144 (90) from P-FROG bandit to Castle Armor
--    TELEPOR seems quite possible with 316 steps plus the P-FROG battle
-- 77 (4D) from Tower to Castle Armor
--    If you get TELEPOR at P-FROG, this could save a few seconds...
--154 (9A) from Castle Armor to Castle Sword
--130 (82) from Tower to Castle Sword
-- 49 (31) Castle Sword 1F
-- 31 (1F) Castle Sword 2F
--  8 (08) Castle Sword 3F
-- 48 (30) from Tower to Castle Shield
--  5 (05) from Castle Shield to Town of Hero

-- The (EB) TELEPOR starts at step F2;
-- The (59) TELEPOR starts at step 60.
-- 4 mutant party (3 rnds + P-FROG), it will take the (59) TELEPOR 64 steps.
-- 3 mutant party (4 rnds + P-FROG), it will take the (59) TELEPOR 158 steps.
-- 4 mutant party (3 rnds + P-FROG), it will take the (EB) TELEPOR 58 steps.
-- 3 mutant party (4 rnds + P-FROG), it will take the (EB) TELEPOR 137 steps.

-- 4 mutant party, (51) GAZE in one, 36 steps (plains, please)
-- 3 mutant party, (51) GAZE in two, 62 steps (plains, then forest)

-- 4 mutant party, (F1) P-BLAST in two,    8 steps (forest-worthy)
-- 3 mutant party, (F2) P-BLAST in three, 53 steps (plains,forest,any)

-- (17) [1] Mana+5, 15 steps
-- (89) [1] Mana+5,  5 steps (No forest; Mana+4 follows)
-- (CB) [1] Mana+5, 45 steps (No forest, bad number of steps)
-- (A1) [2] Mana+5, 93 steps (No. Just, no.)
-- (E6) [2] Mana+5, 18 steps (No forest)
-- (F3) [2] Mana+5,  5 steps
-- (04) [3] Mana+5, 33 steps
-- (88) [3] Mana+5,  6 steps (No forest)
-- (F2) [3] Mana+5,  5 steps (inline with (F2) P-BLAST)
-- (03) [4] Mana+5, 34 steps
-- (87) [4] Mana+5,  7 steps (No forest)
-- (AD) [4] Mana+5, 74 steps (No. Just, no.)
-- (F1) [4] Mana+5,  6 steps (inline with (F1) P-BLAST)

-- 3 mutant party:
-- GAZE first thing: 110 steps to P-FROG left
-- P-BLAST next: 48 steps left (inside cave)  ... No, ZOMBIE blocks GAZE

-- 3 mutant party:
-- P-BLAST first thing: Wait, first forest is 27 steps away, we've got 6...

-- 3 mutant party:
-- Waste a pile of steps first?
-- P-BLAST: 99 steps left (re-order for both Mana+5s)
-- GAZE: 37 steps (in cave. Nuts, a durable ZOMBIE.)
-- Perhaps manipulate quick mana after P-BLAST? Will +10~15 mana cut it?
-- Even with 0 P-BLAST uses after P-FROG, we should have GAZE.
-- I sometimes see the encounters "shift". Maybe SKELETON instead?

--      OpenLand    Forest       Bandit Cave
--A  4, REDBULL     LIZARD       FLY     +SKELETON
--B  4, SKELETON    REDBULL      LIZARD
--C  8, ASIGARU     SKELETON     REDBULL
--D 10, ALBATROS    ASIGARU      SKELETON
--E 20, ZOMBIE      ALBATROS     ASIGARU
--F 40, GOBLIN      ZOMBIE       ALBATROS
--G 80, LIZARD      GOBLIN       ZOMBIE
EDIT: Might also help to paste some functions I've been playing around with... Just include the Master Table (The SuperRNGTable I posted a short while ago), a bit of code to actually call these functions, and we should be good.
--*****************************************************************************
local function Inc(r)   return (r%256)+1   end
--*****************************************************************************

--*****************************************************************************
local function NextRN(r)  r=(r%256)+1; return r,SuperRNGTable[r] end
--*****************************************************************************

--*****************************************************************************
local function GenRange(R,D)
--*****************************************************************************
-- Returns an integer from 0 to D. Expects the RNG index, not value.
-- Might be imprecise. If so, we'll come up with something different!
    return math.floor((SuperRNGTable[R]*(D)/255)+.5)
end


--*****************************************************************************
local function ShowNextBattle(x,y)
--*****************************************************************************
    local RN= memory.readbyte(0xC343)
    local Val
    for i= 0, 9 do
        local Str
        RN, Val= NextRN(RN)
        if     Val < 0x04 then Str= "A"
        elseif Val < 0x08 then Str= "B"
        elseif Val < 0x10 then Str= "C"
        elseif Val < 0x20 then Str= "D"
        elseif Val < 0x40 then Str= "E"
        elseif Val < 0x80 then Str= "F"
        else                   Str= "G" end
        gui.text(x+5*i,y,Str)
    end
    gui.box(x-2,y-1,x+4,y+7,0,"red")
end

--*****************************************************************************
local function ShowNextRun(x,y)
--*****************************************************************************
    local RN= memory.readbyte(0xC323)
    local Val
    for i= 0, 9 do
        local Str
        RN, Val= NextRN(RN)
        if     Val < 0x7F then Str= "N"
        else                   Str= "Y" end
        gui.text(x+5*i,y,Str)
    end
    gui.box(x-2,y-1,x+4,y+7,0,"yellow")
end

local NPCdir= {"S","N","W","E"}
--*****************************************************************************
local function ShowNextNPCDir(x,y)
--*****************************************************************************
    local RN= memory.readbyte(0xC30D)
    for i= 0, 9 do
        RN= Inc(RN)
        local Val= GenRange(RN,3)+1
        gui.text(x+5*i,y,NPCdir[Val])
    end
    gui.box(x-2,y-1,x+4,y+7,0,"green")
end
Editor, Experienced Forum User, Published Author, Skilled player (1174)
Joined: 9/27/2008
Posts: 1085
Definitely one swift stat-gaining run. It was fun watching you start damaging things in the hundreds after just a few swiftly manipulated battles. I note you were thinking about grabbing TELEPOR for use after the P-FROG bandit battle. I then started looking at the number of steps we have and the soonest we can possibly manipulate TELEPOR into existence. Here are the numbers: The 0x59 TELEPOR starts at step 0x60, while the 0xEB TELEPOR starts at step 0xF2. With a four mutant party, you need four battles to get TELEPOR. Presumably, you want 3 random battles and finish by using the P-FROG bandit battle. The 0x59 TELEPOR needs 64 steps, while the 0xEB TELEPOR needs only 58 steps when involving the forest encounter at step 0x00. Not too bad, eh? With a three mutant party, you need five battles for TELEPOR. So four randoms plus the P-FROG should do. However, there's a severe jump in steps! The 0x59 TELEPOR needs 158 steps, and the 0xEB TELEPOR takes 137 steps using the 0x00 step forest encounter. There's only 172 steps between the TOWER and the P-FROG bandit. A three mutant party would be hard-pressed to get TELEPOR while still handily defeating the P-FROG. There's a conveniently located NPC in the bandit cave we can pick a fight with, but LIZARDs aren't the squishiest things to be hitting, and we'd likely fight more than 1 at a time from this sort of encounter. Probably not a good solution for our three mutant party. In any case, the open land and Bandit Cave encounter rates are 5, while the forest is 6. No sneaky high-encounter rates anywhere along the way we can take advantage of, to my knowledge. Notably, TELEPOR doesn't appear as a battle option. You can pick this ability up without need to do any scrolling for your favorite SABER. Silly step counters if you need it (as a bonus, it cheats an RNG that shouldn't cause any encounters):
local EnCounter= 0
local StCounter= 0
local LastLoc= memory.readword(0xCCC8)
while true do
    if memory.readbyte(0xC33B) ~= 0x80 then
        memory.writebyte(0xC33B,0x80)
        EnCounter= EnCounter+1
    end
    local Loc= memory.readword(0xCCC8)
    if Loc ~= LastLoc then
        StCounter= StCounter+1
        LastLoc= Loc
    end
    gui.text(120,1,EnCounter)
    gui.text(120,9,StCounter)

    local z= input.get()
    if z.Z then
        EnCounter= 0
    end
    if z.X then
        StCounter= 0
    end

    emu.frameadvance()
end
EDIT: The [0]= thing I do in lua is just saying "put this object into index 0". It's not saying "allow this thing to be put in index 0", but rather declaring that the object must be placed there. Some table-related built-in functions of lua does not handle this well, for whatever reason, but we shouldn't need to worry about them in this case. EDIT2: I took a look at the random encounter groups, address 0xC343. The thresholds appear to be 0x04, 0x08, 0x10, 0x20, 0x40, and 0x80. A value in the range 0~3 gets one rare group, the range 4~7 gets another rare group, and so forth. The open lands of World I seem to have these encounters: 0x00 ~ 0x03 - REDBULL (1.5625%; Very rare) 0x04 ~ 0x07 - SKELETON (1.5625%; Very rare) 0x08 ~ 0x0F - ASIGARU (3.125%; Quite rare) 0x10 ~ 0x1F - ALBATROS (6.25%; Uncommon) 0x20 ~ 0x3F - ZOMBIE (12.5%; Somewhat common) 0x40 ~ 0x7F - GOBLIN (25%; Quite common) 0x80 ~ 0xFF - LIZARD (50%; Extremely common) I'm hoping this scale is a "one size fits all" kind of a deal, in that all locations have 7 possible types of encounters with these exact chances. Updated the old Master Table with values that fit with these ranges, in case you need it to analyze enemy groups.
Editor, Experienced Forum User, Published Author, Skilled player (1174)
Joined: 9/27/2008
Posts: 1085
My Master Table is actually "off by 1", with how I'm using it. Rather than using 0~255, I've decided to roll with lua's way of beginning tables at 1, so I'm using a range of 1~256. Look at all the other values that random encounters show up, and compare it to my table, and they will all look "off by one". The lookup value 0 is actually index 256 in my table. If it weren't for that "off by one" thing, you would easily see that the two numbers we should be looking at are 0x00 and 0x05. Which should look fine for the random encounters thing. As far as I know, there is a random encounter if it picks a random number less than whatever the encounter threshold is. In world I, the pure-white tiles is 5, forest is 6, and grassy lands is 14, by my measurements. ... I guess with the way I suddenly switched without an explanation, confusion is sure to show up. Would you prefer if I switch back to the old way? Here's what the old-style table would look:
local SuperRNGTable={[0]= 0x05,
       0x3C,0x97,0x97,0x8B,0x13,0xE0,0x4F,0x93,0x69,0xA9,0xB5,0x1C,0xBA,0x0D,0x9C,
  0xD7,0x9C,0xB5,0x06,0x4F,0x71,0xFE,0xED,0x46,0xCB,0xC6,0xA4,0xC2,0x57,0x0F,0xBE,
  0x45,0xFA,0xD7,0xA4,0xCB,0xD3,0xDC,0x6F,0xD5,0xD3,0xE9,0x06,0x5C,0x02,0x31,0x20,
  0x97,0xA2,0xF7,0xB5,0x0F,0xCB,0xBE,0x2D,0x09,0x71,0xF5,0x97,0x82,0x64,0x4F,0x7E,
  0x82,0x42,0xE6,0x17,0xF1,0x69,0x9C,0xCF,0xE9,0x13,0xD5,0xC6,0x9C,0xC4,0x71,0xE0,
  0x57,0x1C,0xC6,0x87,0x2D,0x0B,0x7E,0x8F,0x35,0x4B,0xB5,0x24,0x42,0xD7,0x91,0x3E,
  0xC4,0x7A,0xA4,0xD7,0xB1,0x53,0x5E,0x0F,0xA9,0xA9,0x93,0x75,0xDC,0x7A,0xB1,0x5E,
  0x1A,0xDC,0x86,0x35,0x6D,0xB3,0x3E,0xAD,0x75,0xF1,0x75,0xE6,0x02,0x1A,0xCF,0xFE,
  0xFA,0xC2,0x64,0x64,0x71,0xE9,0x1C,0xAD,0x69,0x93,0x53,0x46,0xE0,0x42,0xF1,0x60,
  0x24,0x63,0x46,0xF7,0xAD,0x8B,0x00,0x0F,0xB5,0x31,0x35,0x57,0x3C,0xA4,0xED,0x3E,
  0xBA,0x02,0x24,0x57,0x31,0x2B,0x20,0x8F,0x29,0x2B,0x15,0xF7,0xA2,0xFA,0xCB,0xDC,
  0x64,0x5C,0x06,0x46,0xED,0x31,0x3E,0xCF,0xF5,0x8B,0x09,0x64,0x7A,0x97,0xAD,0x80,
  0x7A,0xBA,0x17,0xE6,0x0D,0x93,0x60,0x2D,0x15,0xE9,0x29,0x35,0x60,0x3A,0x8B,0x1C,
  0xA4,0xE0,0x35,0x75,0xCF,0xF1,0x80,0x6F,0xC6,0xB3,0x46,0xD7,0xBA,0x24,0x6D,0xBE,
  0x3A,0x82,0x57,0x24,0x4D,0xA9,0xA0,0xED,0x53,0x53,0x69,0x87,0x20,0x82,0x4D,0xA0,
  0xE5,0x23,0x75,0xC6,0x91,0x4B,0xBE,0x4F,0x87,0x0B,0x87,0x17,0xFA,0xE4,0x2D,0x00
}
I'll be taking a look at your script. I have not made any attempts at botting, so looking at something like this should be a good experience. Plus, it should do a good job at making things more convenient. I know the feeling about the fact you haven't started yet. I want to try, knowing things won't get done if I don't, but I just have trouble getting myself into it. There's a lot to be done in this sort of run, with how its RNG works, that much is certain.
Editor, Experienced Forum User, Published Author, Skilled player (1174)
Joined: 9/27/2008
Posts: 1085
Heh, I'm fine even if it isn't in hex format. Fact is, you got a bunch of numbers for me to crunch through, so I went and processed them. Even if you recorded them as cats, flying spaceships, negative Q, etc, I'd still be able to process them (and wonder what in the world made you record them as such), so long as equal entries were given the same keywords, and I knew the relative values of each keyword, like ninja > flying spaceship or something. I've also launched my plan to implement the master table (after the above processing) in the mutant growth. It should be absolutely precise in identifying the basic growth types and what abilities show up, and mostly precise in finding the exact numbers for growth and where the ability is placed. So basically... My masterful code, it lives!! I trust that you can break it several dozen times on your next stroll through a (monster-infested) park.
local range= 16

local SuperRNGTable={
  0x3C,0x97,0x97,0x8B,0x13,0xE0,0x4F,0x93,0x69,0xA9,0xB5,0x1C,0xBA,0x0D,0x9C,0xD7,
  0x9C,0xB5,0x06,0x4F,0x71,0xFE,0xED,0x46,0xCB,0xC6,0xA4,0xC2,0x57,0x10,0xBE,0x45,
  0xFA,0xD7,0xA4,0xCB,0xD3,0xDC,0x6F,0xD5,0xD3,0xE9,0x08,0x5C,0x04,0x31,0x20,0x97,
  0xA2,0xF7,0xB5,0x10,0xCB,0xBE,0x2D,0x09,0x71,0xF5,0x97,0x82,0x64,0x4F,0x7F,0x82,
  0x42,0xE6,0x17,0xF1,0x69,0x9C,0xCF,0xE9,0x13,0xD5,0xC6,0x9C,0xC4,0x71,0xE0,0x57,
  0x1C,0xC6,0x87,0x2D,0x0B,0x7E,0x8F,0x35,0x4B,0xB5,0x24,0x42,0xD7,0x91,0x40,0xC4,
  0x7A,0xA4,0xD7,0xB1,0x53,0x5E,0x0F,0xA9,0xA9,0x93,0x75,0xDC,0x7A,0xB1,0x5E,0x1A,
  0xDC,0x86,0x35,0x6D,0xB3,0x3E,0xAD,0x75,0xF1,0x75,0xE6,0x02,0x1A,0xCF,0xFE,0xFA,
  0xC2,0x64,0x64,0x71,0xE9,0x1C,0xAD,0x69,0x93,0x53,0x46,0xE0,0x42,0xF1,0x60,0x24,
  0x63,0x46,0xF7,0xAD,0x8B,0x00,0x10,0xB5,0x31,0x35,0x57,0x3C,0xA4,0xED,0x3E,0xBA,
  0x02,0x24,0x57,0x31,0x2B,0x20,0x8F,0x29,0x2B,0x15,0xF7,0xA2,0xFA,0xCB,0xDC,0x64,
  0x5C,0x06,0x46,0xED,0x31,0x40,0xCF,0xF5,0x8B,0x09,0x64,0x7A,0x97,0xAD,0x80,0x7A,
  0xBA,0x17,0xE6,0x0D,0x93,0x60,0x2D,0x15,0xE9,0x29,0x35,0x60,0x3A,0x8B,0x1C,0xA4,
  0xE0,0x35,0x75,0xCF,0xF1,0x80,0x6F,0xC6,0xB3,0x46,0xD7,0xBA,0x24,0x6D,0xBE,0x3A,
  0x82,0x57,0x24,0x4D,0xA9,0xA0,0xED,0x53,0x53,0x69,0x87,0x20,0x82,0x4D,0xA0,0xE5,
  0x23,0x75,0xC6,0x91,0x4B,0xBE,0x4F,0x87,0x0B,0x87,0x17,0xFA,0xE4,0x2D,0x00,0x05
}

local mutRNG= {}
local mutAddr= {0xC30B,0xC34B,0xC309,0xC36F,0xC30E}
local mutName= {"main","plus","HP"  ,"pos" ,"shfl"}
--*****************************************************************************
local function RefreshMutantRNG()
--*****************************************************************************
    local T= false
    for i= 1, #mutAddr do
        local val= memory.readbyte(mutAddr[i])
        T= T or (val ~= mutRNG[mutName[i]])   -- I'm searching for any change
        mutRNG[mutName[i]]= val
    end
    return T 
end

-- After calling the above function, I can refer to the following:
--   mutRNG.main  Main mutant RNG. Determines what we get.
--   mutRNG.plus  For what ability and most stat growths
--   mutRNG.HP    Specifically for HP growth
--   mutRNG.pos   Picks what slot an ability goes into
--   mutRNG.shfl  For the Uses Shuffler

local AbilityList={
"ESP",    "BARRIER","FORSEEN","ELECTRO",
"STENCH", "FLAME",  "MIRROR 10","ARMOR",
"ICE",    "STEALTH","KINESIS","THUNDER",
"POWER",  "HEAL",   "GAS",    "xFIRE",
"oFIRE",  "BURNING","SL-GAZE","TELEPOR",
"P-FANGS","HYPNOS", "LEECH",  "P-BLAST",
"oPAR/WP","MIRROR  3","GAZE(s)","GAZE(c)",
"QUAKE",  "GAZE(d)","oDAMAGE","oCHANGE",
}

--*****************************************************************************
local function Inc(A)   return (A%256)+1   end
--*****************************************************************************

--*****************************************************************************
local function GenRange(R,D)
--*****************************************************************************
-- Returns an integer from 0 to D.
-- Might be imprecise. If so, we'll come up with something different!
    return math.floor((SuperRNGTable[R]*(D)/255)+.5)
end

local MutantTable={}
--*****************************************************************************
local function CompleteMutantGrowth()
--*****************************************************************************
    if not RefreshMutantRNG() then return end

    local main= mutRNG.main
    local plus= mutRNG.plus
    local HP  = mutRNG.HP
    local pos = mutRNG.pos
    local shfl= mutRNG.shfl

    for i= 1, range do  -- range is set at top of file
        main= Inc(main)
        local Str= ""
        local test= SuperRNGTable[main]

        if     test <=  34 then -- Ability
            Str= "AB "
            pos= Inc(pos)
            Str= Str .. GenRange(pos,3)+1
            local AB= 1
            while true do
                plus= Inc(plus)
                if SuperRNGTable[plus] >= 0xE5 then  break  end
                AB= (AB%32)+1
            end
            Str= Str .. " " .. AbilityList[AB]

        elseif test <=  68 then -- HP
            HP= Inc(HP)
            Str= "hp+" .. GenRange(HP,5)+10

        elseif test <=  98 then -- Mana
            plus= Inc(plus)
            Str= "mn+" .. GenRange(plus,4)+1

        elseif test <= 116 then -- Agility
            plus= Inc(plus)
            Str= "ag+" .. GenRange(plus,4)+1

        elseif test <= 134 then -- Strength
            plus= Inc(plus)
            Str= "st+" .. GenRange(plus,4)+1

        elseif test <= 142 then -- Defense
            plus= Inc(plus)
            Str= "df+" .. GenRange(plus,2)+1

        elseif test <= 146 then -- Shuffle uses
            Str= "!!"
            -- ... Uh, To Be Determined...

        else -- No effect
            Str= "__"

        end
        MutantTable[i]= Str
    end
end

local function Disp()
    for i= 1, range do
        gui.text(1, 9*i - 8 ,MutantTable[i])
    end
end
gui.register(Disp)

while true do
    CompleteMutantGrowth()
    emu.frameadvance()
end
EDIT: Removed an erroneous -1 from my GenRange. EDIT2: Updated SuperRNGTable
Editor, Experienced Forum User, Published Author, Skilled player (1174)
Joined: 9/27/2008
Posts: 1085
Here's my notes thus far: C309 Mutant HP growth RNG. C30B We know this already! What type of bonus the mutant gets. C30D Which way the NPC will step next. C30E Used for the Ability Uses Shuffler, for each ability. C31B HP200 RNG C323 Run away RNG C325 Flashy enemy fade-in RNG C326 Broken; Incremented every time the Uses Shuffler picks a full decrease C334 Broken; Incremented every time the Uses Shuffler picks a full increase C33B Which step triggers a random battle. C343 Monster group RNG C347: How much additional Str. and Agl. earned from STRENGTH and AGILITY potions. Rolled every time STRENGTH or AGILITY potion is used. (These potions offer a random bonus if the character's Str. or Agl. is below a certain point.) No notes. You seem to have it covered. C34B Double-burdened: Mutant stat bonus for Str, Def, Agl, or Mana; Determines which ability is selected C34F Apparently used for NPCs. Increments 0xC369 at certain values if an NPC is around. C352: Appears to affect the animation of the STENCH ability. (Rolled 4 times during GOBLIN battle around 20500 just after using STENCH, following ZOMBIE battle starting at 62550.) No notes. Odd RNG, though... C353 Number of monsters in groups RNG. C358: How much HP a POTION restores. Whenever POTION is used. (Different RNG for X-POTION?) No notes. C35A: Rolled at start of each battle turn. No notes. C35C Yummy meat RNG C369 Determines when an NPC will take a step. C36F Selects which one of 4 positions where an ability goes. C379: Rolled at start of battle. No notes. EDIT: Discovered what C325 does and realized that C3A4 is the "repeat" counter for when holding down buttons, not for C369.
Editor, Experienced Forum User, Published Author, Skilled player (1174)
Joined: 9/27/2008
Posts: 1085
Bobo the King wrote:
Sorry, still don't understand. What wouldn't work out? I mean, as long as you know what you're doing, feel free to ignore me.
The basic plan I'm thinking about. Here's where things can go wrong: - The plan of growth involves fights that ultimately kills off my fodder prematurely, slowing down acquisition of other desired abilities, notably TELEPOR, putting a rather solid wrench into my plans. - The RNG plan just happens to summon baddies I'd rather not face, like a REDBULL. And the game picks a run value that disallows me from just skipping it. - I fight for stats too much and don't get my TELEPOR at a convenient time, like right at KINGSWRD. - The manipulation is impossible within a reasonable time-span. Stuff like that. Since the RNG is so... Not random, it is crucial to come up with a plan down to the very step count on any reset.
Bobo the King wrote:
FatRatKnight wrote:
Once dead, they can't eat up any more turns, can they?
You mean off the RNG? Good question. They shouldn't, since dead characters generally don't accumulate experience points in RPGs, but there's only one way to be sure. I'm sure it'll naturally arise in one of our test runs.
Well, the menu time from actually selecting their commands is what I mean, but it's also true that they don't eat up any more RNG values for growth as well.
Bobo the King wrote:
Would you like to construct the master table, or shall I?
0x3C,0x97,0x97,0x8B,0x13,0xE0,0x4F,0x93,0x69,0xA9,0xB5,0x1C,0xBA,0x0D,0x9C,0xD7,
0x9C,0xB5,0x06,0x4F,0x71,0xFE,0xED,0x46,0xCB,0xC6,0xA4,0xC2,0x57,0x10,0xBE,0x45,
0xFA,0xD7,0xA4,0xCB,0xD3,0xDC,0x6F,0xD5,0xD3,0xE9,0x08,0x5C,0x04,0x31,0x20,0x97,
0xA2,0xF7,0xB5,0x10,0xCB,0xBE,0x2D,0x09,0x71,0xF5,0x97,0x82,0x64,0x4F,0x7F,0x82,
0x42,0xE6,0x17,0xF1,0x69,0x9C,0xCF,0xE9,0x13,0xD5,0xC6,0x9C,0xC4,0x71,0xE0,0x57,
0x1C,0xC6,0x87,0x2D,0x0B,0x7E,0x8F,0x35,0x4B,0xB5,0x24,0x42,0xD7,0x91,0x40,0xC4,
0x7A,0xA4,0xD7,0xB1,0x53,0x5E,0x0F,0xA9,0xA9,0x93,0x75,0xDC,0x7A,0xB1,0x5E,0x1A,
0xDC,0x86,0x35,0x6D,0xB3,0x3E,0xAD,0x75,0xF1,0x75,0xE6,0x02,0x1A,0xCF,0xFE,0xFA,
0xC2,0x64,0x64,0x71,0xE9,0x1C,0xAD,0x69,0x93,0x53,0x46,0xE0,0x42,0xF1,0x60,0x24,
0x63,0x46,0xF7,0xAD,0x8B,0x00,0x10,0xB5,0x31,0x35,0x57,0x3C,0xA4,0xED,0x3E,0xBA,
0x02,0x24,0x57,0x31,0x2B,0x20,0x8F,0x29,0x2B,0x15,0xF7,0xA2,0xFA,0xCB,0xDC,0x64,
0x5C,0x06,0x46,0xED,0x31,0x40,0xCF,0xF5,0x8B,0x09,0x64,0x7A,0x97,0xAD,0x80,0x7A,
0xBA,0x17,0xE6,0x0D,0x93,0x60,0x2D,0x15,0xE9,0x29,0x35,0x60,0x3A,0x8B,0x1C,0xA4,
0xE0,0x35,0x75,0xCF,0xF1,0x80,0x6F,0xC6,0xB3,0x46,0xD7,0xBA,0x24,0x6D,0xBE,0x3A,
0x82,0x57,0x24,0x4D,0xA9,0xA0,0xED,0x53,0x53,0x69,0x87,0x20,0x82,0x4D,0xA0,0xE5,
0x23,0x75,0xC6,0x91,0x4B,0xBE,0x4F,0x87,0x0B,0x87,0x17,0xFA,0xE4,0x2D,0x00,0x05
You mean this? But it isn't ready yet! ... On the other hand, I don't think I'd ever be satisfied enough anyway, so here it is now. The numbers seen above are the lowest possible values while still fulfilling all RNG stuff I've investigated. In particular, these are what I tried against it: - Ability chart (GameFAQs, oh you're so nice!) - HP200 on a Human (16 possible values!) - Small bits of data from 0xC343 0xC33B, steps for random encounters. - NPC step direction (no new info separate from the HP200 tests.) The Master Table, as is, should fail in several places when looking at mutant stat growth. We'll eventually clean those up, hopefully. EDIT:Updated Master Table to fit HP200, run away, and random encounter tests. 89 different numbers identified.
Editor, Experienced Forum User, Published Author, Skilled player (1174)
Joined: 9/27/2008
Posts: 1085
Bobo the King wrote:
FatRatKnight wrote:
Rather than manipulate the stuffing out of the luck, I'll waste all the time in the world to get the exact luck! I want to see if it'll even work out. Expect extremely long resets if I decide to release such a movie.
[...] I'm a little confused by what you're trying to do.
I want to see if it'll even work out. I'm making zero attempt at optimizing. It will show.
Bobo the King wrote:
I realized I should check the effects of ability shuffling when you have less than four abilities. Suppose you have abilities in slots 2 and 4 and C30B is 93 before you fight a battle. Do your abilities shuffle to + | + (as indicated by my current analysis) or to - | + (as would happen if the RNG for ability shuffling is rolled sequentially)? I'll look into it eventually.
My belief is that it rolls once per adjustable ability. There should be no rolls for blank spots or passive, - use abilities, but I can be wrong.
Bobo the King wrote:
[...] You don't need to follow So-Cho's sister through the subway and you can instead take the surface path to the subway near Southwest Town. Walk back through the subway until you reach the first stairs and you'll turn around and save her, even though she and the enemies aren't there! [...]
It's either take the extra steps through the subway or deal with the SU-ZAKU encounters. Either way, it's a good idea to check. I'll investigate this at some point.
Bobo the King wrote:
Now for an update on long term strategy. I've changed my mind yet again. I think it might be best to pick up four mutants and get both P-BLAST and TELEPOR, contrary to what I'd indicated earlier. [...]
Four might be a bit much. On the other hand, here's how many battles you'd have to face, at best, for each arrangement of mutants:
Mutants: 1 : 2 : 3 : 4 :
-------:---:---:---:---:
GAZE   : 4 : 2 : 2 : 1 :
P-BLAST: 7 : 4 : 3 : 2 :
TELEPOR:14 : 7 : 5 : 4 :
Compared to a 3-mutant party, a 4-mutant party can earn each of these abilities 1 battle earlier. You lose the slot for a potential monster that I so adore. By the way, I keep saying that the extra mutants are fodder and can just drop dead after their usefulness ends, after you get all the abilities you need. Once dead, they can't eat up any more turns, can they? Then again, they can act as a really nice humanoid shield, soaking up a hit that you can't take.
Bobo the King wrote:
I'm going to wait and think about strategies for another day or two, then I'll probably start that run.
If it's going to be a "finalized" run, let me get a chance at optimizing it. EDIT: I think I see better how the RNG works. Apparently, the RNG is asked for a number within a range. It divides up the random numbers such that 0x00 is mapped to the lowest value and 0xFF is mapped to the highest value, and all other values are distributed evenly in between the extremes. After finding the random value it wants to give, it picks the nearest integer and returns that. I don't know if it's really doing that internally, but I want a frame that I can think in that effectively matches the result here. The problem with doing all this is that, while all the inner numbers tend to have fractions above and below themselves, the numbers on the extreme ends only have fractions on one side, since there are no values beyond the extreme. As a result, the extreme values tend to have half as many results as any other number in the middle. See the NPC direction finder? South and East have values 0 and 3, while North and West have 1 and 2, respectively. There are 43 results each for 0 and 3, while there's nearly twice as much, 85, for 1 and 2. No wonder I was able to see a bias where NPCs love going northwest! It's also a good thing if we want to manipulate that NPC's movement like I did in my test run. I'll be making measurements to fine-tune my all-purpose RNG table. Here's hoping I get something always useful, no matter what new random number stuff we crash into. If it fails somewhere, we just adjust the table values a little to see if it matches, or look for a different RNG seed. With the way it should work, this adjustment should never break any old tests we made.
Editor, Experienced Forum User, Published Author, Skilled player (1174)
Joined: 9/27/2008
Posts: 1085
Spent a thousand rerecords and still no luck. Take the meaning however you like. Found an HP boost at 0xF0 that I previously missed as well. In order to catch both Mana boosts at 0xF2 en route to P-BLAST, it seems I must let my fodder get hit twice. Together, they barely have enough HP to survive just those (The ALBATROS deals 19 out of the 20 HP one has got). Finally picking up P-BLAST means my main character takes a hit, but she has twice the HP as either one of the fodder, so hopefully I'm fine. Rather than manipulate the stuffing out of the luck, I'll waste all the time in the world to get the exact luck! I want to see if it'll even work out. Expect extremely long resets if I decide to release such a movie. (minutes wouldn't be a bad estimate; I don't care right now) I'll also be reworking how to chart out the RNG, so that I can get a one-size-fits-all table. I notice some unusual similarities in a few of our charts (Example: The run away field, the NPC directions field). Sure, I don't see any exact 0~255 numbers, and I have no way of seeing these internal numbers, but that's not going to stop me from making attempts. Anyway, I'll keep trying. I've actually been lazy these past few days, and I wouldn't say a thousand rerecords during that time is a lot. EDIT: Just when I thought I had things covered, the game threw me a slot-3 P-BLAST. Obviously, searching for memory.readbyte(0xC30B) == 0xF2 isn't enough. I can only "..." at this point, but I'll keep at it, somehow.
Editor, Experienced Forum User, Published Author, Skilled player (1174)
Joined: 9/27/2008
Posts: 1085
I'm attempting a second run now, and I'm finding it rough to manipulate 0xC30B into becoming exactly 0xF2. In a timely manner, anyway. My current plans involve getting exactly that RNG value so that I can defeat the ALBATROS, followed by going into a forest tile and getting into a battle on the very next step, against ASIGARU. Two battles already, and well on my way to a highly-desired P-BLAST. Hopefully I can get a mana boost or two along the way on my main mutant. GAZE and TELEPOR should follow, in whichever order. I may pick up a second P-BLAST, so that my abilities will be P-BLAST P-BLAST GAZE TELEPOR. My mutant buddies are now fodder for upcoming bosses. Prior to leaving World I, I will grab an ALBATROS from the guild. This ALBATROS will be on a diet until I hit SEI-RYU dead, where it becomes DRAGON 1, then backtrack to eat a SLIME for a BEETLE to make use of SAW on BYAK-KO. Unfortunately, the plan completely falls apart if I can't get the needed 0xF2 first thing! Eyah... I'll keep trying... As for the gold, that's actually a pretty common way (At least, from what I saw in a few other games) to store some numbers -- As a decimal-represented digit each packed in nybbles. If I tell you to convert the hexadecimal number A378C53D into decimal, by hand, you're going to have a hard time. Or at least take quite some time to get the result of 2742601021. If you try changing just one of the more significant hex digits, you end up changing numerous decimal digits, and vice versa. If, however, I "waste" some of the possible hex digits, A through F, we would have a rather familiar range of 0 to 9, and knowing our self-imposed limit for each hex digit, we can very quickly convert it into a graphics tile representing a digit. However, slightly more processing must take place when adding up these digits, since they don't flow so neatly in the more familiar language of binary our computers so love. However, showing us such a number in decimal is trivial, no matter how big it gets. Whatever the case, it's good that you found how the gold is stored in memory. I wouldn't suggest using items we can't actually buy, but if you can somehow get the cash, then by all means, go ahead and try it. Another address for you, by the way: 0xCC00 This marks the start of the addresses governing your basic character stats. Things like name, current HP, max HP, Str, Def, Agl, Mana, and various item IDs and uses are here. Each character uses up 31 bytes to hold this information, so the second character starts at 0xCC1F, the third at 0xCC3E, and the fourth at 0xCC5D. If you want to cheat those to help more of your tests, may as well point out where they are for you. You should be able to find the individual stats on your own, especially if you decide to modify some of them. Be careful around the name, though. By the way, there's none of that crazy numbery stuff that gold uses. 99 Agl here is indeed 0x63 and not 0x99. BYAK-KO has indeed made quite the wall for us, eh? I've also made attempts at finding the battle RNG. I haven't been successful. SAW apparently uses your strength as part of a to-hit formula. Too high, and our strength exceeds the enemy's defense and we can't ever hit. Too low, and it's so unlikely to hit that the enemy may as well be immune. Might not be a bad idea to pick up strength as well, so we can beat the unwieldy RNG, but not too much that we exceed the later bosses. Though, SU-ZAKU has 77 defense, and all the ones after that go even higher. We shouldn't have to worry about having too much strength.
Editor, Experienced Forum User, Published Author, Skilled player (1174)
Joined: 9/27/2008
Posts: 1085
Bobo the King wrote:
[whine]Yeah, but they're sooooo out of the way![/whine] I'll see what I can do.
It all comes down to this: Will grabbing an ELIXIR save the time it takes to get one?
Bobo the King wrote:
Speaking of GAZE, can you say a little more about how it works? [...]
GAZE (death) is PARA element. Any enemies with oPARA, oPAR/WP, oCHANGE, or oALL are immune, which basically means undeads, robots, a few other enemies, and bosses. As for its hit formula, it, as far as I can tell, works just like any other status (Edit: the word magic was a bad term). And from what I read on the GameFAQs board, it's a chance out of 100, there's a base 20% chance to miss, each point of Mana you have reduces this by 1%, and each point the target has raises the chance to miss by 1%. With 20 more Mana than what the target has, it should always hit, no manipulation needed. If you max out your Mana to 99, there are few monsters that has a chance to avoid it by having enough Mana. Even those with equal Mana to yours only has a 20% chance to survive. Those are good odds! But again, things that have particular immunities will always resist it. GameFAQs has so much information! Joy!
Bobo the King wrote:
Do you seriously make these by hand, or is the process automated somehow?
I actually do make them by hand. I sit there, staring at an NPC for several minutes (and somehow they didn't get creeped out), while watching the RAM address and marking down what direction they did go in, for all 256 values. If I knew how to disassemble the game, I would be able to automate this a bit, but manual observation is all I got.
Tristal wrote:
The analysis you guys are doing is awesome. I could be really wrong about an idea I have, but if defending a physical attack (Say, BYAKKO's SWORD) is a problem, couldn't you just pick up a shield from somewhere? I'm sure you could manipulate a full block.
First, the RNG is particularly unforgiving. It may well be impossible due to how the RNG works to consistently block the SWORD attacks. Second, unless the shield protects against spells, what's stopping the ICE from going through? Lastly, we eat up a turn using the shield. Myself, I'm hoping a monster's SAW takes care of the problem instantly. EDIT: I believe I spotted the RNG used in determining how the ability uses are shuffled: 0xC30E - Picks what type of effect to place on each ability's uses 0xC326 - Incremented at every full decrease (the - in your table). Probably broken. 0xC334 - Incremented at every increase (the + in your table). Probably broken.
Editor, Experienced Forum User, Published Author, Skilled player (1174)
Joined: 9/27/2008
Posts: 1085
The golem I had after the battle definitely had 48 Mana, and very much lacked any P-BLASTs. The MUTANT F you were looking for isn't in the first slot. I've seen a monster cause blindness in World IV, but that's not exactly a nice location to get them. I picked up a list of monsters from a FAQ on GameFAQs, let's see what ctrl+F finds me... ANT LION CRAB GARUDA NIKE (not likely) DORUKO ROCK DRAGON 3 DRAGON 4 DRAGON 5 NINJA SU-ZAKU (The primary boss version) SU-ZAKU2 (... Uh, this late...?) SU-ZAKU (The "invincible" random encounter type) ASHURA (By now, it's a tad late.) Think any of them might be useful? Even a single ELIXIR should be good enough for us. Those things got 3 uses, so that equates to 15 P-BLASTs, 15 GAZEs, and 15 TELEPORs just for picking up one ELIXIR. This should be plenty, should we find the initial 5 uses for each ability too ineffective. By the way, the RNG values for abilities I was picking out were for a 3-mutant party and seeking out TELEPOR. I was picking only the optimal ones in this case. However, since you clearly have different plans, I'll pull some other RNG values you might want to consider: 0xC30B, more numbers: 0x51 - 3 GAZE (death) (4 spots away) 0x58 - 1 TELEPOR (15 spots away) 0x59 - 3 TELEPOR (14 spots away) 0xE0 - ??? TELEPOR (25 spots away, quite a range.) 0xE1 - ??? TELEPOR (24 ") 0xE2 - ??? TELEPOR (23 ") [...] 0xEA - 3 TELEPOR (15 spots away) 0xEB - 1 TELEPOR (14 spots away) 0xF1 - 1 P-BLAST (8 spots away) 0xF2 - 2 P-BLAST (7 spots away) There's only one instance of GAZE (d), on slot 3. There's two instances of P-BLAST, for slots 1 and 2. There's numerous instances of TELEPOR I haven't even checked, but I'm pretty sure we can place it in any of the four slots as we please. I'll go find the RNG address for the shuffler (just in case. It uses a different RNG I haven't searched for yet). In the meantime, I created a function that tells you what direction an NPC is headed. They seem biased towards going northwest...
local n,s,e,w= "N","S","E","W"

local NPC_dir={[0]= n,
--0 1 2 3 4 5 6 7 8 9 A B C D E F
    w,w,w,s,e,n,w,n,w,w,s,w,s,w,e, --0x
  w,w,s,n,n,e,e,n,w,w,w,w,n,s,w,n, --1x
  e,e,w,w,w,e,n,e,w,e,s,n,s,n,s,w, --2x
  w,e,w,s,w,w,n,s,n,e,w,w,n,n,n,w, --3x
  n,e,s,e,n,w,w,e,s,e,w,w,w,n,e,n, --4x
  s,w,w,n,s,n,w,n,n,w,s,n,e,w,n,w, --5x
  n,w,e,w,n,n,s,w,w,w,n,e,n,w,n,s, --6x
  e,w,n,n,w,n,w,n,e,n,e,s,s,w,e,e, --7x
  w,n,n,n,e,s,w,n,w,n,n,e,n,e,n,s, --8x
  n,n,e,w,w,s,s,w,n,n,n,n,w,e,n,w, --9x
  s,s,n,n,n,s,w,s,n,s,e,w,e,w,e,n, --Ax
  n,s,n,e,n,n,w,e,w,s,n,n,w,w,w,n, --Bx
  w,s,e,s,w,n,n,s,e,s,n,n,n,w,s,w, --Cx
  e,n,n,w,e,w,n,w,w,n,e,w,s,n,w,n, --Dx
  w,n,s,n,w,w,e,n,n,n,w,s,w,n,w,e, --Ex
  s,n,w,w,n,w,n,w,s,w,s,e,e,n,s,s, --Fx
--0 1 2 3 4 5 6 7 8 9 A B C D E F
}

--*****************************************************************************
local function ScanNPC()
--*****************************************************************************
    local Dir= memory.readbyte(0xC30D)
--    gui.text(60,126,string.format("%x",Dir))
    gui.box(60,134,68,142,0,"green")
    gui.text(63,135,NPC_dir[Dir])
    for i= 1, 9 do
        Dir=(Dir+1)%256
        gui.text(66+5*i,135,NPC_dir[Dir])
    end
end
Editor, Experienced Forum User, Published Author, Skilled player (1174)
Joined: 9/27/2008
Posts: 1085
Bobo the King wrote:
I just checked your run again and discovered you did about 70 damage to SEI-RYU with P-BLAST while your Mana was 48. [...]
33! We should be doing over 200 at 99 Mana with a P-BLAST. This is enough to one-shot most World III monsters, if not all of them.
Bobo the King wrote:
On a related note, do you know anything about FLARE? [...]
Mutants can't naturally learn FLARE. Take a look at a previous list or the growth.lua if you wish, it's not even there, let alone any possible RNG values for it. There is a FLARE book at the secret town in World III (or was it in a town in World IV?), in a shop. It should deal around twice as much as P-BLAST, but I'm not sure on this. Though, think we can even get the cash for it?
Bobo the King wrote:
What's so frustrating about this game is that there's no single, clear strategy for speedrunning it! What do we know for sure so far? That we need at least one mutant?
There's plenty of games like that, actually. I feel this is one of the easier ones to worry about. We know that humans are far too expensive for our amazingly shallow wallet. Monsters can accumulate power quickly, but getting the right ones isn't easy. Mutants gain power through randomness, which we can abuse in a TAS.
Editor, Experienced Forum User, Published Author, Skilled player (1174)
Joined: 9/27/2008
Posts: 1085
I've played a "normal" game through (script-assisted, letting me know what mutant abilities will show up). Also, having a script automate the process of grabbing the HP200s to feed my human thousands of 'em made me wonder how some players manage to get the patience to reach 4000 or so HP on their human. From what I remember, this is the list of required battles: **World I - P-FROG (bandit) - KINGSWRD (to get the sword) - Steward's crew (Not sure if the monsters can be manip'd) - STEWARD (20 damage is all you need) + Just TELEPOR to skip GEN-BU. **World II - SEI-RYU + This appears to be the only forced encounter. **World III - Fight a guard in the pub - Fight the group going after Jeanne - Fight the group guarding Milielle + TELEPOR to skip two forced battles, but not really the walking distance - BYAK-KO **World IV ? Save someone from a group of monsters - A monster guarding the path part-way up (I think it's an eye) - Fight a robotic something (On way to ERASE99) - SU-ZAKU + I'm not sure if it's necessary to save that someone. + There's a SAW item somewhere along the tower prior to this world. Grab that for an insta-death goodie for your mutant. Powerful enough to take out bosses instantly thanks to poor implementation. (if your strength is less than their defense, SAW has a chance to work, depending on some chance-to-hit formula, I believe) **The remaining portion - ASHURA - GEN-BU2 - SEI-RYU2 - BYAK-KO2 - SU-ZAKU2 - CREATOR + I came, I SAW. All of them needs a good SAWing. Here's my plans: World I: Start as MUTANT F. Pick up somewhere between 0 to 2 extra mutants and possibly a GOBLIN. Manipulate GAZE (death), TELEPOR, and P-BLAST on the main MUTANT F, your mutant buddies are now obsolete and should die whenever convenient. GOBLIN should eat a ZOMBIE to become O-BAKE to insta-kill the P-FROG (or GAZE the darn bandit to oblivion), then transform into better stuff later. World II: With GAZE (d), insta-kill single groups to manipulate stat-gains. Try to aim to turn your monster into BEETLE for the SAW, but it isn't necessary if you can swiftly kill SEI-RYU by sheer stat-manipulated damage. The monster can at least act like a pile of HP to soak up attacks. World III: P-BLAST can help with the groups of enemies you may have to face. No solid plans other than that. World IV: Your monster will protect your 40 HP, 0 Def MUTANT F you no doubt still have. And since you probably have nothing for strength, just SAW the single toughies that show up, GAZE (d) any single living groups, and see if you can't manipulate the multiple group battles away (P-BLAST twice for multi-groups you must face.). After that: It depends on how much manipulation can take place in getting SAW to hit. If you can guarantee hits first round against each boss, your monster might not be needed anymore. Try to avoid ever wasting a step. You've got GAZE (death) for anything living, so regardless of how powerful the group may be, it is possible to slay the entire stack outright (chance based on Mana, though). Manipulating stat-gains should be exclusively in the path you're going in, and not a single step of deviation. There's a few spots in the RNG which shuffles your number of uses on your abilities. There's one I missed previously, I'll update my posts with this addition (value is 0x56. I labeled it blank. I discovered it messes with your uses left). It might be possible to use these instead of a trip to an inn to get back needed abilities that you spent. That's my plans. You decide how they stack up with yours. EDIT: The best RNGs to go for on 0xC30B, it seems, are: 0x51 - 3 GAZE (death) (4 spots away. No useful bonuses along the way) 0x58 - 1 TELEPOR (15 spots away. One mana bonus available for our mighty mutant) 0xEB - 1 TELEPOR (14 spots away. Two mana bonuses available) 0xF2 - 2 P-BLAST (7 spots away. One mana bonus available) The reason I backtrack for the SLIME is because I couldn't manipulate one up for my monster in the later floors. The transformation to BEETLE for the insta-kill SAW was desired at the time, and the SLIME was the most direct monster I had to eat for it. I "knew" the BATTLE sword would be needed because that's what I've seen show up every time I played the game up to that point. I wasn't aware that it could be anything different, if at all possible. If the need can be a NEEDLE or a ROCK, I can't say I've seen it happen, yet. I didn't track the RNG for manipulating NPCs out of my way. That was, incidentally (and ironic, considering it's a TAS), sheer luck on my part. You were looking at 0xC30B for the highest mana gains? You should be looking at 0xC34B instead, since it's apparently used in determining just how big the numbers are (0xC309 is used for HP growth). On the other hand, 0xC34B is always just a value of 9 higher than 0xC30B after a reset, so the whole point sort of fades away when the only thing you're manipulating for you isn't preceded by learning an ability. As for my progress, I crashed into a wall. I just don't have the Mana needed for enough damage against all groups with P-BLAST. Nowhere near the needed amount, anyway. You've found the spots in the RNG that we may need to hunt for, which is good. I can try to find the RNG addresses for things like what determines which direction the NPC walks in or when they'll do the walking. Among other things. For now, I'll just try to figure out various aspects of the game so we can do things like manipulate NPCs into walking where we need 'em to walk. I'm also wishing I knew where to begin for ROM-hacking things like the encounter table, but I feel I would need to know the instruction set the GameBoy uses. Which I don't know and am unsure how to get access to.
Editor, Experienced Forum User, Published Author, Skilled player (1174)
Joined: 9/27/2008
Posts: 1085
I dusted off World II now. I wonder if I should have started on my merry way into turning the monster into a WARRIOR, who also has SAW...
Bobo the King wrote:
The culmination of my work (as yet) is this: http://dehacked.2y.net/microstorage.php/info/1287124710/testrun.vbm Please, please, please tell me it syncs on your computer!
I shall increase suspense and tension by writing this filler paragraph in an attempt to force you to read this rather than skip to the next paragraph which has your answer. Yes. It syncs. I was able to fully view your run. And I can definitely see what you did.
Bobo the King wrote:
•Chiefly, your battles are very inefficient. I think this is because of your minimal luck manipulation and use of four characters. From a purely stylistic standpoint, I'd rather watch a TAS that OHKOs as many enemies as possible, rather than spending a full round or so on each battle. It'll probably improve as your run progresses.
Indeed, the first one was definitely horrible. After seeing your run, it made me question my decision to sell the SABER (that thing's got decent offense, unlike RAPIER). Plus, I really should have picked on a GOBLIN or ALBATROS with their 20 HP instead.
Bobo the King wrote:
•Less luck manipulation. If you're only getting 1 or 2 Agl. (or whatever other stat) per battle, then there's hardly any point to fighting them. It's just wasted time. For example, on your way back from King Armor, you fight a Goblin and it gives just a 1 Mana bonus to the mutant in the 4th slot. As far as I can tell, there was no other benefit to that battle.
The other benefit to that battle was to get me closer to the coveted TELEPOR. I could pick at the fact that you went through many battles without a single stat gain, but I know you were going for TELEPOR as well. The 1 Mana was mostly unavoidable, but then again, I could have picked a better RNG on the path to TELEPOR. If you've been collecting data on the stat gains, I'd like to know what you've got so far. Aside from that, I've only made a basic attempt at manipulating luck, and indeed, many improvements could be made. Yet in spite of that, I tightly navigate the menus.
Bobo the King wrote:
I don't like or dislike it, but your monster is a bit of a wild card at this point. He could make your run really easy or just weigh you down. I'm interested, though.
So far, the cute critter is proving useful.
Bobo the King wrote:
•Loaded with luck manipulation. 5 Agl. per battle gets me 43 Agl. after P-Frog. That's going to serve me well.
This I find impressive. The first world is also probably the best place to grind, given how weak the monsters are and the fact mutants only care about the RNG, not the battles. Besides, it's not like we need the money.
Bobo the King wrote:
Combining the strategies of our two runs: The jury's still out on how many characters we should have, but I'm banking on two mutants. One mutant may suffice if we skip TELEPOR, but I have a feeling that will cost too much time. The potential advantage of forgoing TELEPOR would be more opportunities to pump up the solo mutant, probably attaining 99 Agl. by the end of World 1. On the other hand, two mutants would learn TELEPOR with little or no grinding, plus we could kill one off to save time later. In order of most to least likely to be optimal, I'm guessing two, three, one, and four mutant parties respectively.
I'm going to look over the Mutant abilities a quick bit... - ARMOR (You're getting use out of it. Hrm...) - POWER (I got it, but am not getting use out of it) - TELEPOR (Freaking sweet, but hard to get.) - P-BLAST (Powerful hit-all offense. Useful to have) - GAZE (death) (Played around with it, not in this test run. Nice to skip the damage numbers) These abilities give us reason to come with more than one mutant. At least, initially, when our main mutant hasn't picked up those neat abilities yet. Mana would be useful for two of these. There are times where you're stuck fighting the normal enemies, so having spells that can kill them all swiftly should be considered as well. But a high Agility is good as well.
Bobo the King wrote:
With two or more mutants, we could switch party members (as you've been doing) to soak up more high-yield bonuses. We'll have to weigh the time cost of switching party members versus manipulating luck more.
Notably, switching is more useful when focusing on getting hard-to-get abilities, like TELEPOR. Otherwise, just try to manipulate the +4 or +5 in the spot your main mutant happens to reside in.
Bobo the King wrote:
The role of the second (or third) mutant would be almost completely up in the air. Should he be strength-focused to complement our agile mutant? Should he have useful abilities for specific points in the game? Should he just be a tool for luck manipulation? Should he be killed off as quickly as possible?
Manipulation material to get our main mutant equipped with the necessary abilities first thing. The other role is either a secondary P-BLAST/death GAZE, or cannon fodder.
Bobo the King wrote:
I think that just about does it for this post. I'm glad to have finally contributed something concrete. On to World 2!
I feel like we're in a little competition, even though we are working together. Probably what pushed me into clearing out World II.
Editor, Experienced Forum User, Published Author, Skilled player (1174)
Joined: 9/27/2008
Posts: 1085
Bobo the King wrote:
My god! What did you do to the bandit??? LOL! Pretty funny since both of the times I've fought him I was extremely lucky and he decided for several turns he would instead "wait for attack".
I hit his weakpoint for massive damage! The P-FROG has xICE, and since my monster just so happened to transform into O-BAKE, with an ice attack CHILL, the instant-death was possible.
Bobo the King wrote:
What was the deal with that equipment shuffling immediately after acquiring the rest of your party? Were you throwing it out so that they wouldn't take turns in battle?
The shuffling here was to equip my party with defense-raising GOLD armor. The steps: - Remove SABER - Sell SABER (+1030 G) - Buy RAPIER and 3 aGOLD - Equip RAPIER and aGOLD on TAS - Equip aGOLD on the other two mutants - Buy two POTIONs with leftover money (which remain unused so far) The armor seems helpful, considering how much my party was hurting when I finally used the inn.
Bobo the King wrote:
Well, I am very impressed with this little run. I see now that I really shouldn't have let TELEPOR pass me by. Your strategy also seems more "honest" in the sense that it doesn't involve nearly as much luck manipulation.
Indeed, TELEPOR is extremely helpful, as demonstrated in my test run. The problem is that, even with the best RNG from a soft reset, it's the 14th mutant bonus in the list. A solo mutant must win 14 consecutive no-reset battles in the best case. If you're waste no steps, 14 battles will not happen before the P-FROG bandit. Two mutants need 7 battles, while a three mutant party can get away with as little as 5, granting me TELEPOR much sooner. See why I want more than one mutant now? My run still manipulates luck by a pretty significant amount. Just count the soft resets I go through, and it's not exactly a small amount. Even so, I "gave up" and took a RNG value that puts TELEPOR in the 17th spot, which required winning an extra battle. On the upside, it gave ICE to one of my mutants along the way.
Bobo the King wrote:
Unfortunately, I still think a solo run is theoretically faster. Not that I can prove it... grumble... If a solo run is faster but desyncs, that doesn't count for jack squat, so you're in the lead. In case you missed the second edit to my last post, I'm still having desync issues, so I'm going to attempt to code a fake autosave function in Lua. I think my problems may stem from the fact that autosave continues to operate while my script is running.
I still think a three-mutant party is fastest, thanks to the fact TELEPOR is accessible much earlier, along with other "hard-to-reach" abilities. On the other hand, once a mutant has all the "hard-to-reach" abilities you could want (TELEPOR, P-BLAST, ... Uh, another P-BLAST? Maybe a third P-Blast...), the other two would outlive their usefulness and should just drop dead in the next battle, turning it into a solo run. The purpose of the monster is to see what possible use they can be. By the end of World I, it looks like a monster works as a fat stack of HP that my mutants don't have, but insta-killing the P-FROG bandit was certainly a nice plus. I'm hoping to get a BEETLE to try out the insta-kills by SAW.
Bobo the King wrote:
Anyway, I'm in a weird position. I'm hoping I can trounce your run by getting through World 1 in 8 minutes, but since I'm having technical difficulties, I'll instead play cheerleader. Keep up the good work!
When those difficulties end, I hope to see my run trounced by a run using newly-gained knowledge. And hopefully not exclusively thanks to a 0-letter name.
Editor, Experienced Forum User, Published Author, Skilled player (1174)
Joined: 9/27/2008
Posts: 1085
Went through World I in just over 9 minutes Stats:
name  mHP St Df Ag Mn    Transition to World II

mkay  103 17  7 11 13  My monster, WEREWOLF
Run    20  9 14  7 11  Has an ICE spell. Useful-ish.
Test   55 12 16  3  9  Has POWER (dead weight) and TELEPOR (awesome)
TAS    55  6 11 13 27  P-BLAST of doom!!
I'm probably going to manipulate more agility and mana for little miss TAS at this point. Poor GEN-BU can just fight himself, I'm too busy to fight some "required" boss battle. I'm not using your script, I just have it set up so if I hold a button then frame-advance, the script blindly goes through a sequence of input. I'm still manually looking at the list of gains that show up and manually checking battles, looking for the right meat for my monster. It's possible your script itself is causing a desync. But I'm not actually sure. Some further checking may be needed. My vba.ini is almost a brand-new one, considering how recently I got VBA. Try deleting it or moving it to another folder so VBA doesn't detect it, and start fresh to see what happens. Probably wouldn't help, but aside from deleting it, wouldn't hurt to try.
Editor, Experienced Forum User, Published Author, Skilled player (1174)
Joined: 9/27/2008
Posts: 1085
Around 2 minutes in. I got myself BARRIER and POWER, and well on my way to getting P-BLAST and change my monster to O-BAKE. The POWER will help in killing a random ZOMBIE and KINGSWRD each in two rounds, as well as give GEN-BU a good smack. Just ask, and I'll upload my current run, on the spot, wherever I might be. On a side note, I programmed in a cheap macro through lua. From the field, it goes into the menu, saves the game, then resets. So I got around the difficulty of pressing four or five buttons at once. As for your desync issue, the timing difference you read about is mainly saying that movies from v19 will likely not sync at all on v20 or later, and vice versa. This shouldn't affect sync-stability for playing back movies made using the same version. I haven't run into problems myself, yet. I'm not sure what further help I can be, though.
Editor, Experienced Forum User, Published Author, Skilled player (1174)
Joined: 9/27/2008
Posts: 1085
I'm thinking I should try to make another run alongside yours, except I use 3 mutants and a monster and see how little I can get away with. Knowing myself, I always want to keep optimal in my own ways, so I may end up making progress slowly. Comparing times shouldn't be too difficult, and having two separate runs may show techniques that either player missed the first time around. So you're comfortable using a controller. I'm fine with the keyboard myself. And I'm not familiar with GlovePIE, but I do have a Wii Classic Controller.
Editor, Experienced Forum User, Published Author, Skilled player (1174)
Joined: 9/27/2008
Posts: 1085
Bobo the King wrote:
Sounds like you're warming up to a four mutant party while I'm warming up to a one mutant party! [...]
Joy, we've converted each other to the other side! We're still on the opposite sides, in some sense. How about we compensate and go with two?
Bobo the King wrote:
[...] if we can manipulate byte 0xC30B to always be [...]
Manipulating for quick stat gains should be where the RNG gives the largest amount in a few steps. Then reset and repeat. It would be best if we don't have to take extra steps just so we can grind a bit more. The trio of agility gains would be good if we want to go somewhere while still building our agility effectively. Then again, it pretty much comes down to what we need for each required battle... Everything else is just icing.
Bobo the King wrote:
Even though I'm fairly inexperienced, I'm already starting to see how Lua is implemented differently for different emulators.
Even something like joypad.set and joypad.get, (which should be) present in all emulators supporting lua, works differently from emulator to emulator. I'm not just talking about the fact each platform has different buttons, by the way -- No other emulator has four options like FCEUX's true, false, nil, and "invert" for its joypad.set. There's also a few other mechanics that aren't the same throughout.
Bobo the King wrote:
I would like to use it to pump a solo mutant up to 99 Agility in the first world, then run through the rest of the game as a demonstration run.
A demonstration is certainly a good idea. It may take a while to get the 99 agility, but definitely a good start to figure out what we may need.
Bobo the King wrote:
[...] it has 405 frames and 101 re-records (uh... why so many re-records?) [...]
I wanted to select the mutant at the speed of TAS, and wanted to be sure of the earliest possible frame it could happen. Incidentally, it's still not the fastest possible... I could still have picked that MUTANT F faster yet:
My run   Faster
 V..       V..
 V..       V>.
 ...       V>A
 V..       V.A    Faster method
 V..       ...    saves 4 frames
 ...       ...
 V.A       ...
 V.A       ...
Bobo the King wrote:
My rule on character names and other minor things is that the total time sacrificed shouldn't exceed the largest "mistake" in your run. [...]
Better than me, since I have no rules of my own for names. A 0-letter name is easily forgivable if we only have one character, since everyone should recognize that it's our solo player doing the action. Once we add a second character, giving both a 0-letter name will get somewhat confusing, but it's still fastest... That's my thoughts.
Bobo the King wrote:
I'm a little embarrassed to say I don't know what TELEPOR does [...]
Has 5 uses. Sends you straight to the tower, at whatever floor you specify. The highest floor you can specify is limited to the highest point you've reached on the tower, however. It's apparently ineffective when you're in some sort of "vehicle", like the sailing island, the glider, or the bike. 1F takes you to the starting point of the game.
Bobo the King wrote:
I would like to contribute more concrete information. Can you give me a brief overview on how you deduced the purpose of 0xC30B and its associated table? If all the information in this game is stored in tables, then I think we can probably deduce how much each stat will be boosted at the next level.
I found C30B because I knew the RNG is dumb enough to only roll whenever it's needed. This information more or less came from GameFAQs. I also recall playing around on my GameBoy Color with soft resets and all that and it seemed to shuffle how my Mutant grew. So it's a number affected by soft resetting. So I finally pick up VBA like a week ago and searched for some memory values. Start the game, clear the change counts in RAM Search (to be absolutely certain), and do a bunch of stuff I know wouldn't call the RNG for mutant growth. Changes should equal zero so far. When I soft reset, there should be a change. When I win a battle, there should be another change. I didn't expect a memory address to increment by 1 each battle, however. Apparently, it's used as a seed for the RNG, rather than a random number itself. When I added a second mutant into the party, it changed by 2 each battle. That's pretty convincing, eh? The table was constructed by going through each and every battle, keeping meticulous details on what I got. All 256. I double-check by running through several battles again while watching the memory address, thinking I should get this, and should get that. Indeed, it all matched, if I recorded things right. I don't think the game uses tables, but with how it works, it may as well. Eh, less of an overview and more detailed, I suppose.
Bobo the King wrote:
Edit: Switched to version 22 and all is well. I can now watch your movie and write my own! And my Lua script works!
Good to hear your troubles have ended. I'm currently using version 22, by the way.
Editor, Experienced Forum User, Published Author, Skilled player (1174)
Joined: 9/27/2008
Posts: 1085
Bobo the King wrote:
[...] we should have a party of four mutants, allowing us to boost one mutant's stats in almost every battle. [...]
So you're saying we should have several mutants to run through the RNG states faster, so we can grab the abilities and stats we like faster on a particular mutant. That's actually an idea. I've played around with resetting a bunch of times, and I note that 0xC34B is always 9 higher than 0xC30B, which limits our control over what abilities we want. The fastest POWER I found is when 0xC30B = 95 (hex), where it's next in queue. The fastest TELEPOR is when 0xC30B = EB on reset. in spot 14. With 1 Mutant, we'll need to fight 14 consecutive battles, but with 3, it's 5 battles, and 4 mutants lets us fight only 4 battles. The fastest P-BLAST is when 0xC30B = F2 on reset, in spot 7. Multiple mutants are looking rather attractive now...
Bobo the King wrote:
[...] Also, we would be completely at the whim of the RNG, [...]
That's somewhat true, apparently. It looks like, at a glance, that even with all the RNG-based addresses, we only have 256 possibilities on each reset.
Bobo the King wrote:
•Can you find the number of steps to the next battle? I briefly searched for a counter that decreases with every step, but it came up dry.
0xC33B is the relevant address. Note it increases with each step. I'm aware that hex values 2D 7C 96 A1 FF guarantee a battle in all places with random encounters, but I didn't check places with a higher encounter rate. Seems to follow similar RNG rules that everything else uses.
Bobo the King wrote:
•Can you update the Lua script to include the amount of growth in each variable? No big deal if you can't, since we can always manually test the growth amount, then reload a state.
Unfortunately, my knowledge of the RNG system is limited. I don't know how to disassemble ROMs to know what the code is doing. I've filled in the tables I did by manually checking every state. It's possible, by checking stuff manually and recording as we go. Then build a table in lua to hold the collected information. But that's sort of a clunky way to do it, yet that's what I did previously anyway. I do have a few addresses to look at, however: 0xC30B - Previously mentioned. Affects what base thing a mutant gets. 0xC34B - Previously mentioned. Affects what ability and 4 of the stats. 0xC309 - Affects how much HP we get. I didn't check this carefully. 0xC36F - Affects which one of four slots the ability goes into.
Bobo the King wrote:
•How much, if anything, do you know about how battles work? [...]
Practically zero, outside of what I read from the GameFAQs message board.
Bobo the King wrote:
http://towerreversed.org/ Maybe we should contact them to see what they know.
That may help us to get their thoughts. Do you want to try?
Bobo the King wrote:
I would be happy to do a quick playthrough of this game so that we both get an idea of how to proceed. I was going to make a quick movie to test for desyncing, but both of my attempts failed. When I try to replay my own movie, it just sits at the title screen doing nothing. Any idea what I'm doing wrong? If you would upload a brief movie of your own, I could test that for desyncing-- it'd at least be a start.
http://dehacked.2y.net/microstorage.php/info/870235960/FFL.vbm It should select a mutant and name her TAS, and then stop right after the naming. I haven't played around with the emulator much, yet, so I can't say what's going on. As for names, should we have interesting 4-letter names or short 0-letter or 1-letter names? Apparently, it adds to the text seen in battles, slowing us down...
Editor, Experienced Forum User, Published Author, Skilled player (1174)
Joined: 9/27/2008
Posts: 1085
Here's my thoughts: - A human isn't fit for a lot of things. Primarily due to the fact one needs money, and we'll likely be short on it. - A mutant will get things like POWER and TELEPOR right away. Limited chances for stat boosts because we'll be avoiding many battles. - A monster can gain in power very fast with a few select meats. Also, get one with SAW and insta-kill later bosses with ease, from what I heard. - I feel an optimal party would consist of a Mutant and one or two monsters. Yes, we'll have 1 or 2 empty slots. It's still a good idea to try to do a test run to get a better idea. Maybe we'll fight more things than I thought we should. - Hard reset: Turning off the game and powering it back on. This type of reset puts the RNG back to a non-random initial state. - Soft reset: Pressing A, B, start, and select simultaneously. This type of reset changes the RNG to "random" values. At least, the RNG doesn't keep going back to the same values over and over. - I would love to see any sort of test run to get a better idea on what should be done. Even one that is mostly unassisted. A human, mutant, and two monsters may be a good start to get an idea of who's good or bad. - Save & soft reset is the way to go to avoid unnecessary encounters. As a plus, it shuffles up the RNG for us. - Do we really need all four slots filled with party members? Having 4 characters means menu time through all of them, while having only 1 or 2 means we only need to pick through fewer actions. - I'm pretty sure the presence of humans and monsters don't affect a mutant growth. Wouldn't hurt to double-check, however. I did create a lua script. If you got a version of VBA that works with lua scripts, try this one out. It predicts what sort of growth to expect for a mutant. This should get a lot of the guesswork out.
local range= 16

local H,S,D,A,M,X,Y= "hp","st","df","ag","mn","AB","!!"
local _ = "__"

local Growth={[0]=H,
    _,_,D,X,_,M,_,A,_,_,X,_,X,_,_,
  _,_,X,M,A,_,_,M,_,_,_,_,M,X,_,M,
  _,_,_,_,_,_,A,_,_,_,X,M,X,H,X,_,
  _,_,_,X,_,_,H,X,A,_,_,S,A,M,S,S,
  H,_,X,_,A,_,_,_,X,_,_,_,_,A,_,M,
  X,_,D,H,X,S,Y,H,M,_,H,H,_,Y,H,_,
  S,_,_,_,M,M,X,_,_,_,S,_,S,_,M,X,
  _,S,H,A,_,H,_,S,_,S,_,X,X,_,_,_,
  _,A,A,A,_,X,_,A,_,M,M,_,H,_,M,H,
  A,M,_,_,D,X,X,_,H,H,M,H,_,_,H,_,
  X,H,M,H,H,X,Y,H,H,X,_,_,_,_,_,A,
  M,X,M,_,H,H,_,_,D,X,A,S,_,_,S,S,
  _,X,_,X,_,M,H,X,_,H,H,M,H,D,X,_,
  _,H,S,_,_,S,A,_,_,M,_,_,H,A,_,H,
  S,M,H,M,_,_,_,M,M,A,D,X,S,M,_,_,
  H,S,_,Y,M,_,M,D,X,D,X,_,_,H,X,X
}

local SelectAbility= {
  [0x15]=true,[0x16]=true,[0x20]=true,[0x29]=true,[0x31]=true,
  [0x39]=true,[0x41]=true,[0x43]=true,[0x47]=true,[0x78]=true,
  [0x7A]=true,[0x7E]=true,[0x7F]=true,[0x84]=true,[0x8D]=true,
  [0x92]=true,[0x9D]=true,[0xAA]=true,[0xAC]=true,[0xB3]=true,
  [0xB7]=true,[0xC2]=true,[0xC8]=true,[0xD4]=true,[0xE6]=true,
  [0xEF]=true,[0xFB]=true
}

local AbilityList={
  "ESP",    "BARRIER","FORSEEN","ELECTRO",
  "STENCH", "FLAME",  "MIRROR 10","ARMOR",
  "ICE",    "STEALTH","KINESIS","THUNDER",
  "POWER",  "HEAL",   "GAS",    "xFIRE",
  "oFIRE",  "BURNING","SL-GAZE","TELEPOR",
  "P-FANGS","HYPNOS", "LEECH",  "P-BLAST",
  "oPAR/WP","MIRROR  3","GAZE(s)","GAZE(c)",
  "QUAKE",  "GAZE(d)","oDAMAGE","oCHANGE",
}

local MutantTable={}

--*****************************************************************************
local function FindAbility(rng)
--*****************************************************************************    
-- The lazy way. It's slow, but easy on me, the coder.
-- I'll try something else later...
    local Sel= 1
    while not SelectAbility[rng] do
        Sel= (Sel%32)+1
        rng= (rng+1)%256
    end

    return AbilityList[Sel], (rng+1)%256
end

--*****************************************************************************
local function RefreshMutantGrowth()
--*****************************************************************************
    local x= memory.readbyte(0xC30B)
    if x == MutantTable.RNG then return end

    MutantTable.RNG= x
    local y= memory.readbyte(0xC34B)
    for i= 1, range do
        local ab
        local stat= Growth[x]
        MutantTable[i]= stat
        x= (x+1)%256
        if stat == "AB" then
            ab, y= FindAbility(y)
            MutantTable[i]= MutantTable[i] .. " " .. ab
        elseif stat=="st" or stat=="df" or stat=="ag" or stat=="mn" then
            y= (y+1)%256
        end
    end
end


local function Disp()
    for i= 1, range do
        gui.text(1, 9*i - 8 ,MutantTable[i])
    end
end
gui.register(Disp)

while true do
    RefreshMutantGrowth()
    emu.frameadvance()
end
EDIT: Updated script to account for the value of 0x56 actually messing with use counts instead of doing nothing. EDIT2: Another update; This time the value 0xF0 had to be changed to indicate an HP boost.
Editor, Experienced Forum User, Published Author, Skilled player (1174)
Joined: 9/27/2008
Posts: 1085
I'm pretty sure a Mutant would be a good choice to have. Starting as a female Mutant gives us a weapon that we can sell for over 1000G, allowing us to purchase some useful armor instantly, should we find it needed. Abusing the RNG for the right abilities is possible. Soft resets shuffles the RNG somewhat, giving us the control over it that we TASers desperately need. Imagine needing to head back to the tower, and what luck, we happen to learn TELEPOR from that boss we just fought! I'm not actually familiar enough with the game to know a good route from beginning to end (never completed it, haven't used monsters enough). But I did some digging around on how to abuse a Mutant... First off, the list of abilities a Mutant can learn is here in this GameFAQs topic. - ESP - BARRIER - FORSEEN - ELECTRO - STENCH - FLAME - MIRROR (10) - ARMOR - ICE - STEALTH - KINESIS - THUNDER - POWER - HEAL - GAS - xFIRE - oFIRE - BURNING - SL-GAZE - TELEPOR - P-FANGS - HYPNOS - LEECH - P-BLAST - oPAR/WP - MIRROR (3) - GAZE (stone) - GAZE (confuse) - QUAKE - GAZE (death) - oDAMAGE - oCHANGE Second, two useful addresses I scoped out: 0xC30B - Increments after every battle once per mutant in party. Determines what one of 8 "bonuses" the mutant may get. 0xC34B - Increments if a Mutant gets Str, Agl, Mana, or Def. Also changed dramatically if a Mutant learns an ability. Determines what ability may be learned. These are changed on a soft reset, among other things. Third, here's a couple tables I managed to create after meticulously searching through every value for C30B (Memory watch, no real hacking. Just what I observed):
Table C30B
Read C30B as a hex number, find the line that matches the left digit,
start at the leftmost element in that line, then count to the right however
high the right digit is.

0x00| HP __ __ Df XX __ Mn __ Ag __ __ XX __ XX __ __
0x10| __ __ XX Mn Ag __ __ Mn __ __ __ __ Mn XX __ Mn
0x20| __ __ __ __ __ __ Ag __ __ __ XX Mn XX HP XX __
0x30| __ __ __ XX __ __ HP XX Ag __ __ St Ag Mn St St
0x40| HP __ XX __ Ag __ __ __ XX __ __ __ __ Ag __ Mn
0x50| XX __ Df HP XX St YY HP Mn __ HP HP __ YY HP __
0x60| St __ __ __ Mn Mn XX __ __ __ St __ St __ Mn XX
0x70| __ St HP Ag __ HP __ St __ St __ XX XX __ __ __
0x80| __ Ag Ag Ag __ XX __ Ag __ Mn Mn __ HP __ Mn HP
0x90| Ag Mn __ __ Df XX XX __ HP HP Mn HP __ __ HP __
0xA0| XX HP Mn HP HP XX YY HP HP XX __ __ __ __ __ Ag
0xB0| Mn XX Mn __ HP HP __ __ Df XX Ag St __ __ St St
0xC0| __ XX __ XX __ Mn HP XX __ HP HP Mn HP Df XX __
0xD0| __ HP St __ __ St Ag __ __ Mn __ __ HP Ag __ HP
0xE0| St Mn HP Mn __ __ __ Mn Mn Ag Df XX St Mn __ __
0xF0| HP St __ YY Mn __ Mn Df XX Df XX __ __ HP XX XX

HP - Max HP
St - Strength
Df - Defense
Ag - Agility
Mn - Mana
XX - New ability
YY - Mixes up the number of uses on each ability
__ - No observed effect
Table C34B
Similar instructions as for that other table in finding the spot on the table.

Start with the first ability in our list (ESP).
Read C34B for your number, and find your spot in this table.

If you picked a YY, then whatever ability you're pointing at, that's our new ability.

If you picked __, then point at the next ability in the list, and look at the
next entry in this table, and check again.

If you run out of abilities (at oCHANGE and looking at __), then start
again at ESP and keep going.

After we get our ability, the RNG is pointing to a spot after the YY we found.

0x00| __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __
0x10| __ __ __ __ __ YY YY __ __ __ __ __ __ __ __ __
0x20| YY __ __ __ __ __ __ __ __ YY __ __ __ __ __ __
0x30| __ YY __ __ __ __ __ __ __ YY __ __ __ __ __ __
0x40| __ YY __ YY __ __ __ YY __ __ __ __ __ __ __ __
0x50| __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __
0x60| __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __
0x70| __ __ __ __ __ __ __ __ YY __ YY __ __ __ YY YY
0x80| __ __ __ __ YY __ __ __ __ __ __ __ __ YY __ __
0x90| __ __ YY __ __ __ __ __ __ __ __ __ __ YY __ __
0xA0| __ __ __ __ __ __ __ __ __ __ YY __ YY __ __ __
0xB0| __ __ __ YY __ __ __ YY __ __ __ __ __ __ __ __
0xC0| __ __ YY __ __ __ __ __ YY __ __ __ __ __ __ __
0xD0| __ __ __ __ YY __ __ __ __ __ __ __ __ __ __ __
0xE0| __ __ __ __ __ __ YY __ __ __ __ __ __ __ __ YY
0xF0| __ __ __ __ __ __ __ __ __ __ __ YY __ __ __ __

YY - This "roll" will pick our new ability.
__ - Nope. Read the next one to see if the next ability is picked
EDIT: Filled in the blank spots in my second table EDIT2: Replaced a blank spot in table C30B (0x56). Found it to affect use-counts. EDIT3: Replaced a blank spot in table C30B (0xF0). Found it to boost max HP.
Post subject: I'm voting yes. Isn't it obvious enough?
Editor, Experienced Forum User, Published Author, Skilled player (1174)
Joined: 9/27/2008
Posts: 1085
Yay! Encode! Joy! Good grief! In this run, your Settlers unit are bloodthirsty marauders bent on razing every city they come across (all two of them the Settlers found). And they can't even attack! There's an implication of having horsemen collectively destroying every city, leaving a world population of around zero (with no cities, no citizens). Such incredible history can be seen here. I didn't even know America existed back in 4000 BC, and here we are today without a single city. This really opened up my eyes!
Editor, Experienced Forum User, Published Author, Skilled player (1174)
Joined: 9/27/2008
Posts: 1085
Joy! I now see the lua documentation specific for Gens! Actually, I've not been able to find any documentation on some of the latest lua functions, such as the stylus table for DeSmuME or joypad.peek on some emulators. I just looked at _G and worked my way from there, and I can at least show that in my starting post. Though, one question I do have: Which emulators currently support input.get but not joypad.peek? I'll be taking a look at this stuff and see what I can find out. The amount of stuff I haven't kept up to date on has clearly been shown here.