ya2 · news · projects · code · about

json: scene items
[pmachines.git] / pmachines / items / basketball.py
CommitLineData
c991401b 1from panda3d.bullet import BulletSphereShape
4586cbf6 2from pmachines.items.item import Item
8254721d
FC
3
4
5class Basketball(Item):
6
98741d67
FC
7 def __init__(self, world, plane_node, cb_inst, curr_bottom, repos, json, mass=1, pos=(0, 0, 0), r=0, count=0, restitution=.92, friction=.6):
8 super().__init__(world, plane_node, cb_inst, curr_bottom, repos, 'assets/models/bam/basketball/basketball.bam', json, .4, mass=mass, pos=pos, r=r, count=count, restitution=restitution, friction=friction)
8254721d 9
80d579b1 10 def _set_shape(self, apply_scale=True):
ea38777c 11 self.node.add_shape(BulletSphereShape(1))