FrigidCoffin¶
Many of the logic here is shared by Moth's basic attack. As such, it is assumed that the actor is Moth
's player party member.
It is also assumed that this action cannot target a Flying
target.
DoCommand calls¶
# | Conditions | timer | commandtype | data |
---|---|---|---|---|
1 | None | 25.0 | RandomPressKeyTimer | {0.0, 4.0} |
2 | DoCommand 1 set commandsuccess to true |
120.0 | SequentialKeys | {3.0} |
DoDamage calls¶
# | Conditions | attacker | target | damageammount | property | overrides | block |
---|---|---|---|---|---|---|---|
1_a | DoCommand 1 set commandsuccess to true |
Moth 's player party member |
availabletargets[target] |
Moth 's atk unclamped - 1 + combo after DoCommand 2 (from 0 to 3 inclusive) |
Magic | Empty array | false |
1_b | DoCommand 1 set commandsuccess to false |
Moth 's player party member |
availabletargets[target] |
Moth 's atk unclamped |
null | {NoSound} | false |
Freeze infliction logic¶
Right after the DoDamage 1_a call happens, there is some custom Freeze infliction logic that falls outside of CalculateBaseDamage. Since this DoDamage call doesn't have a Freeze
property, it can't inflict it, but the action still can with this custom logic that differs slightly from the one used in the damage pipeline.
The condition will be inflicted if all of the following are true:
- If
combo
is higher than 2 (all inputs were pressed correctly after DoCommand 2) lastdamage
is higher than 0 (DoDamage 1_a dealt more than 0 damage to the target)- target's
freezeres
is lower than 100 (it's not immune) - A resistance test passes with target's
freezeres
- 30 (- 35 instead ifMoth
hasStatusBoost
medal equipped).
The resistance test is performed by generating a random number between 0 and 99 inclusive and seeing if this number is at least the calculated resistance. The test pass if it is and fails if it's not. Exceptionally, if the target's freezeres
was already 30 or below, the test always passes.
These conditions differs from the ones in the damage pipeline logic. Here's the differences:
- The resitence test has 2 changes:
- The target's
freezeres
- 30 is used instead of using thefreezeres
directly and it also allows anyfreezeres
of 30 or below to always pass the test - The
StatusBoost
medal decreases furtherfreezeres
by 5 instead of 15. This means that if it is equipped, the resistence used isfreezeres
- 35 instead offreezeres
- 15
- The target's
- The infliction doesn't require the target to not have the Sturdy condition, but it should be noted that this can't happen under normal gameplay
If all of the above conditions are met, the infliction occurs by doing the following:
- SetCondition called on target to inflict Freeze for 2 turns
- If target's
originalid
+ 1's endata'shasiceanim
is true, target'sinice
set to true - If target's actimmobile is false, its
cantmove
is set to 1 (needs one actor turn before being able to act again) - Freeze is called on the target
- If target's
frozenlastturn
is true, itsfreezeres
increments by 25. Otherwise, target'sfreezeres
increments by 13 (18 instead if on HardMode)
However, this logic differs from the one used in the damage pipeline in the following ways:
- The condition is inflicted for 2 turns instead of 1
- The condition is added immediately instead of being a delayed condition. This only has a visual difference: the
Prefabs/Particles/Snowflakes
that normally appears won't appear - The target's
inice
being set to true condition does not account for being at theGiantLairFridgeInside
map or in any maps outside of theGiantLair
area. Additionally, it doesn't reset the target's weakness to only containHornExtraDamage
if the conditions are fufilled - The damage pipeline logic has no requirements regarding
actimmobile
being false to setcantmove
to 1. This shouldn't affect anything in practice because other parts of the battle system allows to bypass inaction viaactimmobile
- The
freezeres
increase match with the exception that it lacks an increase by 70 that the damage pipeline logic can do. It would have done so if target'soriginalid
+ 1's endata'shasiceanim
is true while being at theGiantLairFridgeInside
map or in any maps outside of theGiantLair
area - If the target had a Topple condition, it is not removed unlike the damage pipeline logic
- If the target had a Sleep condition, it is not removed if 0 damage is dealt while it normally would be in the damage pipeline logic. It is removed otherwise by DoDamage as it usually does. Unintuitively, because the damage pipeline logic was incorrect, this ends up workarounding the issue because it allows DoDamage to enforce the correct waking up logic
- The damage pipeline logic normally includes a Drop of the target if its position is
Ground
while having aheight
above 0.05. While this action doesn't feature this in the freeze infliction logic, a variation of it is included after meaning it applies regardless if the infliction happened or not. The only meaningful difference (as this action is assumed to not be possible onFlying
enemy party members) is theheight
requirements for the drop is being above 0.1 instead of 0.05. This shouldn't affect anything under normal gameplay
Logic sequence¶
- If in
demomode
, CreateHelpBox is called with id 2 - Camera is zoomed in at 0.01 speed from the midpoint between
Moth
and targetentity IceMothThrow
sound playsMoth
animstate set to 108- A
Prefabs/AnimSpecific/mothbattlesphere
is instantiated a bit up-left fromMoth
position with 90.0 degress rotatex in x with aPrefabs/Objects/SingleSphere
as child at half transparency. Themothbattlesphere
will be destroyed in 2.0 seconds - DoCommand 1 happens
- Yield until DoCommand is done
- Camera is reset to default at 0.3 speed
- A
Prefabs/Particles/mothicenormal
appears slighly up from targetentity with x rotation of -90.0 and destroyed in 2.0 seconds Prefabs/Objects/icepillar
appears at targetentity with x rotation of -90.0, a DialogueAnim with x/y targetscale of 0.5- If
commandsuccess
is true (action command succeeded):Moth
animstate set to 111IceMothHit
sound playsicepillar
's DialogueAnim targetscale is set to half of the target'ssize
- target animstate set to 11 (
Hurt
) and notdigging
- target's position is set to
Ground
- 0.5 seconds yield
Moth
animstate set to 105icepillar
gets childed to the target'ssprite
- Target has LockRigid(true) called
- Over the course of 15.0 frames, the target is lifted up in y to 1.5 * (1 - target's weight / 100.0 clamped from 0.0 to 1.0) and while this happens, the target's y
spin
is continuously incremented every frame by 10.0 * (1 - target's weight / 100.0) * the ratio of the 15.0 progression Moth
animstate set to 102- DoCommand 2 call happens
- Frame yield
- Yield until
doingaction
is false Moth
animstate is set to 116- Frame yield
- DoDamage 1_a call happens
- The custom freeze infliction logic mentioned above is performed
icepillar
destroyed- ShakeScreen called with ammount of (0.1, 0.1, 0.1) and time of 0.1
IceShatter
particles played withIceBreak
sound at slightly above the target- 0.5 seconds yield
- target
spin
zeroed out - Over the course of 10.0 frames, the target is moved back to its original position
- StopAllCoroutine on the target's
battleentity
Moth
animstate set to 118- 0.5 seconds yield
- LockRigid(false) called on the target
- target's
basestate
restored to what it was before - If target's
height
is above 0.1 while its cantfall is false, target'sdroproutine
is set to a new Drop call followed by its position set toGround
- target's
onground
set to false
- Otherwise (action command failed):
icepillar
's DialogueAnim targetscale is set to (0.4, 0.4, 0.5)Moth
animstate set to 109IceMothMiss
sound plays- DoDamage 1_b happens
- 1.2 seconds yield
- A
Prefabs/Particles/IceShatter
appears slighly up fromMoth
with x rotation of -90.0 and destroyed in 1.0 seconds Moth
animstate set to 0 (Idle
)
- If
Prefabs/Objects/icepillar
still exists, its DialogueAnim is set to shrink at 0.05 speed