The main analytical result used for this TAS

I measured the amount of instructions accurately.
As a result, we noticed the crash man stage be able to be saved.
This TAS project was started.

We used DelayDownScroll in the CrashManStage.
The Item1 used has been improved from Item1x2 to Item1x1.
We pile up enemy's landing sound , mediumNMI , JustScroll.

As a result, DelayDownScroll succeeds with Item1x1.

We obtain the saving of time because we distribute extra Item1x1 to another part.
AirShooter fills the amount of instruction. However, DelayDownScroll did not succeed because it was not filled with the launching sound.
Moreover, we have improved the part that can be saved even by DelayScrolll of other stages.

We used LuaScript for DelayScroll. Moreover, LuaScript for MegaMan2 is made for the person who wants to challenge TAS of HackRom. :)

Support LuaScript of DelayScroll
@(for Rockman2)(for MegaMan2)
This LuaScript displays various supporting information for DelayScroll.

Support LuaScript for test of DelayScroll
ifor Rockman2j
This script intentionally causes DelayScroll by using cheats. The route can be tested by this script.

Please refer to the following for details of LuaScript and details of the DelayScroll.
j  How to delay scroll (English)


*Rising rule of Item1 and Item3
The majority of this improvement is based on this TAS.
We use this idea, and it is possible to save in each stage.

The Item1 rise is not decided every time, and changes.

According to the timing that you launched Item1.

some time,
launched - rise at 0frame - rise at 3frame - rise  at 6frame
some time,
launched - rise at 1frame - rise at 4frame - rise  at 8frame

I analyzed rising rule of Item1 accurately because there were a lot of parts of it that had not understood up to now.
TraceLog is here.

EECD:SEC                        //set the carry flag.
EECE:LDA $04C0,X @ $04C4 = $67  //$04C4:
Seed of rise of Item1
EED1:SBC $0660,X @ $0664 = $41  //If 0 is exceeded, the carry flag is clear.
                                //$0664=#$41(every time)
EED4:STA $04C0,X @ $04C4 = $26
EED7:LDA $04A0,X @ $04A4 = $5F  //$04A4:Y of Item1
EEDA:SBC $0640,X @ $0644 = $00  //If carry flag is clear , Y of Item1 is decreased(-1).
EEDD:STA $04A4,X @ $04A4 = $5F
EEE0:CMP #$F0                   //Judgment where Item1 disappears outside screen.

I can explain rising rule of Item1 based on this idea.
The rising rule of Item1 is decided depending on Item1x1($4C4),Item1x2($4C3),Item1x3($4C2),Item3($4C2).

If you raunched Item1,
every frame , $4C4=$4C4-0x4.   And, Item1 rises when $4C4 exceeds 0.

Example of Item1 rise($4C4 value of each frame is traced.
$8C->$4B->$0A->$C9(Item1 rises)->$88->$47->$06->$C5(Item1 rises)->$84->$43->$02->$C1(Item1 rises)->$80->$3F->$FE(Item1 rises)c

Moreover, arms that influenced $4C4-$4C2 became the following.
$04C4 :A,Q,M,C(explosion),1
$04C3 :A,B,M,Q,C(explosion),1
$04C2 :A,B,M,Q,C,1,2,3


Support LuaScript was made this time.
LuaScript that supports rising rule of Item1,3 (for Rockman2)

"|...|" means  gup wait wait wait uph
You launch Item1x1 according to this timing , An initial value is Y=180.  Item1x1 rises to the 0th frame and the 4th frame. After 4 frames, it becomes Y=178.

Manner of operation:
S=The height list of each value of Seed is output.(CSV)
Display "|c|" of the hint of height is increased.
Display "|c|" of the hint of height is decreased.
Y=Item1x1Seed($4C4) is added by the cheat. 
H=Item1x1Seed($4C4) is subtracted by the cheat. 
U=Item1x2Seed($4C3) is added by the cheat.
J=Item1x2Seed($4C3) is subtracted by the cheat.

I=Item1x3Seed($4C2) is added by the cheat.
K=Item1x3Seed($4C2) is subtracted by the cheat.

You can increase the hint display. (You understand the height after 40 frames of Item1.)

The optimum solution will be found according to the following procedures.
The hint display is increased to a near frame that you rise to Item1.
   And, the seed is changed by the cheat within the range of 0-255.
   And, the pattern that becomes a timely rise is found.

When a good pattern is found,
   you make Item1 the same rising rule by adjusting the seed.

*Frame rule of boss's HPUnderwater frame rule
Mr. aglasscage lost frame by the boss's HP processing of the game against bubble man.
I decided to doubt it, and to analyze the frame rule accurately.

First of all, the boss's HP processing is traced.

$812F:A5 1C LDA $001C = #$78
$8131:29 03 AND #$03
$8133:D0 08 BNE $813D
$8135:EE C1 06 INC $06C1 = #$00 //$1C AND #$03=#$00
then BossfsHP + 1
$813D:60 RTS

every frame , $1C=$1C+1 .
And, if the result of $1C AND 0x03 is 0x00, boss's HP is added.
The adjustment of the value of $1C is impossible.   And, boss's HP rises once per four frame in a usual boss.
I observed the memory.

Boss's HP is sure to increase every 4 frames usually.
However, the boss's HP increase processing is skipped once per 4 frame when you are in water.
(There is a frame that becomes a transaction rejection once per 4 frame in water.)
As a result, the coming HP increase processing might be skipped once per 4 frame.
Then, timing that boss's HP increases only once per 8 frame might be caused.
You lose frames when there is a lot of timing that becomes per 8 frames.

The value of flag "$FC" of water circulates between "0-4" only while you are in water.
This value can be adjusted by changing the number of frames that you are in water.

When we entering the gate,
@$FC is changed to 0-4 by using the cheat code.
And, the pattern to which frames can be saved most is found.
And, the number of frames that is besides water is adjusted.
As a result, we broke the frame rule. :)

