Posts for Gunty


1 2
6 7
Experienced Forum User, Published Author, Player (198)
Joined: 12/3/2006
Posts: 151
Nice additions :) I dug up some more scripts I made a while ago to help analyse/predict the RNG: terranigma_rng.lua terranigma_rng_parasite.lua terranigma_rng_crits.lua The first script is a generic script that shows a table of future random numbers that the RNG will generate. The second script predicts which random numbers will make the Parasite boss spawn its spikes. The last script predict which random numbers will result in a critical hit, although I haven't tested this one too much.
Experienced Forum User, Published Author, Player (198)
Joined: 12/3/2006
Posts: 151
Here's the the second part of the game (until right after hitting the 40000 exp mark in the sewers), using the NeoFang route: http://dehacked.2y.net/microstorage.php/info/499690207/neofang.smv Some numbers in the comparison are different from before, since somewhat different strategies were used NeoFang vs. EnbuPike
  • Not ressurecting of Mu: -2350 frames
  • Extra Louran grinding (2914 exp) +7000 frames
  • Sylvain castle fights against the skeletons (-80f), first Soul Knight (-500f) and the second Soul Knight (-150f): -730 frames
  • Gumin forest weapon switch (-130f) and killing (-100f): -230 frames
  • Mermaid tower killing: +600 frames
  • Fish boss takes fewer hits: -1000 frames
  • Not collecting the EnbuPike before GLC: -4300 frames
  • GLC grinding: +8650 frames
  • Two more hits required against the GLC boss: +310 frames
  • Two weapon switches before the Security Robot: +410 frames
  • 12 more hits required against the Security Robot: +500 frames
  • One more weapon switch after the Security Robot: +150 frames
  • Shorter sewers grind: -9700 frames
  • Total: -690 frames
Conclusion: this route seems to be 11.5 seconds faster than the EnbuPike route. However, this method does somewhat less damage after the sewers grind than the EnbuPike route. This means that some more time may be lost when killing enemies along the way in the final part of the sewers. Sacrificing a second by getting the GeoStaff is probably worth it to deal more damage in Beruga's Lab and in the Neotokio sewers...
Experienced Forum User, Published Author, Player (198)
Joined: 12/3/2006
Posts: 151
Indeed; 12.5 second on 3.5 hours is like.. 0.1%? Kinda makes you wonder if it is worth the effort to figure this out :p
Experienced Forum User, Published Author, Player (198)
Joined: 12/3/2006
Posts: 151
So I also made some kind of test TAS, to experiment with the route planning in the second half of the game. This movie tried the EnbuPike path, where some leveling parts have been replaced by collecting the EnbuPike instead. The movie is split up in 3 parts because I had to edit in the EnbuPike since I was too lazy to ressurect Mu and play all the way up to Sylvain castle: http://dehacked.2y.net/microstorage.php/info/1657121529/enbupike_part1.smv http://dehacked.2y.net/microstorage.php/info/138841961/enbupike_part2.smv http://dehacked.2y.net/microstorage.php/info/232821868/enbupike_part3.smv Note that the EnbuPike is edited in the inventory between parts 1 & 2. Collecting the EnbuPike properly would add another ~4300 frames to the movie length. Comparing the total movie lengths isn't very insightful due to the different levels of optimization, so here is a more detailed comparison of the movie differences: EnbuPike vs 3PartRod
  • The ressurection of Mu: +2350 frames
  • The movie starts at Sylvain Castle at level 19 (18808 exp) compared to level 20 (21559 exp). This means that the current movie collects 2751 less exp in Louran. Counting an exp collecting rate of 25 exp/sec: -6500 frames
  • The lower level in Sylvain castle results in longer fights against the skeletons (80f), first Soul Knight (500f) and the second Soul Knight (150f): +730 frames
  • Clearing the Gumin forest requires an additional weapon switch (130f) and killing the monsters takes an additional hit (35f x10): +480 frames
  • Fish boss takes 5 more hits: +1000 frames
  • Collecting the EnbuPike before GLC: +4300 frames
  • Skipping the experience collecting in GLC: -9150 frames
  • 2 fewer hits required against the GLC boss: -310 frames
  • Not collecting the 3PartRod: -3600 frames
  • 7 more hits required against the Security Robot: +250 frames
  • Extra experience collecting in the sewers: +9700 frames
  • Total: -750 frames
