public override void onPickUp(Character c, float duration) { base.onPickUp(c, duration); if (defaultStrategy == null) { defaultStrategy = c.jumpStrategy; } c.jumpStrategy = new DoubleJump(); if (c is Player p) { p.addItem = this; } }
public OffsetJumper(int[] offsets, IJumpStrategy strategy) { _offsets = offsets; _strategy = strategy; }