feat: add Captured and TractorBeam components, enhance enemy behavior with capture mechanics
This commit is contained in:
parent
1d1b927007
commit
008f9cc24a
5 changed files with 366 additions and 107 deletions
|
|
@ -1,4 +1,5 @@
|
|||
use bevy::math::Vec2;
|
||||
use bevy::prelude::*;
|
||||
|
||||
// --- Constants ---
|
||||
pub const WINDOW_WIDTH: f32 = 600.0;
|
||||
|
|
@ -31,3 +32,9 @@ pub const BULLET_ENEMY_COLLISION_THRESHOLD: f32 = (BULLET_SIZE.x + ENEMY_SIZE.x)
|
|||
pub const PLAYER_ENEMY_COLLISION_THRESHOLD: f32 = (PLAYER_SIZE.x + ENEMY_SIZE.x) * 0.5;
|
||||
// 35.0
|
||||
pub const ENEMY_BULLET_PLAYER_COLLISION_THRESHOLD: f32 = (ENEMY_BULLET_SIZE.x + PLAYER_SIZE.x) * 0.5;
|
||||
|
||||
// Tractor beam constants
|
||||
pub const TRACTOR_BEAM_WIDTH: f32 = 20.0;
|
||||
pub const TRACTOR_BEAM_DURATION: f32 = 3.0;
|
||||
pub const TRACTOR_BEAM_COLOR: Color = Color::rgba(0.5, 0.0, 0.8, 0.6);
|
||||
pub const CAPTURE_DURATION: f32 = 10.0; // How long the player stays captured
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue