<?xml version="1.0" encoding="utf-8"?>
<ActorDefinitions>
	<!--
	Note about RenderPriority:
	 * 200 is tile damage.
	 * 1000 is default for GameObjects.
	 * 2000 is default for EffectObjects.
	 * If you go high enough over this, you reach decals/sprites in free layers placed in front of main tile layer, but you have up towards 65000 before that.
	 * Small negative values will be decals/sprites in main tile layer.
	 * -1000 is the tilemap in the main layer.
	 * Values below -65536 is decals/sprites in free layers beneath the main tile layer.
	 * Before priority is taken into account, z depth is compared, so this is only relevant for things with 0 depth.
	 * When objects have the same priority, they are first sorted by basic type (tilemap first, then decals, then sprites), then they're sorted by sprite set used,
	   and then simply by order of render request. Neither of the last two is deterministic across runs, so use priorities when it really matters (but don't when 
	   it doesn't, since this will result in faster rendering).
	-->

	<!-- Templates -->
	<Actor>
		<Name>ACTOR</Name>
		
		<CollideAgainst>tiles;hard_enemies;rocks;pools;beams</CollideAgainst>
	</Actor>
	<Actor>
		<Name>FALLBLOCK</Name>
		<SpecialType>fallblock</SpecialType>
		<Template>ACTOR</Template>
		
		<CollisionGroup>rocks</CollisionGroup>
		<CollideAgainst>tiles;hard_enemies;rocks;support;player;enemies;items;transport;lamps;ladders;beams</CollideAgainst>
		<RoundPosition>1</RoundPosition>
		<Persistent>1</Persistent>
		<CanSleep>1</CanSleep>
		<ForceUpdateIfAwake>1</ForceUpdateIfAwake>
		<GravityFactor>0.7</GravityFactor>
		<!--<HitPoints>6</HitPoints>
		<Hardness>4</Hardness>-->
		<Invulnerable>1</Invulnerable>
		<KnockbackSensitivity>0</KnockbackSensitivity>		
		<Behavior>Fallblock</Behavior>
		<DamageCrush Amount="1" Type="crush"/>
		<FallDamage Distance="1" Sound="fallblock_land"/>
		<EndEffect>fallblock_destroyed</EndEffect>
		<FallTileDamageLinear>1</FallTileDamageLinear>
		<WakeNeighboursOnDeath>1</WakeNeighboursOnDeath>
		<WakeNeighboursOnMove>1</WakeNeighboursOnMove>
		<RumbleSound>fallblock_rumble</RumbleSound>
		<WalkOnSound>player_walk_dirt</WalkOnSound>
	</Actor>
	<Actor>
		<Name>POOL</Name>
		<SpecialType>pool</SpecialType>
		<RenderPriority>1100</RenderPriority>
		<CollisionGroup>pools</CollisionGroup>
		<CollisionSensor>0</CollisionSensor>
		<Persistent>1</Persistent>
		<UpdatePhysics>false</UpdatePhysics>
		<Behavior>Pool</Behavior>
	</Actor>
	<Actor>
		<Name>NPC</Name>
		<Template>ACTOR</Template>
		<RenderPriority>900</RenderPriority>
		<Behavior>NPC</Behavior>
		<Animation>Basic</Animation>
		<Light Sprite="blob" Scale="1.5" Offset="0,-18" Color="0.6,0.6,0.6"/>
		<Sprite RoundPosition="true"/>
		
		<CollisionGroup>npcs</CollisionGroup>
		<CollisionBox>-18;-36;36;36</CollisionBox>
		<WalkSpeed>60</WalkSpeed>
	</Actor>
	
	<!-- Friends -->
	<Actor>
		<Name>player</Name>
		<Template>ACTOR</Template>
		
		<Sprite>Sprites/char-rusty;char_rusty</Sprite>
		<RenderPriority>1050</RenderPriority>
		<CollisionBox>-9;-20;18;20</CollisionBox> <!-- Slightly less than half a tile to avoid getting stuck between other half-tiles -->
		<CollisionGroup>player</CollisionGroup>
		<CollideAgainst>tiles;hard_enemies;rocks;bounds;pools;ladders;boss;beams</CollideAgainst>
		<AllyGroup>player</AllyGroup>
		<CheckOnGround>1</CheckOnGround>
		<GroundFriction>0.3</GroundFriction>
		<WallFriction>0.04</WallFriction>
		<LinearAirResistance>0</LinearAirResistance>
		<QuadraticAirResistance>0</QuadraticAirResistance>
		<HighQualityIntegration>1</HighQualityIntegration>
		<LandSoft Speed="50" Sound="player_land_soft_dirt"/>
		<HeadBumpSound>player_headbump_dirt</HeadBumpSound>
		<HeadBumpDamage>1</HeadBumpDamage>
		<Light Sprite="blob" Scale="3.00" Offset="0,-16" Color="1,1,1"/>
		
		<SpecialType>player</SpecialType>
		<HitPoints>2</HitPoints>
		<Water>0</Water>
		<LightTime>180</LightTime>
		<LightWarningThreshold>0.2</LightWarningThreshold>
		<LightDepletedFrequency>30</LightDepletedFrequency>
		<WalkSpeed>150</WalkSpeed>
		<WalkAcceleration>1000</WalkAcceleration>
		<RunningEffect Offset="0,0" Frequency="0.04">fart_lines</RunningEffect>
		<SteamJumpEffect>steam_jump</SteamJumpEffect>
		<SteamJumpTrailEffect RandomOffset="10,0" Frequency="0.05">steam_jump_trail</SteamJumpTrailEffect>
		<Animation>PlayerBody</Animation>
		<AnimationState>body</AnimationState>
		<JumpSpeed>270</JumpSpeed> <!-- Was: 330-->
		<FallDamage Distance="260" MinDmg="0.5" LinearDmg="0.08333" Sound="player_land_hard_dirt" CriticalSound="player_land_critical_dirt"/>
		<FallTileDamageConstant>1</FallTileDamageConstant>
		<AttackedSound>player_hurt</AttackedSound>
		<EndSound>player_die</EndSound>
		<CrushedSound>fallblock_crush_player</CrushedSound>
		<DrainWaterEffect>waterbubbles</DrainWaterEffect>
		<ActivatesBarrels>1</ActivatesBarrels>
		<DoubleJumpWaterDrain>1</DoubleJumpWaterDrain>
		<StaticDashVelocity>350</StaticDashVelocity>		
		<SlideEffect>slide_trail</SlideEffect>
		<SlideEffectFrequency>0.1</SlideEffectFrequency>
		<SlideEffectRandomOffset>4,4</SlideEffectRandomOffset>
		<SlideSound>player_slide_dirt</SlideSound>
		<LadderSound>player_climb_ladder</LadderSound>

		<ProjectileSpawnOffset>0,-3</ProjectileSpawnOffset>
		<Weapons>
			<Weapon>
				<IdleAnimation>hand</IdleAnimation>
				<Name>None</Name>
			</Weapon>
			<Weapon>
				<AttackType>player</AttackType>
				<AttackDamage Amount="1" Tier="1"/>
				<AnimationInput>attack_axe</AnimationInput>
				<IdleAnimation>pickaxe</IdleAnimation>
				<Name>Pickaxe</Name>
				<RequireUpgrade>pickaxe</RequireUpgrade>
				<AttackOnGround>1</AttackOnGround>
				<AttackTime>0.14</AttackTime>
				<AttackCooldown>0.27</AttackCooldown>
				<AttackEffectMiss Offset="38,20">hit_distance</AttackEffectMiss>
				<AttackSoundMiss>player_attack_pick</AttackSoundMiss>
				<AttackSoundInvulnerable>player_attack_pick_invulnerable</AttackSoundInvulnerable>
				<AttackEffectInvulnerable>spark_hit</AttackEffectInvulnerable>
				<IconSprite>gear_pickaxe</IconSprite>
			</Weapon>
			<Weapon>
				<AttackType>player</AttackType>
				<AttackDamage Amount="1" Tier="3" TileReduction="8" EnemyReduction="1" EnemyAmount="0.2" />
				<AnimationInput>attack_drill</AnimationInput>
				<IdleAnimation>drill</IdleAnimation>
				<Name>Drill</Name>
				<RequireUpgrade>drill</RequireUpgrade>
				<WaterDrain>0.01</WaterDrain>
				<MinWater>0.01</MinWater>
				<AttackOnGround>1</AttackOnGround>
				<AttackTime>0.2</AttackTime>
				<AttackCooldown>0.25</AttackCooldown>
				<AttackRepeatTime>0.1</AttackRepeatTime>
				<AttackPitchTime>0.5</AttackPitchTime>
				<AttackSoundConstant>player_attack_drill</AttackSoundConstant>
				<AttackSoundInvulnerable>player_attack_drill_invulnerable</AttackSoundInvulnerable>
				<AttackEffectInvulnerable>spark_hit</AttackEffectInvulnerable>
				<IconSprite>gear_drill</IconSprite>
			</Weapon>
			<Weapon>
				<AttackType>projectile</AttackType>
				<AttackDamage Amount="1" Tier="2" TileReduction="17" EnemyReduction="1" Filter="contact"/>
				<ChargeDamage Amount="4" Tier="0" KnockbackMultiplier="1"/>
				<ProjectileName>steam_blast</ProjectileName>
				<Trajectory Angle="0" AngleVariance="0" Force="450" ForceVariance="0"/>
				<AnimationInput>attack_punch</AnimationInput>
				<IdleAnimation>steampunch</IdleAnimation>
				<Name>Steam Punch</Name>
				<RequireUpgrade>punch</RequireUpgrade>
				<AttackOnGround>true</AttackOnGround>
				<AttackChargeTime>1.1</AttackChargeTime>
				<AttackPitchTime>1.1</AttackPitchTime>
				<WaterDrain>0.25</WaterDrain>
				<MinWater>0.01</MinWater>
				<AttackCooldown>0.5</AttackCooldown>
				<AttackSoundHit>player_attack_punch</AttackSoundHit>
				<AttackSoundMiss>player_attack_punch</AttackSoundMiss>
				<AttackSoundCharged>player_attack_punch_charged</AttackSoundCharged>
				<AttackSoundCharging>player_attack_punch_charging</AttackSoundCharging>
				<AttackEffectInvulnerable>spark_hit</AttackEffectInvulnerable>
				<AttackEffect Offset="0,0" ChargeScale="true">steam_jump</AttackEffect>
				<ChargeLight Sprite="blob" Scale="0.5" Offset="-9,-11" Color="1,0.9,0.5"/>
				<IconSprite>gear_punch</IconSprite>
			</Weapon>
		</Weapons>
		<Tools>
			<Tool>
				<!-- todo icon probably -->
			</Tool>
			<Tool>
				<Name>Ladder</Name>
				<RequireUpgrade></RequireUpgrade>
				<CountUpgrade>ladder</CountUpgrade>
				<IconSprite>gear_ladder</IconSprite>
				<UseSound>deploy_item</UseSound>
				<IsBuilding>true</IsBuilding>
			</Tool>
			<Tool>
				<Name>Lamp</Name>
				<RequireUpgrade></RequireUpgrade>
				<CountUpgrade>lamp</CountUpgrade>
				<IconSprite>gear_lamp</IconSprite>
				<UseSound>deploy_item</UseSound>
				<IsBuilding>true</IsBuilding>
			</Tool>
			<Tool>
				<Name>Teleporter</Name>
				<RequireUpgrade></RequireUpgrade>
				<CountUpgrade>teleporter</CountUpgrade>
				<IconSprite>gear_teleporter</IconSprite>
				<UseSound>deploy_item</UseSound>
				<IsBuilding>true</IsBuilding>
			</Tool>
			<Tool>
				<Name>Dynamite</Name>
				<RequireUpgrade>enable_dynamite</RequireUpgrade>
				<CountUpgrade>dynamite</CountUpgrade>
				<IconSprite>gear_dynamite</IconSprite><!--todo-->
				<UseSound>enemy_shiner_attack</UseSound>
			</Tool>
		</Tools>
	</Actor>
	
	<Actor>
		<Name>char_dorothy</Name>
		<Template>NPC</Template>

		<Sprite>Sprites/chars-tumbleton;char_dorothy</Sprite>
		<WalkSpeed>80</WalkSpeed>
	</Actor>
	
	<Actor>
		<Name>char_cranky</Name>
		<Template>NPC</Template>

		<Sprite>Sprites/chars-tumbleton;char_cranky</Sprite>
	</Actor>
	
	<Actor>
		<Name>char_shopkeeper_1</Name>
		<Template>NPC</Template>

		<Sprite>Sprites/chars-tumbleton;char_texan</Sprite>
		<FirstConversation>Biff_fallback</FirstConversation>
	</Actor>
	
	<Actor>
		<Name>char_shopkeeper_2</Name>
		<Template>NPC</Template>

		<Sprite>Sprites/chars-tumbleton;char_aceman</Sprite>
		<FirstConversation>Dandy_fallback</FirstConversation>
	</Actor>

	<Actor>
		<Name>char_barmaid</Name>
		<Template>NPC</Template>

		<Sprite>Sprites/chars-tumbleton;char_barlady</Sprite>
	</Actor>
	
	<Actor>
		<Name>char_hola</Name>
		<Template>NPC</Template>

		<Sprite>Sprites/chars-tumbleton;hola_idle01</Sprite>
		<Behavior>Hola</Behavior>
	</Actor>
	
	<!-- Script entities -->
	<Actor>
		<Name>player_proxy</Name>
		<SpecialType>player_proxy</SpecialType>
		<UpdatePhysics>false</UpdatePhysics>
	</Actor>
	
	<Actor>
		<Name>dead_miner</Name>
		<Sprite>Sprites/environment-tutorial;dead_miner</Sprite>
		<RenderPriority>900</RenderPriority>
		<CollisionGroup>wall_enemies</CollisionGroup>
		<CollisionBox>-20;-20;40;40</CollisionBox>
		<UpdatePhysics>false</UpdatePhysics>
	</Actor>
			
	<Actor>
		<Name>door_1x1</Name>
		<Sprite>Sprites/environment-tutorial;door01</Sprite>
		<RenderPriority>900</RenderPriority>
		<CollisionGroup>hard_enemies</CollisionGroup>
		<CollisionBox>-12;-20;24;40</CollisionBox>
		<UpdatePhysics>false</UpdatePhysics>
		<Invulnerable>1</Invulnerable>
		<Light Sprite="blob" Scale="1.5" Offset="0,-18" Color="0.6,0.6,0.6"/>
	</Actor>
	
	<Actor>
		<Name>button</Name>
		<Sprite>Sprites/environment-tutorial;leaver01</Sprite>
		<RenderPriority>1100</RenderPriority>
		<CollisionGroup>wall_enemies</CollisionGroup>
		<CollisionBox>-20;-20;40;40</CollisionBox>
		<UpdatePhysics>false</UpdatePhysics>
	</Actor>
	
	<Actor>
		<Name>pneumatic_tube</Name>
		<Sprite>Sprites/environment-general;pneumatic_tube</Sprite>
		<RenderPriority>-1001</RenderPriority>
		<CollisionGroup>wall_enemies</CollisionGroup>
		<CollisionBox>-20;-20;40;40</CollisionBox>
		<UpdatePhysics>false</UpdatePhysics>
	</Actor>
	
	<Actor>
		<Name>pneumatic_tube_tumbleton</Name>
		<Sprite>Sprites/environment-tumbleton;pneumatic_tube</Sprite>
		<RenderPriority>900</RenderPriority>
		<CollisionGroup>wall_enemies</CollisionGroup>
		<CollisionBox>-20;-20;40;40</CollisionBox>
		<UpdatePhysics>false</UpdatePhysics>
	</Actor>
	
	<Actor>
		<Name>shop_upgrades_2</Name>
		<Sprite PlayAll="true">Sprites/environment-tumbleton;building_upgrades2</Sprite>
		<RenderPriority>800</RenderPriority>
		<CollisionGroup>wall_enemies</CollisionGroup>
		<CollisionBox>-134;-184;283;186</CollisionBox>
		<UpdatePhysics>false</UpdatePhysics>
	</Actor>
	
	<Actor>
		<Name>shop_upgrades_3</Name>
		<Sprite PlayAll="true">Sprites/environment-tumbleton;building_upgrades3</Sprite>
		<RenderPriority>800</RenderPriority>
		<CollisionGroup>wall_enemies</CollisionGroup>
		<CollisionBox>-127;-252;276;262</CollisionBox>
		<UpdatePhysics>false</UpdatePhysics>
	</Actor>
	
	<Actor>	
		<Name>upgrade_podium</Name>

		<Sprite>Sprites/environment-general;upgrade_podium</Sprite>
		<RenderPriority>800</RenderPriority>
		<CollisionBox>-2;-8;4;8</CollisionBox>
		<CollisionGroup>items</CollisionGroup>
		<UpdatePhysics>false</UpdatePhysics>
		
		<ResetWithEarth>0</ResetWithEarth>
		<Behavior>UpgradePodium</Behavior>
		<Animation>UpgradePodium</Animation>
	</Actor>

	<Actor>
		<Name>TELEPORTER</Name>
		<MapIcon>teleporter_map</MapIcon>
		<SpecialType>teleporter</SpecialType>

		<RenderPriority>800</RenderPriority>
		<CollisionBox>-15;-30;30;30</CollisionBox>
		<CollisionGroup>lamps</CollisionGroup>
		<UpdatePhysics>false</UpdatePhysics>

		<Behavior>Teleporter</Behavior>
		<Animation>Teleporter</Animation>
		<EndEffect>explosion_egg_tiny</EndEffect>
		<AttachedDirection>0,1</AttachedDirection>
	</Actor>

	<Actor>
		<Name>teleporter</Name>
		<Template>TELEPORTER</Template>
		
		<Sprite PlayAll="true">Sprites/environment-general;teleporter_base</Sprite>
		<Light Sprite="upbeamish" Scale="2.5" Offset="0,0" Color="0,0,1"/>
		<Persistent>1</Persistent>
		<MaxCountGroup>buildings</MaxCountGroup>
	</Actor>
	
	<Actor>
		<Name>town_teleporter</Name>
		<Template>TELEPORTER</Template>

		<Sprite PlayAll="true">Sprites/environment-general;teleporter_base2</Sprite>
		<Behavior>TownTeleporter</Behavior>
	</Actor>

	<!-- Buildings -->
	<Actor>
		<Name>ladder</Name>
		<SpecialType>ladder</SpecialType>
		
		<Sprite>Sprites/environment-general;ladder</Sprite>
		<RenderPriority>950</RenderPriority>
		<CollisionBox>-10;-40;20;40</CollisionBox>
		<CollisionGroup>ladders</CollisionGroup>
		<CollideAgainst>tiles;hard_enemies;rocks;ladders;beams</CollideAgainst>
		<RoundPosition>1</RoundPosition>
		<LandSoft Speed="50" Sound="fallblock_land"/>
		<Persistent>1</Persistent>
		<CanSleep>1</CanSleep>
		<ForceUpdateIfAwake>1</ForceUpdateIfAwake>
		<PlatformCollision>1</PlatformCollision>
		<HitPoints>1</HitPoints>
		<!-- <Invulnerable>1</Invulnerable> -->
		
		<Behavior>Ladder</Behavior>
		<WakeNeighboursOnDeath>1</WakeNeighboursOnDeath>
		<WakeNeighboursOnMove>1</WakeNeighboursOnMove>
		<MaxCountGroup>buildings</MaxCountGroup>
		<AttackedEffect>wood_hit</AttackedEffect>
		<EndSound>player_attack_barrel</EndSound>
		<EndEffect>woodblock_destroyed</EndEffect>
		<EndEffectOffset>0,-20</EndEffectOffset>
	</Actor>
	
	<!-- General -->
	<Actor>
		<Name>enemy_fallblock</Name>
		<Template>FALLBLOCK</Template>
		
		<Sprite>Sprites/enemies-general;enemy_stone_01</Sprite>
		<CollisionBox>-20;-20;40;40</CollisionBox>
	</Actor>
	<Actor>
		<Name>enemy_fallblock_2x2</Name>
		<Template>FALLBLOCK</Template>
		
		<Sprite>Sprites/enemies-general;enemy_fallblock_2x2</Sprite>
		<CollisionBox>-40;-40;80;80</CollisionBox>
	</Actor>
		
	<Actor>
		<Name>enemy_fallblock_oldworld</Name>
		<Template>FALLBLOCK</Template>
		
		<Sprite>Sprites/enemies-oldworld;oldworld_fallblock01</Sprite>
		<CollisionBox>-20;-20;40;40</CollisionBox>
	</Actor>
	<Actor>
		<Name>enemy_fallblock_oldworld_2x2</Name>
		<Template>FALLBLOCK</Template>
		
		<Sprite>Sprites/enemies-oldworld;oldworld_fallblock2x2</Sprite>
		<CollisionBox>-40;-40;80;80</CollisionBox>
	</Actor>
		
	<Actor>
		<Name>DOUCHEBLOCK</Name>
		<Template>FALLBLOCK</Template>
		
		<CanRotate>true</CanRotate>
 		<Behavior>Doucheblock</Behavior>
		<Animation>Doucheblock</Animation>
		<GravityFromRotation>1</GravityFromRotation>
		<RumbleSound>doucheblock_rumble</RumbleSound>
	</Actor>	
	<Actor>
		<Name>enemy_doucheblock</Name>
		<Template>DOUCHEBLOCK</Template>
		
		<Sprite PlayAll="true">Sprites/enemies-vectron;doucheblock</Sprite>
		<CollisionBox>-20;-20;40;40</CollisionBox>
	</Actor>
	<Actor>
		<Name>enemy_doucheblock_2x2</Name>
		<Template>DOUCHEBLOCK</Template>
		
		<Sprite PlayAll="true">Sprites/enemies-vectron;doucheblockbig</Sprite>
		<CollisionBox>-40;-40;80;80</CollisionBox>
	</Actor>
	
	<Actor>
		<Name>enemy_woodblock</Name>
		<SpecialType>fallblock</SpecialType>
		<Template>ACTOR</Template>
		
		<Sprite>Sprites/enemies-general;enemy_woodblock01</Sprite>
		<CollisionBox>-20;-20;40;40</CollisionBox>
		
		<CollisionGroup>rocks</CollisionGroup>
		<CollideAgainst>tiles;hard_enemies;rocks;support;player;enemies;items;transport;lamps;ladders;beams</CollideAgainst>
		<RoundPosition>1</RoundPosition>
		<LandSoft Speed="50" Sound="fallblock_land"/>
		<Persistent>1</Persistent>
		<CanSleep>1</CanSleep>
		<ForceUpdateIfAwake>1</ForceUpdateIfAwake>
		<KnockbackSensitivity>0</KnockbackSensitivity>
		<GravityFactor>0.7</GravityFactor>
		<HitPoints>3</HitPoints>
		<Hardness>2</Hardness>
		<Behavior></Behavior>
		<DamageCrush Amount="0.5" Type="wood_crush"/>
		<FallDamage Distance="1"/>
		<WakeNeighboursOnDeath>1</WakeNeighboursOnDeath>
		<WakeNeighboursOnMove>1</WakeNeighboursOnMove>
		<AttackedSound>player_attack_barrel</AttackedSound>
		<AttackedEffect>wood_hit</AttackedEffect>
		<EndSound>player_attack_barrel</EndSound>
		<EndEffect>woodblock_destroyed</EndEffect>
		<WalkOnSound>player_walk_dirt</WalkOnSound>
	</Actor>
	<Actor>
		<Name>enemy_support</Name>
		<SpecialType>fallblock</SpecialType>
		<Template>ACTOR</Template>
		
		<Sprite>Sprites/enemies-general;enemy_support</Sprite>
		<CollisionBox>-20;-20;40;40</CollisionBox>
		
		<CollisionGroup>support</CollisionGroup>
		<CollideAgainst>tiles;hard_enemies;rocks;support</CollideAgainst>
		<KnockbackSensitivity>0</KnockbackSensitivity>
		<RoundPosition>1</RoundPosition>
		<LandSoft Speed="50" Sound="fallblock_land"/>
		<Persistent>1</Persistent>
		<CanSleep>1</CanSleep>
		<ForceUpdateIfAwake>1</ForceUpdateIfAwake>
		<GravityFactor>0.7</GravityFactor>
		<Behavior></Behavior>
		<WakeNeighboursOnMove>1</WakeNeighboursOnMove>
		<Invulnerable>1</Invulnerable>
	</Actor>
	<Actor>
		<Name>enemy_acidblock</Name>
		<Template>ACTOR</Template>
		
		<CollisionGroup>wall_enemies</CollisionGroup>
		<UpdatePhysics>false</UpdatePhysics>
		<Light Sprite="blob" Scale="0.5" Offset="0,0" Color="0.5,1,0.5"/>

		<Persistent>1</Persistent>
		<HeartBeatTime>2</HeartBeatTime>
		<HeartBeatRandomTime>0</HeartBeatRandomTime>
		<Behavior>Acidblock</Behavior>
		<Weapons>
			<Weapon>
				<AttackType>projectile</AttackType>
				<!--<AttackSound>enemy_acid_drop</AttackSound>-->
				<ProjectileName>acid_drop</ProjectileName>
				<AttackEffect>acid_leak</AttackEffect>
			</Weapon>
		</Weapons>
		<ProjectileSpawnOffset>0,25</ProjectileSpawnOffset>
	</Actor>
	<Actor>
		<Name>pool_1x1</Name>
		<Template>POOL</Template>
		
		<Sprite PlayAll="true">Sprites/enemies-general;pool</Sprite>
		<CollisionBox>-20;-18;40;38</CollisionBox>
		<Water>2</Water>
	</Actor>
	<Actor>
		<Name>pool_3x1</Name>
		<Template>POOL</Template>
		
		<Sprite PlayAll="true">Sprites/enemies-general;pool-x3</Sprite>
		<CollisionBox>-60;-18;120;38</CollisionBox>
		<Water>6</Water>
	</Actor>
	<Actor>
		<Name>pool_5x1</Name>
		<Template>POOL</Template>
		
		<Sprite PlayAll="true">Sprites/enemies-general;pool-x5</Sprite>
		<CollisionBox>-100;-18;200;38</CollisionBox>
		<Water>10</Water>
	</Actor>
	<Actor>
		<Name>ACID_POOL</Name>
		<Template>POOL</Template>
		<DamageAcid Amount="0.30" EnemyAmount="1.5" Tier="1" InvulnerabilityPlayerCooldown="0.50" InvulnerabilityEnemyCooldown="0.50" KnockbackMultiplier="0"/>
	</Actor>
	<Actor>
		<Name>pool_acid_1x1</Name>
		<Template>ACID_POOL</Template>
		
		<Sprite PlayAll="true">Sprites/enemies-general;acidpool</Sprite>
		<CollisionBox>-20;-18;40;38</CollisionBox>
		<Water>2</Water>
	</Actor>
	<Actor>
		<Name>pool_acid_3x1</Name>
		<Template>ACID_POOL</Template>
		
		<Sprite PlayAll="true">Sprites/enemies-general;acidpool-x3</Sprite>
		<CollisionBox>-60;-18;120;38</CollisionBox>
		<Water>6</Water>
	</Actor>
	<Actor>
		<Name>pool_acid_5x1</Name>
		<Template>ACID_POOL</Template>
		
		<Sprite PlayAll="true">Sprites/enemies-general;acidpool-x5</Sprite>
		<CollisionBox>-100;-18;200;38</CollisionBox>
		<Water>10</Water>
	</Actor>
	<Actor>
		<Name>LANTERN</Name>
		<Template>ACTOR</Template>
		<RenderPriority>900</RenderPriority>
		<CollisionGroup>lamps</CollisionGroup>
		<CollideAgainst>tiles</CollideAgainst>
		<SimpleAnimation>idle</SimpleAnimation>
		<CanSleep>1</CanSleep>
		<WeightPressure>0</WeightPressure>
		<UpdatePhysics>0</UpdatePhysics>
		<CollisionBox>-10;-40;20;40</CollisionBox>
		<Behavior>Lantern</Behavior>
		<Persistent>1</Persistent>
		<EndEffect>lantern_destroyed</EndEffect>
		<RejectSameTypeRadius>140</RejectSameTypeRadius>
		<AttachedDirection>0,1</AttachedDirection>
	</Actor>
	
	<Actor>
		<Name>entrance_ladder</Name>
		<Template>LANTERN</Template>
		
		<Light Sprite="entrance_light" Scale="2.0" Offset="0,-20" Color="1,1,1"/>
		<Sprite>Sprites/environment-general;entrance</Sprite>

		<Persistent>false</Persistent>
		<RejectSameTypeRadius>0</RejectSameTypeRadius>	
	</Actor>
	
	<Actor>
		<Name>lamp</Name>
		<Template>LANTERN</Template>
		
		<Light Sprite="lantern_yellow_animated" Scale="3.0" Offset="0,-20" Color="1,1,1"/>
		<Sprite PlayAll="true">Sprites/environment-general;lantern2</Sprite>

		<RejectSameTypeRadius>60</RejectSameTypeRadius>
		<MaxCountGroup>buildings</MaxCountGroup>
	</Actor>
		
	<Actor>
		<Name>standing_lantern</Name>
		<Template>LANTERN</Template>

		<Light Sprite="lantern_yellow_animated" Scale="2.0" Offset="0,-20" Color="1,1,1"/>
		<Sprite PlayAll="true">Sprites/environment-general;lantern2</Sprite>
		<EndEffectOffset>0,-20</EndEffectOffset>
	</Actor>
	<Actor>
		<Name>standing_lantern_green</Name>
		<Template>LANTERN</Template>
		
		<Light Sprite="lantern_yellow_animated" Scale="1.75" Offset="0,-20" Color="1,1,1"/>
		<Sprite PlayAll="true">Sprites/environment-general;lantern3</Sprite>
		<EndEffectOffset>0,-20</EndEffectOffset>
	</Actor>
	<Actor>
		<Name>standing_lantern_blue</Name>
		<Template>LANTERN</Template>
		
		<CanRotate>true</CanRotate>
		<RenderPriority>-1100</RenderPriority>
		<Light Sprite="lantern_blue_animated" Scale="1.5" Offset="0,-20" Color="0.6,0.85,1"/>
		<Sprite PlayAll="true">Sprites/environment-general;lantern4</Sprite>
		<EndEffectOffset>0,-20</EndEffectOffset>
		<RejectSameTypeRadius>42</RejectSameTypeRadius>
	</Actor>
	<Actor>
		<Name>hanging_lantern</Name>
		<Template>LANTERN</Template>

		<AttachedDirection>0,-1</AttachedDirection>
		<CollisionBox>-20;0;40;40</CollisionBox>
		<Light Sprite="lantern_yellow_animated" Scale="2.0" Offset="0,40" Color="1,1,1"/>
		<Sprite PlayAll="true">Sprites/environment-general;lantern1</Sprite>
		<EndEffectOffset>0,20</EndEffectOffset>
	</Actor>
	<Actor>
		<Name>hanging_lantern_green</Name>
		<Template>LANTERN</Template>
		<AttachedDirection>0,-1</AttachedDirection>
		<CollisionBox>-20;0;40;40</CollisionBox>
		<Light Sprite="lantern_green_animated" Scale="2.0" Offset="0,40" Color="1,1,1"/>
		<Sprite PlayAll="true">Sprites/environment-general;hanging_lantern_green</Sprite>
		<EndEffectOffset>0,20</EndEffectOffset>
	</Actor>
	<Actor>
		<Name>wall_light</Name>
		<Template>LANTERN</Template>
		<Sprite PlayAll="true">Sprites/environment-general;wall_lantern_yellow</Sprite>
		
		<AttachedDirection>-1,0</AttachedDirection>
		<AutoFacing>false</AutoFacing>
		<CollisionBox>-20;-20;40;40</CollisionBox>
		<Light Sprite="lantern_yellow_animated" Scale="2.00" Offset="0,0" Color="1.0,1.0,1.0"/>
	</Actor>
	<Actor>
		<Name>wall_light_green</Name>
		<Template>LANTERN</Template>
		<Sprite PlayAll="true">Sprites/environment-general;wall_lantern_green</Sprite>
		
		<AttachedDirection>-1,0</AttachedDirection>
		<AutoFacing>false</AutoFacing>
		<CollisionBox>-20;-20;40;40</CollisionBox>
		<Light Sprite="lantern_green_animated" Scale="2.0" Offset="0,0" Color="1,1,1"/>
	</Actor>
	
	<!-- Archaeans -->
	<Actor>
		<Name>TRILOBITE_WALL</Name>
		<Template>ACTOR</Template>
		
		<RenderPriority>300</RenderPriority>
		<CollisionBox>-8;-8;16;16</CollisionBox>
		<CollisionGroup>wall_enemies</CollisionGroup>
		<CollideAgainst>none</CollideAgainst>
		<Enemies>none</Enemies>
		<UpdatePhysics>false</UpdatePhysics>
		
		<Persistent>1</Persistent>
		<Invulnerable>1</Invulnerable>
		<SimpleAnimation>idle</SimpleAnimation>
		<NoiseThreshold Low="5" High="5"/>
		
		<Drop Resource="refill" GoodResource="refill_all"/>
		<SpawnActorSound>enemy_trilobite_burst</SpawnActorSound>
	</Actor>
	
	<Actor>
		<Name>enemy_trilobite_wall</Name>
		<Template>TRILOBITE_WALL</Template>
		
		<Sprite>Sprites/enemies-archaea;enemy_trilobite_wall</Sprite>
		<AllyGroup>archaean</AllyGroup>
		
		<Behavior>TrilobiteWall</Behavior>
		<Weapons>
			<Weapon>
				<AttackType>wall</AttackType>
				<AttackSound PitchPerHit="0.16">enemy_trilobite_dig</AttackSound>
				<AttackDamage TotalHits="5" Tier="10" Type="weak" IgnoreDepth="1"/>
				<AttackCooldown>0</AttackCooldown>
				<AttackEffect>tile_trilobite_damaged</AttackEffect>
			</Weapon>
		</Weapons>
		
		<EndSound>enemy_trilobite_die</EndSound>
	</Actor>
	
	<Actor>
		<Name>enemy_trilobite_mecha_wall</Name>
		<Template>TRILOBITE_WALL</Template>
		
		<HeartBeatTime>1.0</HeartBeatTime>
		<Sprite PlayAll="true">Sprites/enemies-vectron;vectron_trilobite_wall</Sprite>
		<AllyGroup>voltbot</AllyGroup>
		<Enemies>player;shiner;voltbot</Enemies>
		
		<NoiseThreshold Low="8" High="15"/>
		<Behavior>TrilobiteMechaWall</Behavior>
		<Weapons>
			<Weapon>
				<AttackType>wall</AttackType>
				<AttackSound PitchPerHit="0.15">trilobite_mecha_dig</AttackSound>
				<AttackDamage TotalHits="3" Tier="10" Type="weak" IgnoreDepth="1"/>
				<AttackCooldown>0</AttackCooldown>
				<AttackEffect>tile_destroyed_vectron</AttackEffect>
			</Weapon>
		</Weapons>
		
		<EndSound>trilobite_mecha_die</EndSound>
		<SpawnActorSound>trilobite_mecha_burst</SpawnActorSound>
	</Actor>
	
	<Actor>
		<Name>enemy_trilobite</Name>
		<Template>ACTOR</Template>
		
		<Sprite>Sprites/enemies-archaea;enemy_trilobite</Sprite>
		<CollisionBox>-10;-16;20;16</CollisionBox>
		<CollisionGroup>enemies</CollisionGroup>
		<AllyGroup>archaean</AllyGroup>
		<Enemies>player;shiner;voltbot</Enemies>
		<CheckOnGround>1</CheckOnGround>
		<GroundFriction>0.3</GroundFriction>
		<RandomWakeTime>0.5</RandomWakeTime>
		<HeartBeatTime>1</HeartBeatTime>
		<HeartBeatRandomTime>0.2</HeartBeatRandomTime>
		<ActivatesBarrels>1</ActivatesBarrels>
		
		<EnableRun>true</EnableRun>
		<Persistent>1</Persistent>
		<HitPoints>3</HitPoints>
		<WalkSpeed>40</WalkSpeed>
		<WalkAcceleration>1000</WalkAcceleration>
		<SimpleAnimation>walk</SimpleAnimation>
		<Behavior>Trilobite</Behavior>
		<DamageOnContact Amount="0.5" Type="normal"/>
		<Drop Resource="refill" GoodResource="refill_all"/>
		<EndEffect>trilobite_death</EndEffect>
		<EndSound>enemy_trilobite_die</EndSound>
		<AttackedEffect>enemy_hit</AttackedEffect>
		<AttackedSound>player_attack_trilobite</AttackedSound>
		<CrushedSound>fallblock_crush_archaean</CrushedSound>
		<WalkSound>enemy_trilobite_walk</WalkSound>
	</Actor>

	<Actor>
		<Name>enemy_trilobite_mecha</Name>
		<Template>ACTOR</Template>
		
		<Sprite>Sprites/enemies-vectron;vectron_trilobite</Sprite>
		<CollisionBox>-10;-16;20;16</CollisionBox>
		<CollisionGroup>enemies</CollisionGroup>
		<AllyGroup>voltbot</AllyGroup>
		<Enemies>player;archaean;shiner</Enemies>
		<CheckOnGround>1</CheckOnGround>
		<GroundFriction>0.3</GroundFriction>
		<RandomWakeTime>0.5</RandomWakeTime>
		<HeartBeatTime>1</HeartBeatTime>
		<HeartBeatRandomTime>0.5</HeartBeatRandomTime>
		<ActivatesBarrels>1</ActivatesBarrels>
		
		<Persistent>1</Persistent>
		<HitPoints>6</HitPoints>
		<WalkSpeed>90</WalkSpeed>
		<JumpSpeed>350</JumpSpeed>
		<SimpleAnimation>walk</SimpleAnimation>
		<Behavior>Trilobite</Behavior>
		<DamageOnContact Amount="1" Type="normal"/>
		<Drop Resource="refill" GoodResource="refill_all"/>
		<EndEffect>explosion_egg_tiny</EndEffect>
        <EndEffectOffset>0,-15</EndEffectOffset>
		<EndSound>trilobite_mecha_die</EndSound>
		<AttackedEffect>metal_hit</AttackedEffect>
		<AttackedSound>vectron_enemy_hit</AttackedSound>
		<CrushedSound>fallblock_crush_archaean</CrushedSound>
		<WalkSound>trilobite_mecha_walk</WalkSound>
	</Actor>

	<Actor>
		<Name>ENEMY_TURTLE_BASE</Name>
		<Template>ACTOR</Template>
		
		<CollisionGroup>enemies</CollisionGroup>
		<AllyGroup>archaean</AllyGroup>
		<Enemies>player;shiner;voltbot</Enemies>
		<CheckOnGround>1</CheckOnGround>
		<GroundFriction>0.3</GroundFriction>
		<RandomWakeTime>0.5</RandomWakeTime>
		<RandomDirection>true</RandomDirection>
		<HeartBeatTime>0.5</HeartBeatTime>
		<ActivatesBarrels>1</ActivatesBarrels>

		<Persistent>1</Persistent>
		<HitPoints>6</HitPoints>
		<WalkSpeed>26</WalkSpeed>
		<Animation>Turtle</Animation>
		<Behavior>Turtle</Behavior>
		<DamageOnContact Amount="0.5" Type="normal"/>
		<Drop Resource="refill" GoodResource="refill_all"/>
		<EndEffect>turtle_death</EndEffect>
		<EndSound>enemy_turtle_die</EndSound>
		<AttackedEffect>enemy_hit</AttackedEffect>
		<AttackedSound>player_attack_trilobite</AttackedSound>
		<CrushedSound>fallblock_crush_archaean</CrushedSound>
		<RejectSameTypeRadius>160</RejectSameTypeRadius>
		
		<Weapons>
			<Weapon>
				<AttackType>turtle_projectile</AttackType>
				<AttackSound>enemy_shiner_attack</AttackSound>
				<ProjectileName>turtle_spike</ProjectileName>
				<Trajectory Angle="0" AngleVariance="15" Force="320" ForceVariance="0"/>
				<AnimationInput>attack</AnimationInput>
				<Name>Spike</Name>
				<AttackCooldown>0.8</AttackCooldown>
			</Weapon>
		</Weapons>
	</Actor>
	
	<Actor>
		<Name>enemy_turtle</Name>
		<Template>ENEMY_TURTLE_BASE</Template>
		
		<Sprite>Sprites/enemies-archaea;enemy_turtle</Sprite>
		<CollisionBox>-16;-32;32;32</CollisionBox>
		<ProjectileSpawnOffset>0,8</ProjectileSpawnOffset>
	</Actor>
		
	<Actor>
		<Name>enemy_turtle_big</Name>
		<Template>ENEMY_TURTLE_BASE</Template>
		
		<Sprite Scale="2">Sprites/enemies-archaea;enemy_turtle</Sprite>
		<CollisionBox>-32;-64;64;64</CollisionBox>
	</Actor>
	
	<Actor>
		<Name>enemy_shiner</Name>
		<Template>ACTOR</Template>
		
		<Sprite PlayAll="1">Sprites/enemies-oldworld;enemy_shiner</Sprite>
		<CollisionBox>-8;-16;16;16</CollisionBox>
		<CollisionGroup>enemies</CollisionGroup>
		<AllyGroup>shiner</AllyGroup>
		<Enemies>player;archaean;voltbot</Enemies>
		<CheckOnGround>1</CheckOnGround>
		<GroundFriction>0.3</GroundFriction>
		<RandomWakeTime>0.5</RandomWakeTime>
		<RandomDirection>true</RandomDirection>
		<CanSleep>1</CanSleep>
		<LandSoft Speed="50" Sound="enemy_shiner_land"/>
		
		<Persistent>1</Persistent>
		<HitPoints>5</HitPoints>
		<WalkSpeed>75</WalkSpeed>
		<HeartBeatTime>1.0</HeartBeatTime>
		<IdleSoundTime>1.8</IdleSoundTime>
		<IdleSoundRandomTime>0.4</IdleSoundRandomTime>
		<Animation>Basic</Animation>
		<Behavior>Shiner</Behavior>
		<NoiseThreshold Low="1" High="7"/>
		<DamageOnContact Amount="1" Type="normal"/>
		<Drop Resource="refill" GoodResource="refill_all"/>
		<FallDamage Distance="130" MinDmg="1" LinearDmg="0.01"/>
		<AttackedEffect>enemy_hit</AttackedEffect>
		<AttackedSound>player_attack_shiner</AttackedSound>
		<CrushedSound>fallblock_crush_archaean</CrushedSound>
		<IdleSound>enemy_shiner_idle</IdleSound>
		<EndSound>enemy_shiner_die</EndSound>
		<EndEffect>shiner_death</EndEffect>
		<Weapons>
			<Weapon>
				<IdleAnimation>hand</IdleAnimation>
				<Name>None</Name>
			</Weapon>
			<Weapon>
				<AttackType>projectile</AttackType>
				<AttackSound>enemy_shiner_attack</AttackSound>
				<ProjectileName>dynamite_shiner</ProjectileName>
				<Trajectory Angle="-40" AngleVariance="5" Force="320" ForceVariance="40"/>
				<AttackDamage Amount="1" Tier="1"/>
				<AnimationInput>attack</AnimationInput>
				<IdleAnimation>dynamite</IdleAnimation>
				<Name>Dynamite</Name>
				<AttackOnGround>1</AttackOnGround>
				<AttackTime>0.25</AttackTime>
				<AttackSound>throw</AttackSound>
			</Weapon>
		</Weapons>
		<RejectSameTypeRadius>120</RejectSameTypeRadius>
	</Actor>
	
	<Actor>
		<Name>enemy_boozer</Name>
		<Template>ACTOR</Template>
		
		<Sprite>Sprites/enemies-oldworld;enemy_boozer</Sprite>
		<CollisionBox>-16;-32;32;32</CollisionBox>
		<CollisionGroup>enemies</CollisionGroup>
		<AllyGroup>shiner</AllyGroup>
		<Enemies>player;archaean;voltbot</Enemies>
		<CheckOnGround>1</CheckOnGround>
		<GroundFriction>0.3</GroundFriction>
		<RandomDirection>true</RandomDirection>
		<CanSleep>1</CanSleep>
		<GravityFactor>0.5</GravityFactor>
		<LandSoft Speed="50" Sound="player_land_soft_dirt"/>
		<GravityFactor>0.5</GravityFactor>
		<ActivatesBarrels>0</ActivatesBarrels>
				
		<Persistent>1</Persistent>
		<HitPoints>7</HitPoints>
		<WalkSpeed>0</WalkSpeed>
		<HeartBeatTime>1.5</HeartBeatTime>
		<Animation>Basic</Animation>
		<Behavior>Boozer</Behavior>
		<NoiseThreshold Low="3" High="4"/>
		<DamageOnContact Amount="1" Type="normal"/>
		<Drop Resource="refill" GoodResource="refill_all"/>
		<EndSound>enemy_boozer_die</EndSound>
		<EndEffect>boozer_death</EndEffect>
		<FallDamage Distance="10" MinDmg="100"/>
		<AttackedEffect>enemy_hit</AttackedEffect>
		<AttackedSound>player_attack_boozer</AttackedSound>
		<CrushedSound>fallblock_crush_archaean</CrushedSound>
		<Weapons>
			<Weapon>
				<AttackType>projectile</AttackType>
				<ProjectileName>flask</ProjectileName>
				<Trajectory Angle="30" AngleVariance="5" AngleMin="170" AngleMax="250" Force="360" ForceVariance="50" AimAtTarget="1"/>
				<AttackDamage Amount="1" Tier="1"/>
				<AnimationInput>attack</AnimationInput>
				<IdleAnimation>dynamite</IdleAnimation>
				<Name>Dynamite</Name>
				<AttackOnGround>1</AttackOnGround>
				<AttackTime>0.25</AttackTime>
				<AttackCooldown>1.0</AttackCooldown>
				<EndSound>enemy_boozer_bottle_hit</EndSound>
			</Weapon>
		</Weapons>
		<RejectSameTypeRadius>120</RejectSameTypeRadius>
	</Actor>
	
	<Actor>
		<Name>enemy_barrel</Name>
		<Template>ACTOR</Template>
		
		<Sprite>Sprites/enemies-oldworld;exploding_barrel</Sprite>
		<Light Sprite="blob" Scale="0.75" Offset="0,-20" Color="0.6,0.1,0.05"/>
		<CollisionBox>-20;-40;40;40</CollisionBox>
		<CollisionGroup>hard_enemies</CollisionGroup>
		<CollideAgainst>tiles;hard_enemies;rocks;support;player;enemies;beams</CollideAgainst>
		<AllyGroup>barrel</AllyGroup>
		<Enemies>player;archaean;shiner;voltbot</Enemies>
		<RoundPosition>1</RoundPosition>
		<CanSleep>1</CanSleep>
		<LandSoft Speed="50" Sound="fallblock_land"/>
		<AttackedSound>player_attack_barrel_metal</AttackedSound>
		<KnockbackSensitivity>0</KnockbackSensitivity>
		<WakeNeighboursOnMove>1</WakeNeighboursOnMove>
		
		<Persistent>1</Persistent>
		<HitPoints>4</HitPoints>
		<SimpleAnimation>idle</SimpleAnimation>
		<Behavior>Barrel</Behavior>
		<FallDamage Distance="10" MinDmg="100"/>
		<CollideDamage ReqVelocity="300" Amount="100"/>
		<ProjectileOnDeath>barrel_explode</ProjectileOnDeath>
		<WakeNeighboursOnDeath>1</WakeNeighboursOnDeath>
		<EndEffect>dynamite_explode</EndEffect>
		<EndEffectOffset>0,-20</EndEffectOffset>
		<RejectStandingOnDifferentType>1</RejectStandingOnDifferentType>
		<WalkOnSound>player_walk_dirt</WalkOnSound>
	</Actor>
	
	<Actor>
		<Name>enemy_shroom</Name>
		<SpecialType>bouncer</SpecialType>
		<Template>ACTOR</Template>
		
		<Sprite>Sprites/enemies-oldworld;bounce_shroom</Sprite>
		<CanRotate>true</CanRotate>
		<CollisionBox>-20;-30;40;30</CollisionBox>
		<CollisionGroup>hard_enemies</CollisionGroup>
		<CollideAgainst>tiles;hard_enemies;player;enemies;beams</CollideAgainst>
		<CollideSound>enemy_shroom_bounce</CollideSound>
		<AllyGroup>barrel</AllyGroup>
		<Enemies>player;archaean;shiner;voltbot</Enemies>
		<CanSleep>1</CanSleep>
		<WeightPressure>0</WeightPressure>
		<UpdatePhysics>0</UpdatePhysics>
		<AttachedDirection>0,1</AttachedDirection>
		<KnockbackSensitivity>0</KnockbackSensitivity>
		
		<Persistent>1</Persistent>
		<HitPoints>1</HitPoints>
		<Animation>Shroom</Animation>
		<Behavior>Shroom</Behavior>
		<EndEffect>shroom_destroyed</EndEffect>
		<EndEffectOffset>0,-20</EndEffectOffset>
		<EndSound>enemy_shroom_die</EndSound>
		<RejectStandingOnDifferentType>1</RejectStandingOnDifferentType>
		<RejectOthersOnTop>1</RejectOthersOnTop>
	</Actor>
		
	<Actor>
		<Name>enemy_spike</Name>
		<Template>ACTOR</Template>
		
		<Sprite>Sprites/enemies-archaea;enemy_spike</Sprite>
		<RenderPriority>-1100</RenderPriority>
		<CollisionBox>-16;-50;32;50</CollisionBox>
		<CollisionGroup>wall_enemies</CollisionGroup>
		<AllyGroup>barrel</AllyGroup>
		<Enemies>player;archaean;shiner;voltbot</Enemies>
		<UpdatePhysics>false</UpdatePhysics>
		<KnockbackSensitivity>0</KnockbackSensitivity>

		<Persistent>1</Persistent>
		<Hardness>666</Hardness>
		<HeartBeatTime>0.15</HeartBeatTime>
		<Animation>Basic</Animation>
		<Behavior>Spike</Behavior>
		<AttachedDirection>0,1</AttachedDirection>
		<Weapons>
			<Weapon>
				<AttackType>contact</AttackType>
				<AttackSound>enemy_spike_attack</AttackSound>
				<AttackDamage Amount="1.0" Type="reduced" Tier="1"/>
				<AttackTime>0.08</AttackTime>
				<AttackCooldown>1.0</AttackCooldown>
			</Weapon>
		</Weapons>
	</Actor>
	
	<Actor>
		<Name>enemy_turret</Name>
		<Template>ACTOR</Template>
		
		<Sprite>Sprites/enemies-vectron;enemy_turret</Sprite>
		<RenderPriority>-1050</RenderPriority>
		<CollisionBox>0;-16;32;32</CollisionBox>
		<CollideAgainst>tiles;hard_enemies;rocks;beams</CollideAgainst> <!-- Bugfix: disable collision vs pools -->
		<CollisionGroup>enemies</CollisionGroup>
		<AllyGroup>voltbot</AllyGroup>
		<Enemies>player;archaean;shiner</Enemies>
		<UpdatePhysics>false</UpdatePhysics>
		<CanRotate>true</CanRotate>
		<AttachedDirection>-1,0</AttachedDirection>
		<KnockbackSensitivity>0</KnockbackSensitivity>
		
		<Persistent>1</Persistent>
		<HitPoints>5</HitPoints>
		<InvulnerableToBeams>true</InvulnerableToBeams>
		<EndEffect>explosion_egg_tiny</EndEffect> <!-- todo -->
		<EndSound>destroy_turret</EndSound> <!-- todo -->
		<AttackedEffect>metal_hit</AttackedEffect>
		<AttackedSound>player_attack_turret</AttackedSound>
		
		<SimpleAnimation>idle</SimpleAnimation>
		<Behavior>Turret</Behavior>
		<HeartBeatTime>1.0</HeartBeatTime>
		<Cannon Name="cannon" Length="23" MaxAngle="90"/>
		<ProjectileSpawnOffset>9,0</ProjectileSpawnOffset>
		<Drop Resource="refill" GoodResource="refill_all"/>
		<RejectSameTypeRadius>80</RejectSameTypeRadius>
		
		<Weapons>
			<Weapon>
				<AttackType>laser</AttackType>
				<ProjectileName>vectron_turret_lockon_beam</ProjectileName>
				<AttackCooldown>1.0</AttackCooldown>
			</Weapon>
			<Weapon>
				<AttackType>laser</AttackType>
				<ProjectileName>vectron_turret_beam</ProjectileName>
				<AnimationInput>attack</AnimationInput>
				<AttackCooldown>1.0</AttackCooldown>
			</Weapon>
		</Weapons>
		
		<Beams ForcedUpdateTime="0.1"/>
	</Actor>

	<Actor>
		<Name>enemy_vectron_minion</Name>
		<Template>ACTOR</Template>
		
		<Sprite>Sprites/enemies-vectron;vectron_minion</Sprite>
		<CollisionBox>-15;-26;30;26</CollisionBox>
		<CollisionGroup>enemies</CollisionGroup>
		<AllyGroup>voltbot</AllyGroup>
		<Enemies>player;shiner;archaean</Enemies>
		<CheckOnGround>1</CheckOnGround>
		<GroundFriction>0.3</GroundFriction>
		<RandomWakeTime>0.5</RandomWakeTime>
		<HeartBeatTime>0.7</HeartBeatTime>
		<HeartBeatRandomTime>0</HeartBeatRandomTime>
		
		<EnableRun>true</EnableRun>
		<Persistent>1</Persistent>
		<HitPoints>3</HitPoints>
		<WalkSpeed>30</WalkSpeed>
		<WalkAcceleration>5000</WalkAcceleration>
		<JumpSpeed>700</JumpSpeed>
		<SimpleAnimation>walk</SimpleAnimation>
		<Behavior>VectronMinion</Behavior>
		<NullifyRadialDamage>true</NullifyRadialDamage>
		<DestroyOnContact>1</DestroyOnContact>
		<Drop Resource="refill" GoodResource="refill_all"/>
		<EndEffect>minion_explode</EndEffect>
		<EndEffectOffset>0,-20</EndEffectOffset>
		<EndSound></EndSound>
		<AttackedSound>vectron_enemy_hit</AttackedSound>
		<CrushedSound>fallblock_crush_archaean</CrushedSound> <!-- todo -->
		<WalkSound>trilobite_mecha_walk</WalkSound>
		<ProjectileOnDeath>vectron_minion_explode</ProjectileOnDeath>
		<WakeNeighboursOnDeath>1</WakeNeighboursOnDeath>
		<ActivatesBarrels>1</ActivatesBarrels>
	</Actor>
	<Actor>
		<Name>laser_box</Name>
		<Template>ACTOR</Template>
		
		<Sprite>Sprites/enemies-vectron;enemy_laserblock</Sprite>
		<CollisionGroup>hard_enemies</CollisionGroup>
		<Enemies>player</Enemies>
		<Light Sprite="blob" Scale="0.5" Offset="0,0" Color="1.0,0.25,0.25"/>

		<CollisionBox>-20;-20;40;40</CollisionBox>
		<CanRotate>true</CanRotate>
		<RoundPosition>true</RoundPosition>
		<Persistent>true</Persistent>
		<CanSleep>true</CanSleep>
		<UpdatePhysics>false</UpdatePhysics>
		<GravityFactor>0</GravityFactor>
		<HitPoints>99</HitPoints>
		<InvulnerableToBeams>true</InvulnerableToBeams>
		<EndEffect>explosion_egg_large</EndEffect> <!-- todo -->
		<EndSound>explosion</EndSound> <!-- todo -->
		<AttackedEffect>metal_hit</AttackedEffect>
		<AttackedSound>player_attack_laserbox</AttackedSound>
		<KnockbackSensitivity>0</KnockbackSensitivity>
		<WalkOnSound>player_walk_dirt</WalkOnSound>
		
		<HeartBeatTime>0.5</HeartBeatTime>
		<Behavior>LaserBox</Behavior>
		<ProjectileSpawnOffset>20,0</ProjectileSpawnOffset>
		<Cannon Name="pupil" Length="0" MaxAngle="360"/>

		<Beams Enabled="false" ForcedUpdateTime="0.1">
			<Beam Definition="laser_box_beam" Angle="0"/>
		</Beams>
	</Actor>
	
	<Actor>
		<Name>boss_generator</Name>
		<Template>ACTOR</Template>
		
		<Sprite PlayAll="true">Sprites/enemies-vectron;enemy_generator01</Sprite>
		<Light Sprite="lantern_blue_animated" Scale="1.5" Offset="0,0" Color="1,1,1"/>
		<CollisionBox>-20;-20;40;40</CollisionBox>
		<CanRotate>true</CanRotate>
		<MapIcon>generator_map</MapIcon>
		<AttackedEffect>metal_hit</AttackedEffect>
		<AttackedSound>vectron_enemy_hit</AttackedSound>
		<!-- <ConstantSound>generator_idle</ConstantSound> -->

		<KnockbackSensitivity>0</KnockbackSensitivity>
		<CollisionGroup>hard_enemies</CollisionGroup>
		<CollideAgainst>tiles;hard_enemies;rocks;support;player;enemies;items;transport;lamps</CollideAgainst>
		<RoundPosition>1</RoundPosition>
		<ForceUpdateIfAwake>1</ForceUpdateIfAwake>
		<GravityFactor>0</GravityFactor>
		<HitPoints>1000</HitPoints>
		<Behavior>BossGenerator</Behavior>
		<WalkOnSound>player_walk_dirt</WalkOnSound>
	</Actor>
	<Actor>
		<Name>boss_core</Name>
		<SpecialType>boss_core</SpecialType>
		<Template>ACTOR</Template>
		
		<Sprite>Sprites/enemies-vectron;enemy_boss</Sprite>
		<CollisionBox>-40;-40;80;80</CollisionBox>
		<Animation>BossBody</Animation>
		<AnimationState>body</AnimationState>
		<Light Sprite="blob" Scale="2.5" Offset="0,0" Color="0.9,0.4,0.4"/>
		<ConstantSound>boss_idle</ConstantSound>
		
		<CanRotate>true</CanRotate>
		<KnockbackSensitivity>0</KnockbackSensitivity>
		<Invulnerable>1</Invulnerable>
		<VulnerableDirection>0,1</VulnerableDirection>
		<AttackedEffect Offset="0,-40">metal_hit</AttackedEffect>
		<AttackedSound>player_attack_metal</AttackedSound>
		<AttackedInvulnerableSound>player_attack_pick_invulnerable</AttackedInvulnerableSound>
		<CollisionGroup>boss</CollisionGroup>
		<CollideAgainst>tiles;hard_enemies;rocks;support;player;enemies;items;transport;lamps</CollideAgainst>
		<RoundPosition>1</RoundPosition>
		<ForceUpdateIfAwake>1</ForceUpdateIfAwake>
		<GravityFactor>0</GravityFactor>
		<AllyGroup>voltbot</AllyGroup>
		<Enemies>player</Enemies>

		<HitPoints>1000</HitPoints>
		<Behavior>BossCore</Behavior>
		<HeartBeatTime>3</HeartBeatTime>
		<HeartBeatRandomTime>0</HeartBeatRandomTime>
		<DamageOnContact Amount="0.5" KnockbackMultiplier="0.75"/>
		<WalkOnSound>player_walk_dirt</WalkOnSound>
		
		<Weapons>
			<Weapon>
				<AttackType>projectile</AttackType>
				<ProjectileName>boss_capsule_1</ProjectileName>
				<Trajectory Angle="270" AngleVariance="40" Force="300" ForceVariance="0" IgnoreAimAngle="true"/>
				<SpawnOffset>0,-30</SpawnOffset>
				<AttackTime>1</AttackTime>
				<AttackCooldown>1</AttackCooldown>
				<AttackSoundHit>boss_throw_capsule</AttackSoundHit>
			</Weapon>
			<Weapon>
				<AttackType>projectile</AttackType>
				<ProjectileName>boss_capsule_2</ProjectileName>
				<Trajectory Angle="270" AngleVariance="40" Force="300" ForceVariance="0" IgnoreAimAngle="true"/>
				<SpawnOffset>0,-30</SpawnOffset>
				<AttackTime>0.9</AttackTime>
				<AttackCooldown>0.9</AttackCooldown>
				<AttackSoundHit>boss_throw_capsule</AttackSoundHit>
			</Weapon>
			<Weapon>
				<AttackType>projectile</AttackType>
				<ProjectileName>boss_capsule_2</ProjectileName>
				<Trajectory Angle="270" AngleVariance="40" Force="300" ForceVariance="0" IgnoreAimAngle="true"/>
				<SpawnOffset>0,-30</SpawnOffset>
				<AttackTime>0.4</AttackTime>
				<AttackCooldown>0.4</AttackCooldown>
				<AttackSoundHit>boss_throw_capsule</AttackSoundHit>
			</Weapon>
			<Weapon>
				<AttackType>laser</AttackType>
				<ProjectileName>boss_lock_on_laser_1</ProjectileName>
				<AttackTime>0</AttackTime>
				<AttackCooldown>1.7</AttackCooldown>
			</Weapon>
			<Weapon>
				<AttackType>laser</AttackType>
				<ProjectileName>boss_targeting_laser</ProjectileName>
				<AttackTime>0</AttackTime>
				<AttackCooldown>1.5</AttackCooldown>
			</Weapon>
			<Weapon>
				<AttackType>laser</AttackType>
				<ProjectileName>boss_lock_on_laser_2</ProjectileName>
				<AttackTime>0</AttackTime>
				<AttackCooldown>1.7</AttackCooldown>
			</Weapon>
			<Weapon>
				<AttackType>laser</AttackType>
				<ProjectileName>boss_rotating_laser_1</ProjectileName>
				<AttackTime>0</AttackTime>
				<AttackCooldown>5</AttackCooldown>
			</Weapon>
			<Weapon>
				<AttackType>laser</AttackType>
				<ProjectileName>boss_rotating_laser_2</ProjectileName>
				<AttackTime>0</AttackTime>
				<AttackCooldown>5</AttackCooldown>
			</Weapon>
			<!-- <Weapon>
				<AttackType>laser</AttackType>
				<ProjectileName>boss_rotating_laser_3</ProjectileName>
				<AttackTime>0</AttackTime>
				<AttackCooldown>10</AttackCooldown>
			</Weapon> -->
		</Weapons>

		<Cannon Name="eye" Length="20" MaxAngle="360"/>
		<Beams Enabled="false">
			<!-- <Beam Definition="boss_rotating_laser" Angle="330" /> -->
			<!-- <Beam Definition="boss_targeting_laser" Angle="0" /> -->
		</Beams>
	</Actor>
	
	<Actor>
		<Name>boss_mg</Name>
		<Sprite PlayAll="true">Sprites/boss-vectron;boss_mg</Sprite>
		<RenderPriority>800</RenderPriority>
		<CollisionGroup>wall_enemies</CollisionGroup>
		<CollisionBox>-127;-252;276;262</CollisionBox>
		<UpdatePhysics>false</UpdatePhysics>
	</Actor>

	<Actor>
		<Name>barrier</Name>
		<SpecialType>barrier</SpecialType>
		
		<CollisionGroup>wall_enemies</CollisionGroup>
		<CanRotate>true</CanRotate>
		<Invulnerable>true</Invulnerable>
		<ForceUpdateOnCreation>true</ForceUpdateOnCreation>
		<GravityFactor>0</GravityFactor>
		<UpdatePhysics>false</UpdatePhysics>
		<CanSleep>true</CanSleep>
	</Actor>
	<Actor>
		<Name>generator</Name>
		<Template>ACTOR</Template>
		<SpecialType>generator</SpecialType>
		
		<Sprite PlayAll="true">Sprites/enemies-vectron;enemy_generator01</Sprite><!-- todo -->
		<Light Sprite="lantern_blue_animated" Scale="2.0" Offset="0,0" Color="1,1,1"/>		
		<CollisionBox>-20;-20;40;40</CollisionBox>
		<MapIcon>generator_map</MapIcon>
		<AttackedEffect>metal_hit</AttackedEffect>
		<AttackedSound>vectron_enemy_hit</AttackedSound>
		<KnockbackSensitivity>0</KnockbackSensitivity>
		<ConstantSound>generator_idle</ConstantSound>
		
		<CollisionGroup>hard_enemies</CollisionGroup>
		<UpdatePhysics>0</UpdatePhysics>
		<RoundPosition>true</RoundPosition>
		<GravityFactor>0</GravityFactor>
		<HitPoints>6</HitPoints>
		<EndEffect>generator_explosion</EndEffect>
		<WalkOnSound>player_walk_dirt</WalkOnSound>
	</Actor>
</ActorDefinitions>
