import sys; sys.path.insert(0, '../../b5tools'); from rec import upsert; from snd import snd FIRE = {"anm2": "gfx/projectiles/fire/fire.anm2", "animation": "Flickering"} IDLE = {"poses": ["IdleRight", "IdleRight", "IdleDown", "IdleUp"]} # Mirrored leftward, as RunHori. attacks = [ # Attack1 (state 8): a bomb thrown at Isaac (two from Attack1Double). {"animation": "Attack1Right", "period": 1, "one_in": 50, "range": 300, "release": "Shoot", "bombs": 1, "bomb_at": "player", "directional_poses": ["Attack1Left", "Attack1Right", "Attack1Right", "Attack1Right"], "sounds": [snd(0xc9, "Sound"), snd(0x19, "Shoot")], "cooldown": 40}, {"animation": "Attack1Double", "period": 1, "one_in": 90, "release": "Shoot", "bombs": 1, "bomb_at": "player", "bomb_scatter": 40, "sounds": [snd(0xc9, "Sound"), snd(0x19, "Shoot")], "cooldown": 40}, # Attack2 (state 9): mines dropped about the room. {"animation": "Attack2", "period": 1, "one_in": 120, "release": "Shoot", "bombs": 3, "bomb_scatter": 120, "sounds": [snd(0x19, "Shoot")], "cooldown": 40}, # The sprint's end (state 11): a fire lob at Isaac. {"animation": "ChargeFinish", "period": 1, "one_in": 150, "release": "Shoot", "shots": [{"shot": "boss_volley", "count": 1, "speed": 10, "scale": 1.5, "fall_velocity": -10, "fall_acceleration": 0.5, "look": FIRE}], "sounds": [snd(0x130, "Sound")], "cooldown": 40}, # Taunt. {"animation": "Taunt", "period": 1, "one_in": 200, "sounds": [snd(0xfc, "Sound")]}, ] # Its cart (965.1, its own sheet): 45 ticks in the wall's tunnel each time it runs off the floor (states 6/7). upsert({"key": "hornfel_minecart", "name": "Hornfel's Minecart", "flash_id": 96500100, "hp": 10, "mass": 10000, "radius": 13, "contact_damage": 0, "door_lock": "never", "contact_attack_target": False, "initially_invulnerable": True, "grid_collision": False, "enemy_contact_group": "player_only", "boss_bar": {"eligibility": "never"}, "gibs": {"count": 0}, "death_burst": {"sounds": ["rebirth/wood_plankbreaks0.mp3", "rebirth/wood_plankbreaks1.mp3", "rebirth/wood_plankbreaks2.mp3"]}, "behavior": {"kind": "scripted", "move": "rail", "speed": 1.2, "retention": 0.8, "mirrored": False, "idle_pose": "Move1", "facing": {"turns": ["Move1", "Move2", "Move3", "Move4", "Move5", "Move6", "Move7", "Move8"]}, "rail": {"rider_offset": [0, -7], "rider_layers": ["back", "front"], "tunnel": 45}}, "art": "gfx/bosses/hornfel/hornfel_minecart.anm2"}) upsert({"key": "hornfel_decoy", "name": "Hornfel Decoy", "flash_id": 90600100, "hp": 4, "mass": 20, "radius": 20, "contact_damage": 1, "door_lock": "never", "boss_bar": {"eligibility": "never"}, "gibs": {"count": 0}, "death_explosion": {"variants": [1], "player_damage": 1}, "behavior": {"kind": "scripted", "move": "still", "idle_pose": "DecoyIdle"}, "art": "gfx/bosses/hornfel/hornfel.anm2"}) # Rides his cart from the tunnel (240 health), with two Fly Bombs 1 in 3 and decoys on two other tracks 1 in 8 as it # comes out; at 100 left he falls off (Sad) and runs for the nearest rail door at 1.08, half a heart by touch. upsert({"key": "hornfel", "name": "Hornfel", "flash_id": 90600000, "hp": 340, "mass": 20, "radius": 20, "contact_damage": 1, "gibs": {"large": True}, "grid_collision": False, "behavior": {"kind": "scripted", "move": "still", "retention": 0.8, "idle_pose": "IdleDown", "facing": IDLE, "cart": {"type": "hornfel_minecart", "enter_spawns": [{"type": "fly_bomb", "count": 2, "one_in": 3}, {"type": "hornfel_decoy", "count": 2, "one_in": 8, "carted": True}], "knock_off": 100, "knock_off_damage": 0.5, "speed": 1.08, "pose": "Sad", "facing": ["RunHori", "RunHori", "RunDown", "RunUp"]}, "attacks": attacks}, "death": {"animation": "Sad"}, "death_burst": {"boss_sounds": ["rocket_blast_death_1.mp3"]}, "art": "gfx/bosses/hornfel/hornfel.anm2"})