Posts for TheAxeMan

Ambassador, Experienced Forum User, Published Author, Experienced player (698)
Joined: 7/17/2004
Posts: 985
Location: The FLOATING CASTLE
Sorry if it wasn't clear but my "any start state" claim only applies to the SRAM. The console RAM needs to be cleared. And to make this sound even less impressive I should point out that most of the SRAM gets cleared on starting a new game. As far as I can tell, the only thing that doesn't that matters is that RNG counter. As for testing whether it will sync from any SRAM, I've only tested changes to that value. My computer can turbo through the run in about 5 minutes so I could test every value of that counter in less than a day. It might be interesting to try totally random SRAM changes, but like I said, most of those changes will get fixed when you start your new game. I'm glad so many people liked this run! I'll be looking forward to seeing the responses to the console verification video. I might have to see if I can do a similar adaptation for the white mage run.
Ambassador, Experienced Forum User, Published Author, Experienced player (698)
Joined: 7/17/2004
Posts: 985
Location: The FLOATING CASTLE
The goal here isn't to set an initial state that helps execute a glitch or speed things up, but rather to be able to finish from any initial state. I am thinking "any SRAM" rather than just "dirty SRAM" as in Cheetahmen 2, Chrono Trigger New Game+ and others. Another possible branch description is "No Resets or Power Cycles". That doesn't give the whole story though because some tradeoffs are made to be able to sync from any starting state. So maybe "No Resets, any SRAM". The main reason to submit this was to have a Final Fantasy run that could be console verified. I'll leave it to the community to decide on the classification.
Ambassador, Experienced Forum User, Published Author, Experienced player (698)
Joined: 7/17/2004
Posts: 985
Location: The FLOATING CASTLE
Warp: Yes. It is 2800 miles from here! Driving it could be cheaper if you have a fuel-efficient car but it would be a four day drive in the nastiest weather of the year. Even once you get past the mountains sleet or freezing rain could happen anywhere. Passenger rail and long-distance bus would probably take longer due to transfers and would not be particularly safe.
Ambassador, Experienced Forum User, Published Author, Experienced player (698)
Joined: 7/17/2004
Posts: 985
Location: The FLOATING CASTLE
I thought this was fun. I felt sorry for the little girl who took a particularly brutal beating.
Ambassador, Experienced Forum User, Published Author, Experienced player (698)
Joined: 7/17/2004
Posts: 985
Location: The FLOATING CASTLE
Though it was probably best to not pick Final Fantasy for AGDQ, I am going to finish the console verification run so we can put the video up here. I am offering the names in the console playback movie as a fundraiser for dwangoAC. Once you pick the names in the beginning of Final Fantasy there is no effect on the timing of the rest of the game, so anything is fair game. I already have scripts that can generate the controller input to enter any name. I'm not sure what the best scheme would be though. It could be a donation war where the highest bidder gets to pick the names. Or it could be a raffle where some amount gives you a chance to pick one of the four names. There should be some way to let past donators in. At any rate, here is my idea. I'll finish the run in a couple weeks or so. I'll put together a package with instructions and a setup script similar to what true was able to run with so anyone with a bot can make the video. Then we'll announce the fundraiser and give at least a week or two for entries. We'll post the winning names and the setup package and then make the video. If there is interest, we may be able to stream it live. dwangoAC had been preparing to set this up and if he does it then I could easily be present.
Ambassador, Experienced Forum User, Published Author, Experienced player (698)
Joined: 7/17/2004
Posts: 985
Location: The FLOATING CASTLE
This was pretty cool. Once we decide what is in we should definitely make a hype video. It could be part of a campaign to ask for more donations. One more thing to mention is that Final Fantasy has another unique draw: I can set up the names on demand for a donation item. There are probably a few people out there who would get a kick out of seeing their name in a TAS.
Ambassador, Experienced Forum User, Published Author, Experienced player (698)
Joined: 7/17/2004
Posts: 985
Location: The FLOATING CASTLE
Thanks for running this, true! Using lua, I've tested all 256 initial values for that rng and my script syncs for all of them. I'll finish up this version of the run for console verification whether or not it's part of AGDQ.
Ambassador, Experienced Forum User, Published Author, Experienced player (698)
Joined: 7/17/2004
Posts: 985
Location: The FLOATING CASTLE
http://s000.tinyupload.com/index.php?file_id=18013980956528089469 There is an updated pack of code for the next time we want to try. I included a python version of the script that figures out the rng based on battle results and there are some instructions. Anyone else with a bot and Final Fantasy please feel free to try.
Ambassador, Experienced Forum User, Published Author, Experienced player (698)
Joined: 7/17/2004
Posts: 985
Location: The FLOATING CASTLE
I'm not sure how I got so few rerecords but probably due to my rewinding lua script. Anyway, it turns out I am bad at TASing quickly and/or rusty on platforming. The quad encode makes me look even slower though; you can see from the framecount that it isn't matched up with the others. Everything pretty much turns on picking up the baby and mostly on the levels where you need to jump up to a platform for him. The main trick is picking him up just before falling off the ledge to keep moving forward. In the last level this is tough to do without falling in the river. Another note is that even on a flat pickup, picking up on certain frames gets a slightly faster animation for some reason. I messed around trying to find movement tweaks but all I found was that if you press left+right in the air you turn left but don't lose time. I showed that off just in case anyone was counting style points. But Tompa's hopping trick is much cooler and saved time.
Ambassador, Experienced Forum User, Published Author, Experienced player (698)
Joined: 7/17/2004
Posts: 985
Location: The FLOATING CASTLE
About making addresses and other info available, it might be interesting. When I took the challenge I spent some of my time looking at memory and wasn't able to find much out in that time period. Then again, if the goal is for the result to be comparable to a realtime run then that might be too much help.
Ambassador, Experienced Forum User, Published Author, Experienced player (698)
Joined: 7/17/2004
Posts: 985
Location: The FLOATING CASTLE
Nice to see some progress! I can verify that the dungeon light script that I posted earlier syncs so far. As far as manipulating luck to delay battles, doesn't any sort of delay work? I didn't see anything different with the sliding cyclops except that you moved towards and then away. Maybe your relative position affects their RNG usage? Anyway, I'll see if I can make some lua to help maximize those 20 steps. Looks like in one case you went in and out of town again to get more steps. But a few frames in the last battle might be faster. It's hard to plan that out though. Another thing is that it seems that especially with only one or two enemies that you can kill them much faster than escape. Manipulating a low number of enemies may even be more advantageous than getting maximum steps between battles. What is the time difference between a fast kill and a quick escape?
Ambassador, Experienced Forum User, Published Author, Experienced player (698)
Joined: 7/17/2004
Posts: 985
Location: The FLOATING CASTLE
I'd like to thank everyone for their feedback. A TAS on Final Fantasy is probably more of a conceptual work of art that is more entertaining to create than watch. So when dwangoAC asked if I'd be interested I was excited about having an excuse to hack into FF again and do some interesting scripting in three different languages. I have to admit that I often have trouble watching my runs play back without falling asleep. I'd still be willing to attend and help present or whatever and I hope there's a place somewhere for a TAS at Final Fantasy. We have almost two weeks of submission window left so we can discuss other options when dwangoAC starts his thread.
Ambassador, Experienced Forum User, Published Author, Experienced player (698)
Joined: 7/17/2004
Posts: 985
Location: The FLOATING CASTLE
Scepheo wrote:
You'd have to adjust the entire movie file, load the new one into the bot...
This assumes that you need to play from a movie file. We can change the bot to run from a different program that changes based on the value set in the startup procedure. Running the lua scripts I posted earlier can get you in the mindset of thinking about more than just one movie file driving a run. The bot setups I have seen, particularly last year's AGDQ, don't seem to have thought about EMI at all. Putting the bot board in a metal enclosure and shortening the controller wires to a minimum should make a huge difference.
Ambassador, Experienced Forum User, Published Author, Experienced player (698)
Joined: 7/17/2004
Posts: 985
Location: The FLOATING CASTLE
Doesn't look like anyone checked out the demo I posted. I don't know all the differences between the bots, but Final Fantasy has very simple and consistent timing. We can account for every controller polling. EMI could still be a problem but we can experiment to see how it does. The method to adapt to the unknown initial state is pretty neat as is setting the names on demand. We could also start up Final Fantasy and leave it playing on the side while we do SMB3, ACE playaround or something on SNES. If it is still running we can go back to it between runs and at the end. This would work really well with a white mage FF run where there are a lot of slow parts before a really awesome ending. As for whether the time is too long or not, we can put several games in the submission or make multiple submissions and work with the organizers on what they think.
Ambassador, Experienced Forum User, Published Author, Experienced player (698)
Joined: 7/17/2004
Posts: 985
Location: The FLOATING CASTLE
Race vs TASbot would be cool. Not possible here because like I said, a real-time FF run would be terrible for a marathon. I am quite impressed by the realtime Crystalis runs and it would be a blast to watch a realtime runner race my Crystalis run. That game is way too laggy to sync on a bot though. As far as donation incentives, we can do names for starters. I already have an input generator that makes the input for any name and then the names don't affect timing. Another possibility is for me to make a white mage run and switch to that on a bidding war or incentive. Now that I think of it, another area I could use some help is an encoder to make a hype video.
Ambassador, Experienced Forum User, Published Author, Experienced player (698)
Joined: 7/17/2004
Posts: 985
Location: The FLOATING CASTLE
About the time, I would have have to ask for more like 80 minutes to include a little setup time. I don't think it's too long. A lot of games take that long or longer. For another thing, concentrating on one game means that there is something going on the whole time rather than messing with getting another run started and synced. It's definitely a different sort of block than last year's but I think it would be pretty neat. Having our own little event would be interesting but it is a lot of work. A separate thread would be a good way to start the discussion...
Post subject: TAS bot at AGDQ 2015 - Final Fantasy
Ambassador, Experienced Forum User, Published Author, Experienced player (698)
Joined: 7/17/2004
Posts: 985
Location: The FLOATING CASTLE
I think Final Fantasy (the original on NES) would be a good game for NESbot at AGDQ. Because of its RNG and length an unassisted run would not be good at a marathon. A TAS tames the randomness and gets the time down to 70 minutes. It also shows off some luck manipulation strategies that are not feasible in real time. I have developed some ways around the problems with getting Final Fantasy to sync on a TASbot setup. There are several issues:
  • TASbot currently can't do hard or soft resets. I know true and maybe others are looking at this but for stability and convenience I'll make a run that doesn't need to do this. I've done some planning and it should only add a minute or two.
  • The initial RAM state matters, but true's erase cart can take care of that.
  • The battle RNG is in SRAM, so it doesn't get cleared even if the RAM is fully cleared! The solution is a little procedure at the start to determine what the value was. The counter increments every other frame in battle, so a short wait can resync once we know the wait. This means that we need a way to find the value and a way to tell it to the bot. We can find the value by getting into the first battle and holding the A button. Someone puts some info (your guy's hp after the fight and maybe some other stuff) into a web page and it tells you the number you need to know. That can get to the bot pretty easily and the bot can fix the input to compensate. The time window to get the information to the bot is at least 20 seconds depending on how that fight goes, plenty of time.
  • After the first procedure, my guys have varying hp. So depending on what shape they are in there are three different ways the first boss fight can go. After that they run from some random fights and visit an inn to get to a known state.
  • The time the fight takes varies and that affects a counter used for randomizing NPC movement. This increments every frame in the outer world, towns and dungeons. If in an area where there are NPCs then there is another part of the RNG that gets altered. So I let the counter cycle to a particular value before entering the Temple of Fiends.
  • At the first boss I add some wait frames to resync the battle RNG. After that fight the RNG is the same in every case and the input can be the same the rest of the way through.