Conclusion: I think this strategy is at least 12.5 seconds faster. Level 27 vs level 28 against Dark Gaia Getting to level 28 requires 4805 more experience. This takes about 4000 frames in the sewers, with an additional 500 frames for the levelup animation. Comparing the second phase of the Dark Gaia fight, my version takes about 4570 more frames, meaning that a total of 70 frames is lost. However, considering my horrible/non-existing luck manipulation, I estimate that an optimized Dark Gaia fight at level 27 can save up to 30 seconds. Other notes
  • Death-warping from Eklemata to Freedom after Beruga's Lab saves about 10 seconds.
  • Getting the 1700 gems in Africa on the way to Yunkou is a fast gem source (120 gems/sec).
  • A lot of fast experience (7036 exp) can be gained on the way from the sewers to the final boss, so getting to 40000 exp against the purple robot balls in the sewers should be enough.
Now I wonder how the strategy of skipping both EnbuPike and the 3PartRod plays out. I may do a similair comparison of it in a while.
Experienced Forum User, Published Author, Player (198)
Joined: 12/3/2006
Posts: 151
AsFarAsIGet wrote:
So there are actually intervals, where u do more and less damage, is that right? o.0
Yep, the damage you do fluctuates between 5 levels: 75%/87.5%/100%/112.5%/125%. http://tasvideos.org/forum/viewtopic.php?p=219965#219965
Experienced Forum User, Published Author, Player (198)
Joined: 12/3/2006
Posts: 151
These are some of the Lua scripts: terranigma_collision_map.lua terranigma_exp_timer.lua terranigma_dmg_graph.lua You can use them like this:
Language: Lua

require "terranigma_collision_map" require "terranigma_exp_timer" require "terranigma_dmg_graph" currentInput = {} previousInput = {} while true do previousInput = currentInput currentInput = joypad.read(1) if currentInput["L"] and not previousInput["L"] then exp_timer.toggle() end emu.frameadvance() end
Sorry for the lack of proper commenting :p
Experienced Forum User, Published Author, Player (198)
Joined: 12/3/2006
Posts: 151
TheAngryPanda wrote:
How exactly does this work?
Like this: http://dehacked.2y.net/microstorage.php/info/1548459680/funky_jump.smv
  • First make sure you're running up, next to the Elder
  • Press left or right for one frame
  • Press down for two frames
  • Then press right to face the Elder
  • On the next frame, press A to talk to him
  • When given the dialogue choice, press B
So why does this work? First: when you're jumping, the jump is made in Ark's current movement direction. Second: when you turn, you will continue moving towards your current direction for 1 frame (there is an exception when you turn from left to up/down, but I consider that a bug). If you combine these two, it allows you to jump in a certain direction, while facing another. The whole dialogue with the elder just comes in-between.
TheAngryPanda wrote:
Also, Gunty, are you still working on that lua script with all the information on it? If so, do you plan to release it at some point? That script is just amazing, awesome work.
Not actively, but I've been asked by other people to share it, so I will try and clean it up a bit before sharing it. Any particular one you're interested in?
Experienced Forum User, Published Author, Player (198)
Joined: 12/3/2006
Posts: 151
Lemon wrote:
So... I did a full TAS... kind of
Interesting video! I really liked the part where you repeatedly killed the Grecliff boss; that should help close the experience gap between the Parasite leveling session and Louran. However! I'm not convinced that the second part of your run is optimal :p. I think there are at least two better alternatives to using the 3PartRod against the Security Robot: either the NeoFang or the EnbuPike (possibly with a lower level). Maybe I should try making a run similar to yours, since I have never actually tried these strategies in practice...
Experienced Forum User, Published Author, Player (198)
Joined: 12/3/2006
Posts: 151
Warepire wrote:
Samsara and Gunty: Has anything happened to this TAS?
I haven't spent much time on it, besides some minor route-planning research. While I enjoy the long-term planning of this game, I never really planned on making an actual TAS. The manual movement optimization and luck manipulation are too labor intensive for my taste.
Experienced Forum User, Published Author, Player (198)
Joined: 12/3/2006
Posts: 151
Talking about helpful Lua scripts; this one could help a lot when optimizing movement/corner boosting: Link to video Regarding a long term planning issue: BonePins The SDA run uses BonePins in the following places to save time:
  • Sylvain Castle after the basement switch
  • Beruga's Lab after the first switch
  • Neotokio Sewers after getting the Starstone
  • Storkolm after getting Hero Pike/Armor
