@@ -15,6 +15,7 @@ import funkin.play.GameOverSubState;
15
15
import funkin.play.PauseSubState;
16
16
import funkin.play.PlayState;
17
17
import funkin.util.Constants;
18
+ import funkin.util.HapticUtil;
18
19
import funkin.Preferences;
19
20
20
21
class PicoPlayerCharacter extends MultiSparrowCharacter
@@ -232,8 +233,13 @@ class PicoPlayerCharacter extends MultiSparrowCharacter
232
233
// Move the camera up.
233
234
GameOverSubState.instance.cameraFollowPoint.y -= 100;
234
235
235
- // Indicates that it is a special game over animation. Used for haptics.
236
- GameOverSubState.instance.isSpecialAnimation = true;
236
+ HapticUtil.vibrate(0, 0.5);
237
+
238
+ // Death by Darnell's can.
239
+ new FlxTimer().start(1.85, function(tmr:FlxTimer) {
240
+ // Pico falls on his knees.
241
+ HapticUtil.vibrate(0, 0.1, 0.1, 1);
242
+ });
237
243
238
244
var picoDeathExplosionPath = Paths.animateAtlas("characters/picoExplosionDeath", "weekend1");
239
245
picoDeathExplosion = new FlxAtlasSprite(this.x - 640, this.y - 340, picoDeathExplosionPath);
@@ -331,6 +337,23 @@ class PicoPlayerCharacter extends MultiSparrowCharacter
331
337
{
332
338
createCasing();
333
339
}
340
+
341
+ if (!HapticUtil.hapticsAvailable || picoDeathExplosion != null) return;
342
+
343
+ // Pico falls on his back.
344
+ if (name == 'firstDeath' && frameNumber == 20)
345
+ {
346
+ HapticUtil.vibrate(0, 0.1, 0.1, 1);
347
+ }
348
+
349
+ // Blood firework woohoo!!!!
350
+ if (name == 'deathLoop' && frameNumber % 2 == 0)
351
+ {
352
+ final randomAmplitude:Float = FlxG.random.float(0.1, 0.5);
353
+ final randomDuration:Float = FlxG.random.float(0.1, 0.3);
354
+
355
+ HapticUtil.vibrate(0, randomDuration, randomAmplitude);
356
+ }
334
357
}
335
358
336
359
var casingGroup:FlxTypedSpriteGroup;
0 commit comments