Lua functions list

(Difference between revisions)
Jump to: navigation, search
(System)
Line 1: Line 1:
 +
===3d Math===
 +
 +
* [[vec3]](x, y, z)
 +
* [[length]](vec3)
 +
* [[normalize]](vec3)
 +
* [[dot]](vec3)
 +
* [[cross]](vec3)<br><br>
 
===Object===
 
===Object===
  
 
* [[getObject]](« objectName »)
 
* [[getObject]](« objectName »)
 +
* [[getParent]](object)
 +
* [[getChilds]](object)
 
* [[getClone]](object)
 
* [[getClone]](object)
 +
* [[setParent]](object, parent)
 +
* [[getName]](object)
 +
* [[activate]](object)
 +
* [[deactivate]](object)
 +
* [[isVisible]](object)
 +
* [[isActive]](object)<br><br>
 
* [[rotate]](object, {x, y, z}, angle, ''"local"'')
 
* [[rotate]](object, {x, y, z}, angle, ''"local"'')
 
* [[translate]](object, {x, y, z}, ''"local"'')
 
* [[translate]](object, {x, y, z}, ''"local"'')
Line 10: Line 25:
 
* [[setPosition]](object, {x, y, z})
 
* [[setPosition]](object, {x, y, z})
 
* [[setRotation]](object, {x, y, z})
 
* [[setRotation]](object, {x, y, z})
* [[setScale]](object, {x, y, z})
+
* [[setScale]](object, {x, y, z})<br><br>
* [[isVisible]](object)
+
* [[getTransformedPosition]](object)
* [[activate]](object)
+
* [[getTransformedRotation]](object)
* [[deactivate]](object)
+
* [[getTransformedScale]](object)
 
+
* [[getInverseRotatedVector]](object)
 +
* [[getRotatedVector]](object)
 +
* [[getInverseVector]](object)
 +
* [[getTransformedVector]](object)
 +
* [[updateMatrix]](object)
 +
* [[getMatrix]](object)<br><br>
 +
* [[enableShadow]](object, shadow)
 +
* [[isCastingShadow]](object)<br><br>
 
===Behavior===
 
===Behavior===
  
 
* [[getBehaviorVariable]](object, behaviorId, "variableName")
 
* [[getBehaviorVariable]](object, behaviorId, "variableName")
* [[setBehaviorVariable]](object, behaviorId, "variableName", value)
+
* [[setBehaviorVariable]](object, behaviorId, "variableName", value)<br><br>
 
+
 
===Animation===
 
===Animation===
  
Line 25: Line 46:
 
* [[changeAnimation]](object, animationId)
 
* [[changeAnimation]](object, animationId)
 
* [[isAnimationOver]](object)
 
* [[isAnimationOver]](object)
 
+
* [[getAnimationSpeed]](object)
 +
* [[setAnimationSpeed]](object, speed)
 +
* [[getCurrentFrame]](object)
 +
* [[setCurrentFrame]](object, frame)<br><br>
 
===Physics===
 
===Physics===
  
 
* [[setGravity]]({x, y, z})
 
* [[setGravity]]({x, y, z})
* [[getGravity]]()
+
* [[getGravity]]()<br><br>
* [[addCentralForce]](object, {x, y, z}, ''"local"'')
+
* [[addTorque]](object, {x, y, z}, ''"local"'')
+
 
* [[getLinearDamping]](object)
 
* [[getLinearDamping]](object)
* [[setLinearDamping]](object, {x, y, z})
+
* [[setLinearDamping]](object, damping)
 
* [[getAngularDamping]](object)
 
* [[getAngularDamping]](object)
 
* [[setAngularDamping]](object, damping)
 
* [[setAngularDamping]](object, damping)
 +
* [[getLinearFactor]](object)
 +
* [[setLinearFactor]](object, {x, y, z})
 +
* [[getAngularFactor]](object)
 +
* [[setAngularFactor]](object, factor)
 +
* [[getMass]](object)
 +
* [[setMass]](object, mass)
 +
* [[getFriction]](object)
 +
* [[setFriction]](object, friction)
 +
* [[getRestitution]](object)
 +
* [[setRestitution]](object, restitution)<br><br>
 +
* [[clearForces]](object)
 +
* [[addCentralForce]](object, {x, y, z}, ''"local"'')
 +
* [[addTorque]](object, {x, y, z}, ''"local"'')
 +
* [[getCentralForce]](object)
 +
* [[getTorque]](object)
 
* [[isCollisionTest]](object)
 
* [[isCollisionTest]](object)
 
* [[isCollisionBetween]](object1, object2)
 
* [[isCollisionBetween]](object1, object2)
* [[clearForces]](object)
 
 
* [[getNumCollisions]](object)
 
* [[getNumCollisions]](object)
* [[rayHit]](start, end, ''object'')
+
* [[rayHit]](start, end, ''object'')<br><br>
 