An additional 24 seconds can be saved by using BonePins in the following locations:
  • Mermaid Tower after getting the Engagement ring
  • Mu after getting the EnbuPike
Of course 2 additional Magirocks would need to be collected. Luckily, this trick allows you to use a GrassPin to regain 4 Magirocks without having to go through the lengthy magic animation. Together with the Magirock found in Zue on the screen left of Altar 2 (which is the fastest obtainable one I think), this should yield enough Magirocks to buy the required amount of BonePins. If anyone has more ideas for using BonePins to save time: please share! :)
Experienced Forum User, Published Author, Player (198)
Joined: 12/3/2006
Posts: 151
It's a visual representation of the damage bonus/penalty you'd get in the near future (right of the red line) and some time in the past (left of the red line), which fluctuates between 5 levels. You could get the same information using RAM watch, but I found doing bitwise AND operations in my head to be quite tiresome. At this point in the game, I think being level 3 or 4 would be a reasonable guess. But that wouldn't really matter since you can kill the spikes in one shot anyway.
Experienced Forum User, Published Author, Player (198)
Joined: 12/3/2006
Posts: 151
I'm currently making some Lua scripts that could help when making a Terranigma TAS. I currently have an RNG watcher (also shown in the previous video), a graph showing the damage fluctuations (-1/4, 1/8, 0, +1/8, +1/4) and a timer to keep track of Exp gathering speed. Here's the same Parasite video as before using the new Lua scripts: Link to video Some things I would like to add are enemy health bars, and a script to help movement optimization by showing a collision map of the current area.
Experienced Forum User, Published Author, Player (198)
Joined: 12/3/2006
Posts: 151
Here's a video on how Parasite grinding could look like in a TAS: Link to video This comes down to about 13.6 Exp/sec, which could even be higher with improved luck manipulation. This is the fastest place to gather experience until Louran graveyard, which means that enough experience should be gathered here to be at an adequate level for taking on Dark Morph in Eklemata (level 15 I'd say).
Experienced Forum User, Published Author, Player (198)
Joined: 12/3/2006
Posts: 151
I had to switch the color positions, or Youtube would complain about identical video uploads: Unscaled 1:1 (yellow-black) http://www.youtube.com/watch?v=1GqrEgvwBx8 Unscaled 1:1 (red-green) http://www.youtube.com/watch?v=gl0ZhNYHwQQ
Experienced Forum User, Published Author, Player (198)
Joined: 12/3/2006
Posts: 151
Youtube scaling 1:1 to 4:3 (yellow-black) http://www.youtube.com/watch?v=N5Z5-U3m1Bo Youtube scaling 1:1 to 4:3 (red-green) http://www.youtube.com/watch?v=bDmA7Bgq-Wo Each color block is 2x2 (chroma is point sampled to YV12), resulting in a total image resolution of 32x32.
Experienced Forum User, Published Author, Player (198)
Joined: 12/3/2006
Posts: 151
Aktan wrote:
Oh, we know there is no transcoding, but the scaling is done on fly. The question in which order. In one way (resize, then colorspace conversion) would introduce color bleeding. The other way (colorspace conversion, then resize) would not. That is the test we are talking about.
Excuse my ignorance :) Maybe the following examples are of use? Native 4:3 source http://www.youtube.com/watch?v=sMUE1aUHm00 Youtube scaling 1:1 to 4:3 http://www.youtube.com/watch?v=nmaQ2903Ovw If I may give my uneducated opinion: I see no color bleeding in the second video, and the edges appear to be sharper.
Experienced Forum User, Published Author, Player (198)
Joined: 12/3/2006
Posts: 151
I'm quite sure there is no transcoding going on when using the 4:3 or 16:9 tags, just rendering at a different pixel aspect ratio. You can test it quite easily: just add or remove the tags to one of your videos and observe how it is instantly rendered at a different aspect ratio.
Experienced Forum User, Published Author, Player (198)
Joined: 12/3/2006
Posts: 151
Make sure the following line is set to true in your snes9x.cfg file:
APUEnabled            = TRUE   # true to enable the sound CPU
Experienced Forum User, Published Author, Player (198)
Joined: 12/3/2006
Posts: 151
nitsuja wrote:
But that script won't work in Snes9x because the following things are missing from Snes9x Lua:
  1. a way to emulate a frame without pausing afterward if the user is using the frame advance hotkey (this one really hurts)