*Frame rule of MechDragon and GutsTank

The frame rule exists in the explosion processing of MechDragon and GutsTank.
The value of $B2 is a counter when the blackout processing and RockMan become sticks.
In this figure, as for defeating the boss, v2 is faster.
However, you understand frame that the blackout begins is the same.

Result of trace is here.

9131 LDA $1C
9133 AND #$0F
9135 BNE $9164
915B DEC $B2
9164 RTS

The value of $B2 is subtracted every 16 frames.
And, the blackout processing starts when $0C becomes # $0C.
every frame , $1C=$1C+1 .
In a word, the change in this frame rule is impossible.

In a word, when you save by about 16 frames in RockMan2,
You become possible to save in W1 and W3.

* The hit judgment is changed when colliding with the enemy.
You collide with the enemy while the CrashBomb is exploding.
Then, the enemy in a place away might be able to be destroyed.

However, nobody has understood why to cause this mechanism.
I analyzed it accurately this time.
Result of trace is here.

$E606:BC 90 05  LDY $0590,X @ $0594 = #$00   A:01 X:04 Y:74 P:nvUbdIzc@Hit judgment number(arm)
$E609:B9 DC D4  LDA $D4DC,Y @ $D4DC = #$00   A:01 X:04 Y:00 P:nvUbdIZc
$E60C:65 08     ADC $0008 = #$74             A:00 X:04 Y:00 P:nvUbdIZc
$E60E:A8        TAY                          A:74 X:04 Y:00 P:nvUbdIzc Y=A
$E60F:38        SEC                          A:74 X:04 Y:74 P:nvUbdIzc
$E610:A5 2E     LDA $002E = #$14             A:74 X:04 Y:74 P:nvUbdIzC 2E=
X of Enemy
$E612:FD E0 06  SBC $06E0,X @ $06E4 = #$40   A:14 X:04 Y:74 P:nvUbdIzC A-(
X of arms in screen)
$E615:B0 04     BCS $E61B                    A:D4 X:04 Y:74 P:NvUbdIzc
carry flag then branch
$E617:49 FF     EOR #$FF                     A:D4 X:04 Y:74 P:NvUbdIzc
$E619:69 01     ADC #$01                     A:2B X:04 Y:74 P:nvUbdIzc A + #$01
$E61B:D9 E1 D4  CMP $D4E1,Y @ $D555 = #$4C   A:2C X:04 Y:74 P:nvUbdIzc *D4E1+Y:
Width of hit judgmentiX)
$E61E:B0 11     BCS $E631                    A:2C X:04 Y:74 P:NvUbdIzc
carry flag then branchiX coordinates are corresponding.j
$E620:38        SEC                          A:2C X:04 Y:74 P:NvUbdIzc
$E621:A5 00     LDA $0000 = #$64             A:2C X:04 Y:74 P:NvUbdIzC
$E623:FD A0 04  SBC $04A0,X @ $04A4 = #$4E   A:64 X:04 Y:74 P:nvUbdIzC A-(Y of arms in screen)
$E626:B0 04     BCS $E62C                    A:16 X:04 Y:74 P:nvUbdIzC
@carry flag then blanch
$E62C:D9 81 D5  CMP $D581,Y @ $D5F5 = #$1C   A:16 X:04 Y:74 P:nvUbdIzC
@*D581+Y:Height of hit judgmentiYj
$E62F:90 0F     BCC $E640                    A:16 X:04 Y:74 P:NvUbdIzc
@ Collision!@Not carry flag then branch
$E640:A4 A9     LDY $00A9 = #$08             A:16 X:04 Y:74 P:NvUbdIzc A9=now arm

This result shows
1:If you damaged from enemy ,  $06EE becomes coordinates of RockMan's damage.

$06EE is used as X coordinates and a hit judgment number of arms.
When you damaged from enemy again, the collision judgment processing of launched arms and enemy starts.
During the collision judgment processing , "Width of the judgment of arms" and "Height of the judgment of arms" change by $06EE.
As a result, when arms collided with the enemy, it is misjudged.

Width of X coordinates of hit judgment Memory($D4E1,$06EE)  The maximum value is #$50 at $D575.

Height of X coordinates of hit judgment
Memory($D581,$06EE) The maximum value is #$FF at $D678.


For instance,  $06EE=0x46 at W4.
Width of X coordinates of hit judgment = ($D4D1,0x46)=$D527=0x30
Height of Y coordinates of hit judgment = ($D581,0x46)=$D5C7=0x28

Width of hit judgment at time usually.

Momentary hit judgment that collides with enem.
The hit judgment grows, and the enemy in a place away is defeated!

I think about the adjustment.
If you hope for the adjustment of $06EE, RockMan should damaged from enemy.
2:The kind of arms is unrelated.(
Arms other than crashbomb also succeed.)
3:You should change the value of $06EE within the range of 00-FF.
@And, you should confirm width and height of the hit judgment.
4:If you maximize the hit judgment , you can considerably defeat the enemy in the distance.


*Screen shift display support Lua

When the screen shifts, You do not understand geographical features where RockMan exists.
I made LuaScript for the support.(LuaGD is necessary.)
The map and the position where actual Rockman are displayed.

In the NicoVideo, Mr.Pirohiko is transplanting this script for Lua for aviutl.

Screen shift display support Lua
(for all stages