30 lines
1,022 B
Text
30 lines
1,022 B
Text
--'******************************************************
|
|
--'* Áèíäåð îáúåêòà ñìàðò êàâåð .
|
|
--'******************************************************
|
|
registered_smartcovers = {}
|
|
|
|
function bind(obj)
|
|
obj:bind_object(smart_cover_binder(obj))
|
|
end
|
|
|
|
class "smart_cover_binder" (object_binder)
|
|
function smart_cover_binder:__init(obj) super(obj)
|
|
end
|
|
function smart_cover_binder:net_spawn(server_object)
|
|
if not object_binder.net_spawn(self, server_object) then
|
|
return false
|
|
end
|
|
registered_smartcovers[self.object:name()] = self.object
|
|
printf("smart_cover_binder.net_spawn() smart_cover [%s] is registered %s", self.object:name(), vec_to_str(self.object:direction()))
|
|
return true
|
|
end
|
|
function smart_cover_binder:net_destroy()
|
|
registered_smartcovers[self.object:name()] = nil
|
|
printf("smart_cover_binder.net_destroy() smart_cover [%s] is unregistered", self.object:name())
|
|
object_binder.net_destroy(self)
|
|
end
|
|
|
|
function smart_cover_binder:update(delta)
|
|
object_binder.update(self, delta)
|
|
end
|
|
|