GameObject module

class GameObject.GameObject(app, name='undefined', model='defaultMeshes/cube.bam', ground=False, x=0, y=0, z=0, rx=0, ry=0, rz=0, sx=1, sy=1, sz=1, mass=0, overlapping=False, emission=False, animations={})

Bases: object

animations

Animations

app

The main application

convexHullShape(model)

convexHullShape Hull shape from the model

createShape(model)

createShape Creates the collision Shape of the object. Gets called in the __init__ function

Parameters

model (str) – The model it should display. A .bam file, defaults to “defaultMeshes/cube.bam”

Returns

Collision shape

Return type

BulletCollisionShape

lights

Emission lights attached to the object

model

The model path

name

The name of the object

node

The main node which displays the object. You can get the physical node by self.node.node()

overlapping

Should the object be overlapping (cannot be changed while running)

simpleShape(*args)

simpleShape Just a box

transform(x, y, z, rx, ry, rz, sx, sy, sz)

transform Transforms the object

triangleShape(model)

triangleShape Exact shape from the model. Can’t be used for moving objects.