blob: 66dddfd390cf7527acbfeb8c2d19550d8d0b75ea (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
from UM.Scene.SceneNodeDecorator import SceneNodeDecorator
## A decorator that stores the amount an object has been moved below the platform.
class ZOffsetDecorator(SceneNodeDecorator):
def __init__(self):
self._z_offset = 0
def setZOffset(self, offset):
self._z_offset = offset
def getZOffset(self):
return self._z_offset
def __deepcopy__(self, memo):
copied_decorator = ZOffsetDecorator()
copied_decorator.setZOffset(self.getZOffset())
return copied_decorator
|