mirror of
https://github.com/illiumst/marl-factory-grid.git
synced 2025-07-06 17:41:36 +02:00
no more tiles no more floor
This commit is contained in:
marl_factory_grid
algorithms
configs
environment
modules
batteries
clean_up
destinations
doors
factory
items
machines
maintenance
zones
utils
@ -37,7 +37,11 @@ class PositionMixin:
|
||||
|
||||
def __delitem__(self, name):
|
||||
idx, obj = next((i, obj) for i, obj in enumerate(self) if obj.name == name)
|
||||
obj.tile.leave(obj) # observer notify?
|
||||
try:
|
||||
for observer in obj.observers:
|
||||
observer.notify_del_entity(obj)
|
||||
except AttributeError:
|
||||
pass
|
||||
super().__delitem__(name)
|
||||
|
||||
def by_pos(self, pos: (int, int)):
|
||||
|
Reference in New Issue
Block a user