flowchart whiteboard - robblofield/TomeboundDocs GitHub Wiki
graph TD;
%% Player Input
A[Player Presses Fire] --> B{Can Fire?};
%% Can't Fire
B -->|No| Z1[Play Empty Clip Sound];
Z1 --> Z2[Exit Function];
%% Can Fire
B -->|Yes| C[Reduce Ammo Count];
C --> D[Play Muzzle Flash & Sound];
D --> E[Perform Hit Detection];
%% Hit or Miss
E -->|Hit Enemy| F[Call TakeDamage()];
E -->|Miss| G[No Action];
%% Enemy Damage Outcome
F --> H{HP <= 0?};
H -->|Yes| I[Enemy Death Event];
H -->|No| J[Continue Gameplay];
%% Enemy Death Branch
I --> K[Respawn or Remove Enemy];