forked from tas/major_tom
Fix missing collision for charger, spawner, and laser turret
All three new entity types were absent from the hardcoded enemy-type checks in is_enemy() (contact damage + projectile hits), homing projectile targeting, and drone targeting. Also adds proper death particle colors for charger (orange) and spawner (purple).
This commit is contained in:
@@ -251,7 +251,9 @@ static void projectile_update(Entity *self, float dt, const Tilemap *map) {
|
||||
|
||||
/* Player bullets target enemies, enemy bullets target player */
|
||||
if (is_player_proj) {
|
||||
if (e->type != ENT_ENEMY_GRUNT && e->type != ENT_ENEMY_FLYER) continue;
|
||||
if (e->type != ENT_ENEMY_GRUNT && e->type != ENT_ENEMY_FLYER &&
|
||||
e->type != ENT_TURRET && e->type != ENT_ENEMY_CHARGER &&
|
||||
e->type != ENT_SPAWNER && e->type != ENT_LASER_TURRET) continue;
|
||||
} else {
|
||||
if (e->type != ENT_PLAYER) continue;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user