dialog WIP paths consolidation and rendering

This commit is contained in:
Jonas H
2026-03-28 10:34:19 +01:00
parent 4c3ebca96e
commit 11b31169b1
70 changed files with 2658 additions and 485 deletions

View File

@@ -1,6 +1,8 @@
use glam::Vec3;
use crate::components::trigger::{TriggerEvent, TriggerEventKind, TriggerFilter, TriggerShape, TriggerState};
use crate::components::trigger::{
TriggerEvent, TriggerEventKind, TriggerFilter, TriggerShape, TriggerState,
};
use crate::entity::EntityHandle;
use crate::world::World;
@@ -35,10 +37,12 @@ pub fn trigger_system(world: &mut World)
let overlapping = match world.triggers.get(trigger_entity)
{
Some(trigger) => activator_positions.iter().any(|(_, pos)| match &trigger.shape
{
TriggerShape::Sphere { radius } => (trigger_pos - *pos).length() < *radius,
}),
Some(trigger) => activator_positions
.iter()
.any(|(_, pos)| match &trigger.shape
{
TriggerShape::Sphere { radius } => (trigger_pos - *pos).length() < *radius,
}),
None => continue,
};