delete entities w/o fadeout if current view isn't active
parent
bb48704bd6
commit
d14b8246f5
|
@ -4,11 +4,17 @@
|
|||
#include "prediction.h"
|
||||
#include "librg.h"
|
||||
#include "world/world.h"
|
||||
#include "game.h"
|
||||
|
||||
int32_t tracker_read_remove(librg_world *w, librg_event *e) {
|
||||
int64_t entity_id = librg_event_entity_get(w, e);
|
||||
world_view *view = (world_view*)librg_world_userdata_get(w);
|
||||
entity_view_mark_for_removal(&view->entities, entity_id);
|
||||
|
||||
if (view != game_world_view_get_active()) {
|
||||
entity_view_destroy(&view->entities, entity_id);
|
||||
} else {
|
||||
entity_view_mark_for_removal(&view->entities, entity_id);
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
|
@ -27,7 +27,7 @@ load_paths =
|
|||
{
|
||||
{{
|
||||
{ ".", .recursive = false, .relative = true },
|
||||
{ "code/apps/client", .recursive = true, .relative = true },
|
||||
{ "code/game", .recursive = true, .relative = true },
|
||||
{ "code/common", .recursive = true, .relative = true },
|
||||
{ "code/modules", .recursive = true, .relative = true },
|
||||
{ "code/vendors", .recursive = true, .relative = true },
|
||||
|
|
Loading…
Reference in New Issue