| Class KX_GameActuator (2.48) |
|
|
| getExecutePriority |
setExecutePriority |
| getOwner |
---------- |
|
|
getFile
getFile()
Returns the name of the blend file to load.
Type: string
Sample
Code
# get the controller
controller = GameLogic.getCurrentController()
# get the actuator attached to the controller named act
act = controller.getActuator("act")
# get name of blend file from actuator to be loaded
name = act.getFile()
setFile
setFile(filename)
Sets the name of the blend file to load.
filename:
Type is string
Note:
If it's in the same directory, just the name of the
blend.
ie. "myGame.blend"
If it's in a different directory, full path.
ie "C:\\BlenderGames\\myGame.blend"
Sample
Code
# get the controller
controller = GameLogic.getCurrentController()
# get the actuator attached to the controller named act
act = controller.getActuator("act")
# set name of blend file to be loaded
act.setFile("Level2.blend")
# use the game actuator
GameLogic.addActiveActuator( act, True)
|