http://s000.tinyupload.com/index.php?file_id=18013980956528089469 To demonstrate and test I've set up some lua. In this case the lua is taking the place of the fm2 and providing the input. (To make this I recorded fm2s and then parsed and converted them to lua.) In this zip file there is a dir with a bunch of lua files. You'll need them all in the same directory. Load up Final Fantasy in FCEUX and run FinalFantasy-anySramNoResets.lua. If the lua interface is the same then BizHawk should work too. What this does is hit the power button, randomize the seed and then plays through to Marsh Cave. Right now it may desync after pirates, I need to fix that fight. The other folder has the code for the web page that lets you figure out the RNG. The lua code just manages it automatically but you can see how it would work if you run the page. If we go through with this DwangoAC will help get the hardware set up but not present. I'd be willing to present but I'd like to have someone else there to help. While I can easily talk about Final Fantasy for the length of the run another person could keep me more organized and we could talk about other TAS activity. The AGDQ submission window is open until Sept. 3. Who is interested in helping out? Edit: Replaced demo package with updated code and fixed the description to match. Edit: Another demo package with a more convenient python script and an explanatory readme.
Ambassador, Experienced Forum User, Published Author, Experienced player (698)
Joined: 7/17/2004
Posts: 985
Location: The FLOATING CASTLE
Ok, now that I try to do it again for a screenshot it looks fine. Sorry for the false alarm. If I see it again I'll try to figure out what happened. The QuickNES screen transition issue is repeatable though.
Ambassador, Experienced Forum User, Published Author, Experienced player (698)
Joined: 7/17/2004
Posts: 985
Location: The FLOATING CASTLE
Tried out Final Fantasy with both NES cores. As far as I can tell the problems are only graphical. In QuickNES the sliding screen transition is totally messed up. With NesHawk that works but in battle there is another graphical issue with the attack effect being black instead of white. FCEUX gets both of these right and has the same timing as far as I can tell. Final Fantasy definitely pulls some interesting graphical tricks because there is one effect that I've never seen emulated properly. It happens when you touch one of the altars, there should be a light that flies off. You can see it at about 94:20 in the SDA run: http://speeddemosarchive.com/FinalFantasy.html
Ambassador, Experienced Forum User, Published Author, Experienced player (698)
Joined: 7/17/2004
Posts: 985
Location: The FLOATING CASTLE
I watched Feasel's SGDQ run on this game and it looked pretty neat. He went through the first set of levels in about 16 minutes. I think it would be entertaining enough to escape the vault. VoD of the run here: http://twitch.tv/sda/b/541421316?t=2h25m10s
Ambassador, Experienced Forum User, Published Author, Experienced player (698)
Joined: 7/17/2004
Posts: 985
Location: The FLOATING CASTLE
Now that I think about it, the routing around Stom is centered around the timing of the levelup before Mt Sabre. So the time impact is really based on how it affects the spawning counter. The counter runs while you fight Stom but not while in the menu or warping so counter time is not the same as clock time.
Ambassador, Experienced Forum User, Published Author, Experienced player (698)
Joined: 7/17/2004
Posts: 985
Location: The FLOATING CASTLE
Nice find! Strange that it has to be Leaf but it seems otherwise the game doesn't clear the flag that says you are fighting Stom. Each time I use warp boots saves a menu visit so yeah, losing one would cost another second or so. Less than 100 frames though. Another cast of teleport also means 20 MP. There is only one point where I let my MP get that low but something else to plan for.
Dragondarch wrote:
The game disables you from using the Teleport spell, but still allows use of Warp Boots.
Actually, the published run uses teleport there. The trick is that you need to hit a different button from the one you use to dismiss the last menu. So to use teleport you need to have it equipped, hit B when the dolphin thanks you and then A for teleport. All the frames in between are lag and the controller input is not polled so the game can't tell that you pressed the button on the first frame otherwise.
Ambassador, Experienced Forum User, Published Author, Experienced player (698)
Joined: 7/17/2004
Posts: 985
Location: The FLOATING CASTLE
One more thing I noticed is that sometimes you can avoid encountering an NPC by turning the other way. This works on the guy between Wycliff and Parma for example. Turn the other way and go backwards and you won't see him.
Ambassador, Experienced Forum User, Published Author, Experienced player (698)
Joined: 7/17/2004
Posts: 985
Location: The FLOATING CASTLE
Nice improvements! On leaving towns you could try forcing better encounter by letting random npc movements use the RNG. Or hex-edit a change to the last fight so you don't have to replay the town sequence. The best way is to have some lua code that plays over and over again, but that takes time to program. The light hack script syncs so far, you can use it in the encode. Here is a version with no special hacks: Download SwordOfVermilionLight.lua
Language: lua

--Sword of Vermilion script by TheAxeMan --Lights up dungeons as if you had an eternal candle function turnOnLights() memory.writebyte(0xFFC560, 0xFF); memory.writeword(0xFFC562, 0x0800); end; function turnOffLights() memory.writebyte(0xFFC560, 0x00); memory.writeword(0xFFC562, 0x0000); end; wasInDungeon = (memory.readbyte(0xFFC551) == 0xFF); while (true) do nowInDungeon = (memory.readbyte(0xFFC551) == 0xFF); if nowInDungeon and not wasInDungeon then turnOnLights(); end; wasInDungeon = nowInDungeon; gens.frameadvance() end;
Ambassador, Experienced Forum User, Published Author, Experienced player (698)
Joined: 7/17/2004
Posts: 985
Location: The FLOATING CASTLE
That's cool, I'll edit my posts. If I remember right, Gens was the first emulator to get lua support and its support is very good. lua is a great tool, I use it extensively and highly recommend it.