PyANGKernel.GKMobileAgent

class GKMobileAgent

Base class for any kind of vehicle

Inheritance diagram of PyANGKernel.GKMobileAgent

Inherited by: GKVehicle

Synopsis

Methods

Virtual methods

Note

This documentation may contain snippets that were automatically translated from C++ to Python. We always welcome contributions to the snippet translation. If you see an issue with the translation, you can also let us know by creating a ticket on https:/bugreports.qt.io/projects/PYSIDE

__init__()
clearShapes2D()

Clears all the articulated lengths and shapes 2D. There will be no articulated part defined, just one part related to the only existing part (with length -1, that means the whole vehicle length).

clearShapes3D()

Deletes all the 3D shapes defined

getAlwaysVertical()
Return type:

bool

Gets if the vehicles are always drawn vertical

getImageName([pos=0])
Parameters:

pos – int

Return type:

str

It return the image associated with the “pos” part of the vehicle. “pos” is 0 for the part in the front and “pos” is nbParts-1 for the rear part of the vehicle.

getImagesName()
Return type:

list of strings

For shapes 2d using an image: its name

getShape3DPosFromLength(length)
Parameters:

length – float

Return type:

int

Gets the vector index associated with that length having into account the percentages and the from and to values defined.

isArticulated()
Return type:

bool

setAlwaysVertical(vertical)
Parameters:

vertical – bool

Sets if the vehicles are always drawn vertical

setImagesName(names)
Parameters:

names – list of strings

For shapes 2d using an image: its name