Addressed more comments. Changed how buffs were sorted so that duration was also taken into account.

This commit is contained in:
Sam
2020-10-24 20:20:03 -05:00
parent f759895d63
commit 5d0fd3d9bc
7 changed files with 104 additions and 92 deletions

View File

@ -51,7 +51,7 @@ impl<'a> System<'a> for Sys {
span!(_guard, "run", "controller::Sys::run");
let mut server_emitter = server_bus.emitter();
for (entity, uid, controller, character_state) in
for (entity, _uid, controller, character_state) in
(&entities, &uids, &mut controllers, &mut character_states).join()
{
let mut inputs = &mut controller.inputs;
@ -85,7 +85,7 @@ impl<'a> System<'a> for Sys {
},
ControlEvent::RemoveBuff(buff_id) => {
server_emitter.emit(ServerEvent::Buff {
uid: *uid,
entity,
buff_change: BuffChange::RemoveFromController(buff_id),
});
},