summaryrefslogtreecommitdiff
path: root/src/room.rs
diff options
context:
space:
mode:
authortroido <troido@protonmail.com>2020-05-21 12:25:36 +0200
committertroido <troido@protonmail.com>2020-06-05 22:27:53 +0200
commitbd1da23cf18960b36f8683c09899044d64b4bd83 (patch)
tree605207d2a5219682d5aab2d6de2f601a5fc68834 /src/room.rs
parentde4505121dd8b2216e8c797b4b7b7347e5d98c2f (diff)
made Talk its own component/system instead of part of interact
Diffstat (limited to 'src/room.rs')
-rw-r--r--src/room.rs8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/room.rs b/src/room.rs
index 0b8ee3b..d39bdb1 100644
--- a/src/room.rs
+++ b/src/room.rs
@@ -70,7 +70,8 @@ use crate::{
Building,
Deduplicate,
SpawnTrigger,
- Replace
+ Replace,
+ Talk
}
};
@@ -86,12 +87,13 @@ pub fn default_dispatcher<'a, 'b>() -> Dispatcher<'a, 'b> {
.with(Take, "take", &["controlinput", "controlai"])
.with(Use, "use", &["controlinput", "controlai"])
.with(Interact, "interact", &["controlinput", "controlai"])
+ .with(Talk, "talk", &["controlinput", "controlai"])
.with(SpawnTrigger, "spawntrigger", &["spawn", "deduplicate", "replace"])
.with(Move, "move", &["controlinput", "controlai"])
.with(Trapping, "trapping", &["move"])
.with(Fight, "fight", &["move"])
.with(Heal, "heal", &[])
- .with(Attacking, "attacking", &["use", "trapping", "fight", "heal", "interact", "spawntrigger"])
+ .with(Attacking, "attacking", &["use", "trapping", "fight", "heal", "interact", "talk", "spawntrigger"])
.with(Die, "die", &["attacking"])
.with(DropLoot, "droploot", &["attacking"])
.with(Building, "building", &["attacking"])
@@ -125,7 +127,7 @@ impl <'a, 'b>Room<'a, 'b> {
world.insert(NewEntities::new(encyclopedia));
register_insert!(
world,
- (Position, Visible, Controller, Movable, New, Removed, Moved, Player, Inventory, Health, Serialise, RoomExit, Entered, TriggerBox, Trap, Fighter, Healing, ControlCooldown, Autofight, MonsterAI, Home, AttackInbox, Item, Spawner, Clan, Faction, Interactable, Loot, Timer, Equipment, TimeOffset, Flags, Ear, Build, Whitelist, Dedup, Minable, LootHolder, OnSpawn, Substitute),
+ (Position, Visible, Controller, Movable, New, Removed, Moved, Player, Inventory, Health, Serialise, RoomExit, Entered, TriggerBox, Trap, Fighter, Healing, ControlCooldown, Autofight, MonsterAI, Home, AttackInbox, Item, Spawner, Clan, Faction, Interactable, Loot, Timer, Equipment, TimeOffset, Flags, Ear, Build, Whitelist, Dedup, Minable, LootHolder, OnSpawn, Substitute, Talkable),
(Ground, Input, Output, Size, Spawn, Players, Emigration, Time, RoomPermissions)
);