Indeed, that's the functionality I was missing in my current implementation. I guess I could simply bind the pause hotkey to my current frameadvance button and be done with it. With some simplifications (and turning off savestate compression), the script now runs at about 10 fps which is reasonable.
Language: lua

function customFrameAdvance() savestate.save(mySave) emu.frameadvance() getCollisionData() savestate.load(mySave) drawCollisionData() emu.pause() end
Experienced Forum User, Published Author, Player (198)
Joined: 12/3/2006
Posts: 151
Awesome timesaver :-) Also, one technique I forgot to mention (used in the smv I posted earlier): by running into corners diagonally, you can boost yourself 1 pixel ahead. I'm not sure if you already knew, but I thought I'd mention just in case. Also also, regarding the EnbuPike: ignore what I previously said. I further corrected my previous calculations and the difference is just too small to make an accurate guess on which route is faster. I would say collecting the EnbuPike before GLC would be the most entertaining option since that would eliminate one grinding session entirely (at the cost of one longer grinding session in the sewers)
Experienced Forum User, Published Author, Player (198)
Joined: 12/3/2006
Posts: 151
Is there a way to get rid of the 1-frame delay when drawing to the screen? That is, display graphics based on the frame that was just emulated (assuming frameadvance is used). I tried several methods, including the gui.register function, and some elaborate savestate saving/loading methods to look ahead 1 frame in the future, but none of them worked so far. Edit: the best I could come with is this pseudo frameadvance function to ahead in the future, and using the unpause hotkey to advance a frame. I'm guessing there has to be a better way.
Language: lua

function customFrameAdvance() savestate.save(mySave) emu.frameadvance() getCollisionData() drawCollisionData() emu.frameadvance() myImg = gui.gdscreenshot() savestate.load(mySave) gui.gdoverlay(myImg,1) emu.pause() end
Experienced Forum User, Published Author, Player (198)
Joined: 12/3/2006
Posts: 151
Well, I recently did some more research and I wanted to share the following findings:
  • Getting all 4 STR Potions saves at least 90 seconds over skipping them all.
  • Skipping the EnbuPike saves about 15 to 20 seconds, compared to using it on Hitoderan and GuardRobot.
The reason why skipping the EnbuPike turned out to be faster is because the assumption of being level 20 when starting the Great Lake Caverns (as stated in my previous calculations) is not very realistic. This is because level 20 should already be reached in Sylvain Castle, for fighting the 2 Soul Knights. For the record, this is how the last part of the optimal level progression for a TAS would look like:
  • Start of Sylvain Castle: Level 20
  • Just before fighting Hitoderon: Level 23
  • Just before fighting GuardRobot: Level 24
  • Just before fighting Dark Gaia: Level 27
The large grinding sessions will be the Parasite fight (?), Louran graveyard (~lvl 19, 5 minutes), Great Lake Cavern (~lvl 23, 3 minutes) and Neotokio Sewers (~lvl 27, 4 minutes).
Experienced Forum User, Published Author, Player (198)
Joined: 12/3/2006
Posts: 151
Nicos wrote:
i'm 99% sure it's giving me a headache....
Haha. Maybe the following translation is more insightful ;) If Y,B,X and A are pressed: Write 700 to $09c2 and $09c4 Write 300 to $09d4 and $09d6 Write 100 to $09c6 and $09c8 Write 20 to $09ca and $09cc Write 20 to $09ce and $09d0 Write 0xF337 to $09a2 and $09a4 Write 0x100F to $09a6 and $09a8
Experienced Forum User, Published Author, Player (198)
Joined: 12/3/2006
Posts: 151
Looking at the disassembled code, I'm 99% sure it's a debugging code: http://pastebin.com/XVQJHiGg
Experienced Forum User, Published Author, Player (198)
Joined: 12/3/2006
Posts: 151
While I still have some ambition to finish the Ancient Cave TAS some day and maybe optimize some of the puzzles, a full regular playthrough TAS requires a too large time investment for me at the moment. I believe I started optimizing the Alunze colored block puzzle about a year ago, but I never finished it.
1 2
6 7