+
 
===Inputs===
 
===Inputs===
  
Line 48: Line 83:
 
* [[onKeyUp]]([[Keys|key]])
 
* [[onKeyUp]]([[Keys|key]])
 
* [[getAxis]]([[Axis|axis]])
 
* [[getAxis]]([[Axis|axis]])
 
+
* [[getProperty]]("propertyName")
 +
* [[getTouchPosition]](touchId)
 +
* [[getLastTouchPosition]](touchId)
 +
* [[getTouchPhase]](touchId)<br><br>
 
===Sound===
 
===Sound===
  
Line 55: Line 93:
 
* [[stopSound]](object)
 
* [[stopSound]](object)
 
* [[getSoundGain]](object)
 
* [[getSoundGain]](object)
* [[setSoundGain]](object, gain)
+
* [[setSoundGain]](object, gain)<br><br>
 
+
 
===Scene===
 
===Scene===
  
 
* [[getScene]]("sceneName")
 
* [[getScene]]("sceneName")
 
* [[changeScene]](scene)
 
* [[changeScene]](scene)
 
+
* [[getCurrentSceneId]]()
 +
* [[getScenesNumber]]()<br><br>
 
===Level===
 
===Level===
  
* [[loadLevel]]("levelName")
+
* [[loadLevel]]("levelName")<br><br>
 
+
 
===Light===
 
===Light===
  
Line 71: Line 108:
 
* [[getLightRadius]](object)
 
* [[getLightRadius]](object)
 
* [[getLightIntensity]](object)
 
* [[getLightIntensity]](object)
 +
* [[getLightShadowQuality]](object)
 +
* [[getLightShadowBias]](object)
 +
* [[getLightShadowBlur]](object)
 +
* [[getLightSpotAngle]](object)
 +
* [[getLightSpotExponent]](object)
 
* [[setLightColor]](object, {r, g, b})
 
* [[setLightColor]](object, {r, g, b})
 
* [[setLightRadius]](object, radius)
 
* [[setLightRadius]](object, radius)
 
* [[setLightIntensity]](object, intensity)
 
* [[setLightIntensity]](object, intensity)
 
+
* [[setLightShadowQuality]](object, quality)
 +
* [[setLightShadowBias]](object, bias)
 +
* [[setLightShadowBlur]](object, blur)
 +
* [[setLightSpotAngle]](object, spotAngle)
 +
* [[setLightSpotExponent]](object, exponent)<br><br>
 
===Camera===
 
===Camera===
  
 
* [[changeCurrentCamera]](object)
 
* [[changeCurrentCamera]](object)
 +
* [[getCurrentCamera]]()<br><br>
 
* [[getCameraClearColor]](object)
 
* [[getCameraClearColor]](object)
 
* [[getCameraFov]](object)
 
* [[getCameraFov]](object)
Line 91: Line 138:
 
* [[setCameraFogDistance]](object, fogDistance)
 
* [[setCameraFogDistance]](object, fogDistance)
 
* [[enableCameraOrtho]](object, ortho)
 
* [[enableCameraOrtho]](object, ortho)
* [[enableCameraFog]](object, fog)
+
* [[enableCameraFog]](object, fog)<br><br>
 
* [[enableCameraLayer]](object, scene)
 
* [[enableCameraLayer]](object, scene)
 
* [[disableCameraLayer]](object)
 
* [[disableCameraLayer]](object)
 
* [[enableRenderToTexture]](object, "textureName", renderWith, renderHeight)
 
* [[enableRenderToTexture]](object, "textureName", renderWith, renderHeight)
* [[disableRenderToTexture]](object)
+
* [[disableRenderToTexture]](object)<br><br>
 
+
* [[getProjectedPoint]](object, point)
 +
* [[getUnProjectedPoint]](object, point)<br><br>
 
===Text===
 
===Text===
  
Line 102: Line 150:
 
* [[getText]](object)
 
* [[getText]](object)
 
* [[getTextColor]](object)
 
* [[getTextColor]](object)
* [[setTextColor]](object, {r, g, b, a})
+
* [[setTextColor]](object, {r, g, b, a})<br><br>
 
+
 
===System===
 
===System===
  
Line 109: Line 156:
 
* [[hideCursor]]()
 
* [[hideCursor]]()
 
* [[showCursor]]()
 
* [[showCursor]]()
 +
* [[getWindowScale]]()
 +
* [[getSystemTick]]()
 
* [[quit]]()
 
* [[quit]]()
 
* [[dofile]]("filename.lua")
 
* [[dofile]]("filename.lua")

Revision as of 15:35, 5 February 2013

Contents

3d Math

Object

Behavior

Animation

Physics

Inputs

Sound

Scene

Level

Light

Camera

Text

System

Personal tools
Namespaces
Variants
Actions
Navigation
Toolbox