<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-GB">
	<id>https://wiki.crumbledworld.com/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Anders</id>
	<title>Crumbled World Wiki - User contributions [en-gb]</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.crumbledworld.com/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Anders"/>
	<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php/Special:Contributions/Anders"/>
	<updated>2026-04-22T00:26:37Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.41.4</generator>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=Model&amp;diff=206</id>
		<title>Model</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=Model&amp;diff=206"/>
		<updated>2026-02-07T18:12:40Z</updated>

		<summary type="html">&lt;p&gt;Anders: /* Functions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:ModelExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Inheritance==&lt;br /&gt;
[[SceneNode]]&lt;br /&gt;
&lt;br /&gt;
==Static functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|[[Model]]&lt;br /&gt;
|[[Model:new()|new]]()&lt;br /&gt;
|Create a new Instance of the the Model&lt;br /&gt;
|-&lt;br /&gt;
|[[Model]]&lt;br /&gt;
|[[Model:new(Model model)|new]]([[Model]] model)&lt;br /&gt;
|Create a new Instance of the the Model&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[Mesh:getNumMesh()|getNumMesh]]()&lt;br /&gt;
|Get num meshes.&lt;br /&gt;
|-&lt;br /&gt;
|[[Mesh]]&lt;br /&gt;
|[[Mesh:getMesh(string name)|getMesh]]([[string]] name)&lt;br /&gt;
|get [[mesh]] by name.&lt;br /&gt;
|-&lt;br /&gt;
|[[Mesh]]&lt;br /&gt;
|[[Mesh:getMesh(int index)|getMesh]](int index)&lt;br /&gt;
|Get [[mesh]] by index.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Mesh:getCollisionEnabled()|getCollisionEnabled]]()&lt;br /&gt;
|Get is collision enambled&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Mesh:getHeight()|getHeight]]()&lt;br /&gt;
|Get an approximated height of the model.&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Mesh:getFileName()|getFileName]]()&lt;br /&gt;
|Get the models [[file]] name.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Mesh:getVisible()|getVisible]]()&lt;br /&gt;
|Get if the model is visible.&lt;br /&gt;
|-&lt;br /&gt;
|[[AnimationManager]]&lt;br /&gt;
|[[Mesh:getAnimation()|getAnimation]]()&lt;br /&gt;
|Get if the models animation manager.&lt;br /&gt;
|-&lt;br /&gt;
|[[Box]]&lt;br /&gt;
|[[Mesh:getGlobalModelBounds()|getGlobalModelBounds]]()&lt;br /&gt;
|Get models current existing vertex bounds;&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Mesh:setCollisionEnabled(bool enable)|setCollisionEnabled]](bool enable)&lt;br /&gt;
|Set is collision enambled&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Mesh:setColor(Vec3 color)|setColor]]([[Vec3]] color)&lt;br /&gt;
|Set is model color.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Mesh:setColor(Vec4 color)|setColor]]([[Vec4]] color)&lt;br /&gt;
|Set is model color.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Mesh:setRenderLevel(int renderLevel)|setRenderLevel]](int renderLevel)&lt;br /&gt;
|Set render Level [0-32].&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Mesh:rotate(Vec3 axis, float rad)|rotate]]([[Vec3]] axis, float rad)&lt;br /&gt;
|roate around axis.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Mesh:rotateAroundPoint(Vec3 axis, Vec3 point, float rad)|rotateAroundPoint]]([[Vec3]] axis, [[Vec3]] point, float rad)&lt;br /&gt;
|roate around a given point on the given axis.&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=NodeId&amp;diff=205</id>
		<title>NodeId</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=NodeId&amp;diff=205"/>
		<updated>2026-02-07T18:01:33Z</updated>

		<summary type="html">&lt;p&gt;Anders: /* Enum */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:NodeIdExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Enum==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|Name&lt;br /&gt;
!|Value&lt;br /&gt;
!|Description&lt;br /&gt;
|-&lt;br /&gt;
|sceneNode&lt;br /&gt;
|0&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|renderNode&lt;br /&gt;
|1&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|camera&lt;br /&gt;
|2&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|nodeMesh&lt;br /&gt;
|5&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|light&lt;br /&gt;
|7&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|fileNode&lt;br /&gt;
|9&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|playerNode&lt;br /&gt;
|10&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|particleSystem&lt;br /&gt;
|13&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|ropeBridge&lt;br /&gt;
|15&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|island&lt;br /&gt;
|21&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|islandEdge&lt;br /&gt;
|23&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|islandMesh&lt;br /&gt;
|24&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|navMesh&lt;br /&gt;
|25&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|model&lt;br /&gt;
|26&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|mesh&lt;br /&gt;
|27&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|animatedMesh&lt;br /&gt;
|28&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|ambientLight&lt;br /&gt;
|41&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|directionalLight&lt;br /&gt;
|42&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|pointLight&lt;br /&gt;
|43&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|soulManager&lt;br /&gt;
|38&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|buildNode&lt;br /&gt;
|50&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|toolManager&lt;br /&gt;
|51&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|graphicParticleSystem&lt;br /&gt;
|53&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|collisionMesh&lt;br /&gt;
|54&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Static functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Core:getNameFromNodeId(NodeId id)|getNameFromNodeId]]([[NodeId]] id)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=Camera&amp;diff=204</id>
		<title>Camera</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=Camera&amp;diff=204"/>
		<updated>2026-02-01T18:56:04Z</updated>

		<summary type="html">&lt;p&gt;Anders: /* Functions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:CameraExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Inheritance==&lt;br /&gt;
[[SceneNode]]&lt;br /&gt;
&lt;br /&gt;
==Static functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Camera:new()|new]]()&lt;br /&gt;
|Create a new Instance of the the Camera&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Camera:new(Text nodeName)|new]]([[Text]] nodeName)&lt;br /&gt;
|Create a new Instance of the the Camera&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Camera:new(Text nodeName, bool canRender3D)|new]]([[Text]] nodeName, bool canRender3D)&lt;br /&gt;
|Create a new Instance of the the Camera&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Camera:new(Text nodeName, bool canRender3D, int frameBufferWidth, int frameBufferHeight)|new]]([[Text]] nodeName, bool canRender3D, int frameBufferWidth, int frameBufferHeight)&lt;br /&gt;
|Create a new Instance of the the Camera&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Camera:new(string nodeName)|new]](string nodeName)&lt;br /&gt;
|Create a new Instance of the the Camera&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Camera:new(string nodeName, bool canRender3D)|new]](string nodeName, bool canRender3D)&lt;br /&gt;
|Create a new Instance of the the Camera&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Camera:new(string nodeName, bool canRender3D, int frameBufferWidth, int frameBufferHeight)|new]](string nodeName, bool canRender3D, int frameBufferWidth, int frameBufferHeight)&lt;br /&gt;
|Create a new Instance of the the Camera&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec3]]&lt;br /&gt;
|[[Camera:getAtVec()|getAtVec]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec3]]&lt;br /&gt;
|[[Camera:getUpVec()|getUpVec]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec3]]&lt;br /&gt;
|[[Camera:getRightVec()|getRightVec]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|{SceneNode()}&lt;br /&gt;
|[[Camera:getAllNodeByTypeInView(NodeId type)|getAllNodeByTypeInView]]([[NodeId]] type)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|{SceneNode()}&lt;br /&gt;
|[[Camera:getAllNodeByTypeInViewFromNode(SceneNode node, NodeId type)|getAllNodeByTypeInViewFromNode]]([[SceneNode]] node, [[NodeId]] type)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Line3D]]&lt;br /&gt;
|[[Camera:getWorldLineFromScreen(Vec2 pos)|getWorldLineFromScreen]]([[Vec2]] pos)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Texture]]&lt;br /&gt;
|[[Camera:getTexture()|getTexture]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[AmbientLight]]&lt;br /&gt;
|[[Camera:getAmbientLight()|getAmbientLight]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[DirectionalLight]]&lt;br /&gt;
|[[Camera:getDirectionLight()|getDirectionLight]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2]]&lt;br /&gt;
|[[Camera:getScreenCoordFromglobalPos(Vec3 globalPosition)|getScreenCoordFromglobalPos]]([[Vec3]] globalPosition)&lt;br /&gt;
|Get screen coordinates from a global position.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2]]&lt;br /&gt;
|[[Camera:getResolution()|getResolution]]()&lt;br /&gt;
|Get the screen resolution of this camera.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Camera:getDynamicLightsEnable()|getDynamicLightsEnable]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Camera:getVisibleInCamera()|getVisibleInCamera]]()&lt;br /&gt;
|Returns true if the node was visible for a camera.&lt;br /&gt;
|-&lt;br /&gt;
|[[Shader]]&lt;br /&gt;
|[[Camera:getDefferRenderShader()|getDefferRenderShader]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setActive(bool active)|setActive]](bool active)&lt;br /&gt;
|Set if the camera should be active, if deactivated the camera will not be sent of to render&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setDefferRenderShader(Shader defferedShader)|setDefferRenderShader]]([[Shader]] defferedShader)&lt;br /&gt;
|Set the shader that will make the final render from deferred buffers to one buffer.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:render()|render]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setLocalMatrix(Matrix mat)|setLocalMatrix]]([[Matrix]] mat)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setLocalPosition(Vec3 position)|setLocalPosition]]([[Vec3]] position)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setUseShadow(bool enable)|setUseShadow]](bool enable)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setUseGlow(bool enable)|setUseGlow]](bool enable)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setUseAntiAliasing(bool enable)|setUseAntiAliasing]](bool enable)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setUseSelectedRender(bool enable)|setUseSelectedRender]](bool enable)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setDynamicLightsEnable(bool enable)|setDynamicLightsEnable]](bool enable)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setClearColor(Vec4 clearColor)|setClearColor]]([[Vec4]] clearColor)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setShadowScale(float scale)|setShadowScale]](float scale)&lt;br /&gt;
|Cameras shadow map is of the same size as the camera resolution but this can be changed by a scalar with this function.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setAmbientLight(AmbientLight light)|setAmbientLight]]([[AmbientLight]] light)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setDirectionLight(DirectionalLight light)|setDirectionLight]]([[DirectionalLight]] light)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setFrameBufferSize(Vec2i size)|setFrameBufferSize]]([[Vec2i]] size)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setRenderScript(string scriptName)|setRenderScript]](string scriptName)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:add2DScene(Scene2DNode scene2DNode)|add2DScene]]([[Scene2DNode]] scene2DNode)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:disableRenderLayer(int renderLayer)|disableRenderLayer]](int renderLayer)&lt;br /&gt;
|Disable Render Layer To be renderd&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:enableAllRenderLayers()|enableAllRenderLayers]]()&lt;br /&gt;
|Enable All Render Layers&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Camera:saveScreenshot(string fileName)|saveScreenshot]](string fileName)&lt;br /&gt;
|return true if the image was successfully saved to file. Cameras rendering directly to screen can not save a screenshot. &lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Camera:remove2DScene(Scene2DNode scene2DNode)|remove2DScene]]([[Scene2DNode]] scene2DNode)&lt;br /&gt;
|return true if the scene2DNode was removed.&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=Camera&amp;diff=203</id>
		<title>Camera</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=Camera&amp;diff=203"/>
		<updated>2026-02-01T18:27:19Z</updated>

		<summary type="html">&lt;p&gt;Anders: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:CameraExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Inheritance==&lt;br /&gt;
[[SceneNode]]&lt;br /&gt;
&lt;br /&gt;
==Static functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Camera:new()|new]]()&lt;br /&gt;
|Create a new Instance of the the Camera&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Camera:new(Text nodeName)|new]]([[Text]] nodeName)&lt;br /&gt;
|Create a new Instance of the the Camera&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Camera:new(Text nodeName, bool canRender3D)|new]]([[Text]] nodeName, bool canRender3D)&lt;br /&gt;
|Create a new Instance of the the Camera&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Camera:new(Text nodeName, bool canRender3D, int frameBufferWidth, int frameBufferHeight)|new]]([[Text]] nodeName, bool canRender3D, int frameBufferWidth, int frameBufferHeight)&lt;br /&gt;
|Create a new Instance of the the Camera&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Camera:new(string nodeName)|new]](string nodeName)&lt;br /&gt;
|Create a new Instance of the the Camera&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Camera:new(string nodeName, bool canRender3D)|new]](string nodeName, bool canRender3D)&lt;br /&gt;
|Create a new Instance of the the Camera&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Camera:new(string nodeName, bool canRender3D, int frameBufferWidth, int frameBufferHeight)|new]](string nodeName, bool canRender3D, int frameBufferWidth, int frameBufferHeight)&lt;br /&gt;
|Create a new Instance of the the Camera&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec3]]&lt;br /&gt;
|[[Camera:getAtVec()|getAtVec]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec3]]&lt;br /&gt;
|[[Camera:getUpVec()|getUpVec]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec3]]&lt;br /&gt;
|[[Camera:getRightVec()|getRightVec]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|{SceneNode()}&lt;br /&gt;
|[[Camera:getAllNodeByTypeInView(NodeId type)|getAllNodeByTypeInView]]([[NodeId]] type)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|{SceneNode()}&lt;br /&gt;
|[[Camera:getAllNodeByTypeInViewFromNode(SceneNode node, NodeId type)|getAllNodeByTypeInViewFromNode]]([[SceneNode]] node, [[NodeId]] type)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Line3D]]&lt;br /&gt;
|[[Camera:getWorldLineFromScreen(Vec2 pos)|getWorldLineFromScreen]]([[Vec2]] pos)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Texture]]&lt;br /&gt;
|[[Camera:getTexture()|getTexture]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[AmbientLight]]&lt;br /&gt;
|[[Camera:getAmbientLight()|getAmbientLight]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[DirectionalLight]]&lt;br /&gt;
|[[Camera:getDirectionLight()|getDirectionLight]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2]]&lt;br /&gt;
|[[Camera:getScreenCoordFromglobalPos(Vec3 globalPosition)|getScreenCoordFromglobalPos]]([[Vec3]] globalPosition)&lt;br /&gt;
|Get screen coordinates from a global position.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2]]&lt;br /&gt;
|[[Camera:getResolution()|getResolution]]()&lt;br /&gt;
|Get the screen resolution of this camera.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Camera:getDynamicLightsEnable()|getDynamicLightsEnable]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Camera:getVisibleInCamera()|getVisibleInCamera]]()&lt;br /&gt;
|Returns true if the node was visible for a camera.&lt;br /&gt;
|-&lt;br /&gt;
|[[Shader]]&lt;br /&gt;
|[[Camera:getDefferRenderShader()|getDefferRenderShader]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setActive(bool active)|setActive]](bool active)&lt;br /&gt;
|Set if the camera should be active, if deactivated the camera will not be sent of to render&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setDefferRenderShader(Shader defferedShader)|setDefferRenderShader]]([[Shader]] defferedShader)&lt;br /&gt;
|Set the shader that will make the final render from deferred buffers to one buffer.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:render()|render]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setLocalMatrix(Matrix mat)|setLocalMatrix]]([[Matrix]] mat)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setLocalPosition(Vec3 position)|setLocalPosition]]([[Vec3]] position)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setUseShadow(bool enable)|setUseShadow]](bool enable)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setUseGlow(bool enable)|setUseGlow]](bool enable)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setUseAntiAliasing(bool enable)|setUseAntiAliasing]](bool enable)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setUseSelectedRender(bool enable)|setUseSelectedRender]](bool enable)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setDynamicLightsEnable(bool enable)|setDynamicLightsEnable]](bool enable)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setClearColor(Vec4 clearColor)|setClearColor]]([[Vec4]] clearColor)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setShadowScale(float scale)|setShadowScale]](float scale)&lt;br /&gt;
|Cameras shadow map is of the same size as the camera resolution but this can be changed by a scalar with this function.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setAmbientLight(AmbientLight light)|setAmbientLight]]([[AmbientLight]] light)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setDirectionLight(DirectionalLight light)|setDirectionLight]]([[DirectionalLight]] light)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setFrameBufferSize(Vec2i size)|setFrameBufferSize]]([[Vec2i]] size)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setRenderScript(string scriptName)|setRenderScript]](string scriptName)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:add2DScene(Scene2DNode scene2DNode)|add2DScene]]([[Scene2DNode]] scene2DNode)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:disableRenderLayer(int renderLayer)|disableRenderLayer]](int renderLayer)&lt;br /&gt;
|Disable Render Layer To be renderd&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Camera:saveScreenshot(string fileName)|saveScreenshot]](string fileName)&lt;br /&gt;
|return true if the image was successfully saved to file. Cameras rendering directly to screen can not save a screenshot. &lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Camera:remove2DScene(Scene2DNode scene2DNode)|remove2DScene]]([[Scene2DNode]] scene2DNode)&lt;br /&gt;
|return true if the scene2DNode was removed.&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=Model&amp;diff=202</id>
		<title>Model</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=Model&amp;diff=202"/>
		<updated>2026-02-01T18:16:45Z</updated>

		<summary type="html">&lt;p&gt;Anders: /* Functions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:ModelExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Inheritance==&lt;br /&gt;
[[SceneNode]]&lt;br /&gt;
&lt;br /&gt;
==Static functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|[[Model]]&lt;br /&gt;
|[[Model:new()|new]]()&lt;br /&gt;
|Create a new Instance of the the Model&lt;br /&gt;
|-&lt;br /&gt;
|[[Model]]&lt;br /&gt;
|[[Model:new(Model model)|new]]([[Model]] model)&lt;br /&gt;
|Create a new Instance of the the Model&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[Mesh:getNumMesh()|getNumMesh]]()&lt;br /&gt;
|Get num meshes.&lt;br /&gt;
|-&lt;br /&gt;
|[[Mesh]]&lt;br /&gt;
|[[Mesh:getMesh(string name)|getMesh]]([[string]] name)&lt;br /&gt;
|get [[mesh]] by name.&lt;br /&gt;
|-&lt;br /&gt;
|[[Mesh]]&lt;br /&gt;
|[[Mesh:getMesh(int index)|getMesh]](int index)&lt;br /&gt;
|Get [[mesh]] by index.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Mesh:getCollisionEnabled()|getCollisionEnabled]]()&lt;br /&gt;
|Get is collision enambled&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Mesh:getHeight()|getHeight]]()&lt;br /&gt;
|Get an approximated height of the model.&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Mesh:getFileName()|getFileName]]()&lt;br /&gt;
|Get the models [[file]] name.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Mesh:getVisible()|getVisible]]()&lt;br /&gt;
|Get if the model is visible.&lt;br /&gt;
|-&lt;br /&gt;
|[[AnimationManager]]&lt;br /&gt;
|[[Mesh:getAnimation()|getAnimation]]()&lt;br /&gt;
|Get if the models animation manager.&lt;br /&gt;
|-&lt;br /&gt;
|[[Box]]&lt;br /&gt;
|[[Mesh:getGlobalModelBounds()|getGlobalModelBounds]]()&lt;br /&gt;
|Get models current existing vertex bounds;&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Mesh:setCollisionEnabled(bool enable)|setCollisionEnabled]](bool enable)&lt;br /&gt;
|Set is collision enambled&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Mesh:setColor(Vec3 color)|setColor]]([[Vec3]] color)&lt;br /&gt;
|Set is model color.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Mesh:setColor(Vec4 color)|setColor]]([[Vec4]] color)&lt;br /&gt;
|Set is model color.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Mesh:setRederLevel(int renderLevel)|setRederLevel]](int renderLevel)&lt;br /&gt;
|Set render Level [0-32].&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Mesh:rotate(Vec3 axis, float rad)|rotate]]([[Vec3]] axis, float rad)&lt;br /&gt;
|roate around axis.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Mesh:rotateAroundPoint(Vec3 axis, Vec3 point, float rad)|rotateAroundPoint]]([[Vec3]] axis, [[Vec3]] point, float rad)&lt;br /&gt;
|roate around a given point on the given axis.&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=Core&amp;diff=201</id>
		<title>Core</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=Core&amp;diff=201"/>
		<updated>2026-01-04T11:27:38Z</updated>

		<summary type="html">&lt;p&gt;Anders: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:CoreExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Static functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setUpdateHz(float hz)|setUpdateHz]](float hz)&lt;br /&gt;
|Sets the update frequency of the script based on in game time. minimum hz that can be set is &amp;gt;0.1 below that it will update every frame&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setUpdateHzRealTime(float hz)|setUpdateHzRealTime]](float hz)&lt;br /&gt;
|Sets the update frequency of the script based on real time. minimum hz that can be set is &amp;gt;0.1 below that it will update every frame&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:skipFrames(int frames)|skipFrames]](int frames)&lt;br /&gt;
|Skip a specified number of frames once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:skipTime(float seconds)|skipTime]](float seconds)&lt;br /&gt;
|Skip a specified time only once. This function needs to be called every time the script want to skip a specified number of frames.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getAverageDeltaTime()|getAverageDeltaTime]]()&lt;br /&gt;
|Get the average delta time over the last 100 frames.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getDeltaTime()|getDeltaTime]]()&lt;br /&gt;
|Get the last frames delta time.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getRealDeltaTime()|getRealDeltaTime]]()&lt;br /&gt;
|Get the last frames delta time without speed factor.&lt;br /&gt;
|-&lt;br /&gt;
|double&lt;br /&gt;
|[[Core:getGameTime()|getGameTime]]()&lt;br /&gt;
|Get time since the program started, with speed factor.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getTime()|getTime]]()&lt;br /&gt;
|Get time since the program started.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getTimeSpeed()|getTimeSpeed]]()&lt;br /&gt;
|Get time speed.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setTimeSpeed(float speed)|setTimeSpeed]](float speed)&lt;br /&gt;
|Set time speed bettwen [0,10], defult is 1.0.&lt;br /&gt;
|-&lt;br /&gt;
|[[FontCharacter]]&lt;br /&gt;
|[[Core:getFontCharacter(String font, int fontHeight, String character)|getFontCharacter]](String font, int fontHeight, String character)&lt;br /&gt;
|Get a font character.&lt;br /&gt;
|-&lt;br /&gt;
|[[SoundHandler]]&lt;br /&gt;
|[[Core:getSoundHandler()|getSoundHandler]]()&lt;br /&gt;
|get sound handler&lt;br /&gt;
|-&lt;br /&gt;
|[[Sound]]&lt;br /&gt;
|[[Core:getSound()|getSound]]()&lt;br /&gt;
|Load [[sound]].&lt;br /&gt;
|-&lt;br /&gt;
|[[Work]]&lt;br /&gt;
|[[Core:getCurrentWork()|getCurrentWork]]()&lt;br /&gt;
|Return the current work.&lt;br /&gt;
|-&lt;br /&gt;
|[[LuaScript]]&lt;br /&gt;
|[[Core:getCurrentLuaScript()|getCurrentLuaScript]]()&lt;br /&gt;
|Returns the the current executing Lua script.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSoundCamera(Camera camera)|setSoundCamera]]([[Camera]] camera)&lt;br /&gt;
|Set to which camera sound will go. This will be removed in the future.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSoundCameraMatrix(Matrix cameraMatrix)|setSoundCameraMatrix]]([[Matrix]] cameraMatrix)&lt;br /&gt;
|Set sound camera matrix. this is only useful when sound camera is set to nil.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setDebug2DCamera(Camera camera)|setDebug2DCamera]]([[Camera]] camera)&lt;br /&gt;
|Set to which camera 2D debug text should be renderd to.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:addDebugLine(Vec3 l1, Vec3 l2, float time, Vec3 color)|addDebugLine]]([[Vec3]] l1, [[Vec3]] l2, float time, [[Vec3]] color)&lt;br /&gt;
|Add debug line.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:addDebugLine(Line3D line, float time, Vec3 color)|addDebugLine]]([[Line3D]] line, float time, [[Vec3]] color)&lt;br /&gt;
|Add debug line.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:addDebugSphere(Sphere sphere, float time, Vec3 color)|addDebugSphere]]([[Sphere]] [[sphere]], float time, [[Vec3]] color)&lt;br /&gt;
|Add debug [[sphere]].&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:addDebugBox(Box box, float time, Vec3 color)|addDebugBox]]([[Box]] [[box]], float time, [[Vec3]] color)&lt;br /&gt;
|Add debug [[box]].&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:clearDebugLines()|clearDebugLines]]()&lt;br /&gt;
|Clear all debug data, this includes lines, Spheres and debugBoxes.&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[Core:getFrameNumber()|getFrameNumber]]()&lt;br /&gt;
|get number of rendered frame sence program started.&lt;br /&gt;
|-&lt;br /&gt;
|[[Model]]&lt;br /&gt;
|[[Core:getModel(string modelName)|getModel]]([[string]] modelName)&lt;br /&gt;
|Load model.&lt;br /&gt;
|-&lt;br /&gt;
|[[Shader]]&lt;br /&gt;
|[[Core:getShader(string shaderName)|getShader]]([[string]] shaderName)&lt;br /&gt;
|Load shader.&lt;br /&gt;
|-&lt;br /&gt;
|[[Shader]]&lt;br /&gt;
|[[Core:getShader(string shaderName, string definition)|getShader]]([[string]] shaderName, string definition)&lt;br /&gt;
|Load shader with one definition.&lt;br /&gt;
|-&lt;br /&gt;
|[[Shader]]&lt;br /&gt;
|[[Core:getShader(string shaderName, table definitions)|getShader]]([[string]] shaderName, [[table]] definitions)&lt;br /&gt;
|Load shader with one definitions.&lt;br /&gt;
|-&lt;br /&gt;
|[[Texture]]&lt;br /&gt;
|[[Core:getTexture(string textureName)|getTexture]]([[string]] textureName)&lt;br /&gt;
|Load texture.&lt;br /&gt;
|-&lt;br /&gt;
|[[Texture]]&lt;br /&gt;
|[[Core:getTexture(File aFile)|getTexture]]([[File]] aFile)&lt;br /&gt;
|Load texture from a file.&lt;br /&gt;
|-&lt;br /&gt;
|[[File]]&lt;br /&gt;
|[[Core:getDataFolder()|getDataFolder]]()&lt;br /&gt;
|Get main folder.&lt;br /&gt;
|-&lt;br /&gt;
|[[File]]&lt;br /&gt;
|[[Core:getDataFolder(string subFolder)|getDataFolder]]([[string]] subFolder)&lt;br /&gt;
|Get sub folder from main folder.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2]]&lt;br /&gt;
|[[Core:getScreenResolution()|getScreenResolution]]()&lt;br /&gt;
|Get screen resolution.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2]]&lt;br /&gt;
|[[Core:getRenderResolution()|getRenderResolution]]()&lt;br /&gt;
|Get render resolution. &lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getRenderScale()|getRenderScale]]()&lt;br /&gt;
|Get render scale. &lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Core:getSteamName()|getSteamName]]()&lt;br /&gt;
|returns the name of the current steam user, if available.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Core:setScriptNetworkId(string name)|setScriptNetworkId]](string name)&lt;br /&gt;
|Sets the network name of this script. returns true on success. [This name should be set by all clients individually]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:requireScriptNetworkIdToRunUpdate(bool set)|requireScriptNetworkIdToRunUpdate]](bool set)&lt;br /&gt;
|If set true, the script will not run &amp;quot;update&amp;quot; until setScriptNetworkId() is set&lt;br /&gt;
|-&lt;br /&gt;
|number&lt;br /&gt;
|[[Core:getPlayerId()|getPlayerId]]()&lt;br /&gt;
|returns the unique player id of the client. to know where he is supossed to be.&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Core:getNetworkName()|getNetworkName]]()&lt;br /&gt;
|returns netName for the current script&lt;br /&gt;
|-&lt;br /&gt;
|[[Client]]&lt;br /&gt;
|[[Core:getNetworkClient()|getNetworkClient]]()&lt;br /&gt;
|Returns the client, using multiple times will return the same client. (There is one client)&lt;br /&gt;
|-&lt;br /&gt;
|[[Server]]&lt;br /&gt;
|[[Core:getNetworkServer()|getNetworkServer]]()&lt;br /&gt;
|Returns the server, using multiple times will return the same server. (There is one server)&lt;br /&gt;
|-&lt;br /&gt;
|{ {name=string(), ip=string(), port=int(), time=int()} }&lt;br /&gt;
|[[Core:getServerList()|getServerList]]()&lt;br /&gt;
|Returns the global serverlist.&lt;br /&gt;
|-&lt;br /&gt;
|{ {name=string(), ip=string(), port=int(), time=int()} }&lt;br /&gt;
|[[Core:getServerList(int time)|getServerList]](int time)&lt;br /&gt;
|Returns the global serverlist. Time is in the format epoch seconds.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Core:isInMultiplayer()|isInMultiplayer]]()&lt;br /&gt;
|Returns true if the client is connected to a server.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Core:isInFullscreen()|isInFullscreen]]()&lt;br /&gt;
|Returns true if in fullscreen mode&lt;br /&gt;
|-&lt;br /&gt;
|number&lt;br /&gt;
|[[Core:getIndexOfNetworkName(string networkName)|getIndexOfNetworkName]](string networkName)&lt;br /&gt;
|Returns the index of the script with the networkName, or 0 if none was found&lt;br /&gt;
|-&lt;br /&gt;
|[[LuaScript]]&lt;br /&gt;
|[[Core:getScriptOfNetworkName(string networkName)|getScriptOfNetworkName]](string networkName)&lt;br /&gt;
|Returns the script that uses the networkName, or nil if none was found&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Core:getNetworkNameOf(object param)|getNetworkNameOf]](object param)&lt;br /&gt;
|Returns the Network name of the script. takes number(index of a script) or a [[LuaScript]]&lt;br /&gt;
|-&lt;br /&gt;
|[[ComUnit]]&lt;br /&gt;
|[[Core:getComUnit()|getComUnit]]()&lt;br /&gt;
|Get screen resolution.&lt;br /&gt;
|-&lt;br /&gt;
|[[bool]]&lt;br /&gt;
|[[Core:existLuaScript(int luaIndex)|existLuaScript]](int luaIndex)&lt;br /&gt;
|Returns true if lua script is running.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getBillboard()|getBillboard]]()&lt;br /&gt;
|Get the billboard for this script.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getBillboard(int luaIndex)|getBillboard]](int luaIndex)&lt;br /&gt;
|Get the billboard for luaIndex.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getBillboard(string name)|getBillboard]]([[string]] name)&lt;br /&gt;
|Get billboard by name.&lt;br /&gt;
|-&lt;br /&gt;
|[[Input]]&lt;br /&gt;
|[[Core:getInput()|getInput]]()&lt;br /&gt;
|Get input.&lt;br /&gt;
|-&lt;br /&gt;
|[[HighScore]]&lt;br /&gt;
|[[Core:getHighScore()|getHighScore]]()&lt;br /&gt;
|Get HighScore.&lt;br /&gt;
|-&lt;br /&gt;
|[[Cursor]]&lt;br /&gt;
|[[Core:getCursor()|getCursor]]()&lt;br /&gt;
|Get cursor.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:stopCore()|stopCore]]()&lt;br /&gt;
|Stop score.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:quitMainMenu()|quitMainMenu]]()&lt;br /&gt;
|If game is in main menu then the game will be shutdown.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:quitToMainMenu()|quitToMainMenu]]()&lt;br /&gt;
|Quit from mapeditor or game to main menu.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:quitToMapeditor()|quitToMapeditor]]()&lt;br /&gt;
|Quit from game to mapeditor.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Core:isInEditor()|isInEditor]]()&lt;br /&gt;
|Return true when in editor or when testing a map from the editor.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:startMap(string fileName)|startMap]]([[string]] fileName)&lt;br /&gt;
|start map with name like fileName=&amp;quot;Data/Map/fil.map&amp;quot;.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:startMultiplayerClonedMaps(string fileName, nil clientIds)|startMultiplayerClonedMaps]](string fileName, nil clientIds)&lt;br /&gt;
|start map with name like fileName=&amp;quot;Data/Map/fil.map&amp;quot;. &lt;br /&gt;
clientIds is a list of all client ids that need a private world to be loaded. example {2,3,4,5} &lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:startMapInDebugMode(string fileName)|startMapInDebugMode]]([[string]] fileName)&lt;br /&gt;
|start map in debug mode with name like fileName=&amp;quot;Data/Map/fil.map&amp;quot;.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:startMapEditor(string fileName)|startMapEditor]]([[string]] fileName)&lt;br /&gt;
|start mapEditor. If fileName is &amp;quot;&amp;quot; then a new map will be created.&lt;br /&gt;
|-&lt;br /&gt;
|[[Panel]]&lt;br /&gt;
|[[Core:getPanelWithKeyboardFocus()|getPanelWithKeyboardFocus]]()&lt;br /&gt;
|Return the curent [[panel]] with keyboard focus.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getGlobalBillboard(string billboardName)|getGlobalBillboard]]([[string]] billboardName)&lt;br /&gt;
|Create or collect the billboard with a given name. The Billboard will exist unit the game shutsdown. The billboardName must be unique or allready exist as a globalBillboard.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getGameSessionBillboard(string billboardName)|getGameSessionBillboard]]([[string]] billboardName)&lt;br /&gt;
|Create or collect the billboard with a given name. The Billboard will exist unit the game current map is shutdown.&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Core:getMainCamera()|getMainCamera]]()&lt;br /&gt;
|Get the main camera.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setMainCamera(Camera mainCamera)|setMainCamera]]([[Camera]] mainCamera)&lt;br /&gt;
|set the main camera.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setRenderScale(float scale)|setRenderScale]](float scale)&lt;br /&gt;
|set the scale factor of the current render resolution. should be between [0.5,2.0]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setRenderResolution(Vec2 resolution)|setRenderResolution]]([[Vec2]] resolution)&lt;br /&gt;
|set Render resolution.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setMaxFrameRate(int maxFrameRate)|setMaxFrameRate]](int maxFrameRate)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:skipRenderFrame()|skipRenderFrame]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setCursor(string cursorFilePath)|setCursor]]([[string]] cursorFilePath)&lt;br /&gt;
|Set the cursor icon. NOTE! must be a *.bmp file.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSounMasterGain(float gain)|setSounMasterGain]](float gain)&lt;br /&gt;
|set sound master gain, gain is between [0,1]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSoundMusicGain(float gain)|setSoundMusicGain]](float gain)&lt;br /&gt;
|set music gain, gain is between [0,1]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSounEffectGain(float gain)|setSounEffectGain]](float gain)&lt;br /&gt;
|set effect gain, gain is between [0,1]&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getSounMasterGain()|getSounMasterGain]]()&lt;br /&gt;
|get sound master gain&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getSounMusicGain()|getSounMusicGain]]()&lt;br /&gt;
|get sound master gain&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getSounEffectGain()|getSounEffectGain]]()&lt;br /&gt;
|get sound master gain&lt;br /&gt;
|-&lt;br /&gt;
|[[Panel]]&lt;br /&gt;
|[[Core:getPanelWithMouseFocus()|getPanelWithMouseFocus]]()&lt;br /&gt;
|get panel with mouse focus.&lt;br /&gt;
|-&lt;br /&gt;
|[[Panel]]&lt;br /&gt;
|[[Core:getPanelWithKeyboardFocus()|getPanelWithKeyboardFocus]]()&lt;br /&gt;
|get panel with mouse focus.&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Core:getMachineId()|getMachineId]]()&lt;br /&gt;
|get the machine ID.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setFullscreen(bool fullscreen)|setFullscreen]](bool fullscreen)&lt;br /&gt;
|Set if we should use fullscreen.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setVsync(bool vSync)|setVsync]](bool vSync)&lt;br /&gt;
|Set if vSyncshould turned od.&lt;br /&gt;
|-&lt;br /&gt;
|[[DirectionalLight]]&lt;br /&gt;
|[[Core:getDirectionalLight(SceneNode node)|getDirectionalLight]]([[SceneNode]] node)&lt;br /&gt;
|get the current direction light&lt;br /&gt;
|-&lt;br /&gt;
|[[AmbientLight]]&lt;br /&gt;
|[[Core:getAmbientLight(SceneNode node)|getAmbientLight]]([[SceneNode]] node)&lt;br /&gt;
|get the current ambientlight&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=SoundHandler&amp;diff=200</id>
		<title>SoundHandler</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=SoundHandler&amp;diff=200"/>
		<updated>2026-01-04T10:42:07Z</updated>

		<summary type="html">&lt;p&gt;Anders: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:SoundHandlerExampleCode}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[SoundHandler:setSoundLimitation(string soundName, float maxSoundPerSecond)|playSound]](string soundName, float maxSoundPerSecond)&lt;br /&gt;
|Set a limit on how many sound can be started every second&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[SoundHandler:playSound(string soundName, float soundLevel, Vec3 position)|playSound]](string soundName, float soundLevel, [[Vec3]] position)&lt;br /&gt;
|Play a sound by name, sound level and a global position&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[SoundHandler:playSound(string soundName, float soundLevel, Vec3 position, bool looping)|playSound]](string soundName, float soundLevel, [[Vec3]] position, bool looping)&lt;br /&gt;
|Play a sound by name, sound level and a global position&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=SoundHandler&amp;diff=199</id>
		<title>SoundHandler</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=SoundHandler&amp;diff=199"/>
		<updated>2026-01-04T10:41:37Z</updated>

		<summary type="html">&lt;p&gt;Anders: Created page with &amp;quot;{{:SoundHandlerExampleCode}}   ==Functions== {| class=&amp;quot;wikitable&amp;quot; !|return !|function !|description |- | |playSound(string soundName, float maxSoundPerSecond) |Set a limit on how many sound can be started every second |- | |playSound(string soundName, float soundLevel, Vec3 position) |Set a limit on how many soun...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:SoundHandlerExampleCode}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[SoundHandler:setSoundLimitation(string soundName, float maxSoundPerSecond)|playSound]](string soundName, float maxSoundPerSecond)&lt;br /&gt;
|Set a limit on how many sound can be started every second&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[SoundHandler:playSound(string soundName, float soundLevel, Vec3 position)|playSound]](string soundName, float soundLevel, [[Vec3]] position)&lt;br /&gt;
|Set a limit on how many sound can be started every second&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[SoundHandler:playSound(string soundName, float soundLevel, Vec3 position, bool looping)|playSound]](string soundName, float soundLevel, [[Vec3]] position, bool looping)&lt;br /&gt;
|Set a limit on how many sound can be started every second&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=Lua&amp;diff=198</id>
		<title>Lua</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=Lua&amp;diff=198"/>
		<updated>2026-01-04T10:37:47Z</updated>

		<summary type="html">&lt;p&gt;Anders: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Lua API documentation&lt;br /&gt;
&lt;br /&gt;
== Class overview ==&lt;br /&gt;
{|cellspacing=&amp;quot;0&amp;quot; cellpadding=&amp;quot;0&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|&#039;&#039;&#039;Nodes&#039;&#039;&#039;&lt;br /&gt;
|&lt;br /&gt;
:&#039;&#039;&#039;Math&#039;&#039;&#039;&lt;br /&gt;
|&lt;br /&gt;
:&#039;&#039;&#039;Form&#039;&#039;&#039;&lt;br /&gt;
|&lt;br /&gt;
:&#039;&#039;&#039;Core&#039;&#039;&#039;&lt;br /&gt;
|&lt;br /&gt;
:&#039;&#039;&#039;Lists&#039;&#039;&#039;&lt;br /&gt;
|&lt;br /&gt;
:&#039;&#039;&#039;Render&#039;&#039;&#039;&lt;br /&gt;
|-&lt;br /&gt;
|valign=&amp;quot;top&amp;quot; width=&amp;quot;160&amp;quot;|&lt;br /&gt;
*[[AmbientLight]]&lt;br /&gt;
*[[AnimationManager]]&lt;br /&gt;
*[[BuildNode]]&lt;br /&gt;
*[[Camera]]&lt;br /&gt;
*[[DirectionalLight]]&lt;br /&gt;
*[[Editor]]&lt;br /&gt;
*[[FileNode]]&lt;br /&gt;
*[[Island]]&lt;br /&gt;
*[[IslandEdge]]&lt;br /&gt;
*[[NavMesh]]&lt;br /&gt;
*[[NodeMesh]]&lt;br /&gt;
*[[NodeMover]]&lt;br /&gt;
*[[Mesh]]&lt;br /&gt;
*[[Model]]&lt;br /&gt;
*[[MeshSplitter]]&lt;br /&gt;
*[[ParticleEffectElectricFlash]]&lt;br /&gt;
*[[ParticleSystem]]&lt;br /&gt;
*[[GraphicParticleSystem]]&lt;br /&gt;
*[[PathListMover]]&lt;br /&gt;
*[[PointLight]]&lt;br /&gt;
*[[PointLightModel]]&lt;br /&gt;
*[[PlayerNode]]&lt;br /&gt;
*[[RenderNode]]&lt;br /&gt;
*[[RootNode]]&lt;br /&gt;
*[[SplittedMesh]]&lt;br /&gt;
*[[SceneNode]]&lt;br /&gt;
*[[SoundSource]]&lt;br /&gt;
*[[SoundNode]]&lt;br /&gt;
*[[PhysicNode]]&lt;br /&gt;
*[[ToolManager]]&lt;br /&gt;
*[[UnstackableList]]&lt;br /&gt;
&lt;br /&gt;
|valign=&amp;quot;top&amp;quot; width=&amp;quot;160&amp;quot;|&lt;br /&gt;
*[[Box]]&lt;br /&gt;
*[[Collision]]&lt;br /&gt;
*[[Frustrum]]&lt;br /&gt;
*[[Line2D]]&lt;br /&gt;
*[[Line3D]]&lt;br /&gt;
*[[math]]&lt;br /&gt;
*[[Matrix]]&lt;br /&gt;
*[[Quat]]&lt;br /&gt;
*[[Random]]&lt;br /&gt;
*[[Sphere]]&lt;br /&gt;
*[[table]]&lt;br /&gt;
*[[Vec2]]&lt;br /&gt;
*[[Vec2i]]&lt;br /&gt;
*[[Vec3]]&lt;br /&gt;
*[[Vec4]]&lt;br /&gt;
&lt;br /&gt;
|valign=&amp;quot;top&amp;quot; width=&amp;quot;160&amp;quot;|&lt;br /&gt;
*[[Alignment]]&lt;br /&gt;
*[[Anchor]]&lt;br /&gt;
*[[Border]]&lt;br /&gt;
*[[DoubleBorder]]&lt;br /&gt;
*[[BorderSize]]&lt;br /&gt;
*[[Button]]&lt;br /&gt;
*[[ButtonStyle]]&lt;br /&gt;
*[[CheckBox]]&lt;br /&gt;
*[[ColorPicker]]&lt;br /&gt;
*[[ComboBox]]&lt;br /&gt;
*[[FallLayout]]&lt;br /&gt;
*[[FileWindow]]&lt;br /&gt;
*[[FlowLayout]]&lt;br /&gt;
*[[FreeFormLayout]]&lt;br /&gt;
*[[FreeFormLine]]&lt;br /&gt;
*[[FreeFormSprite]]&lt;br /&gt;
*[[FreeFormButton]]&lt;br /&gt;
*[[FreeFormButtonDesign]]&lt;br /&gt;
*[[FreeFormLabel]]&lt;br /&gt;
*[[Form]]&lt;br /&gt;
*[[Gradient]]&lt;br /&gt;
*[[GridLayout]]&lt;br /&gt;
*[[Image]]&lt;br /&gt;
*[[ImageLayout]]&lt;br /&gt;
*[[Label]]&lt;br /&gt;
*[[Layout]]&lt;br /&gt;
*[[Node2DMesh]]&lt;br /&gt;
*[[TextNode]]&lt;br /&gt;
*[[ProgressBar]]&lt;br /&gt;
*[[Render2DNode]]&lt;br /&gt;
*[[Scene2DNode]]&lt;br /&gt;
*[[ScrollBar]]&lt;br /&gt;
*[[Slider]]&lt;br /&gt;
*[[Sprite]]&lt;br /&gt;
*[[TextArea]]&lt;br /&gt;
*[[TextField]]&lt;br /&gt;
*[[Panel]]&lt;br /&gt;
*[[PanelSize]]&lt;br /&gt;
*[[PanelSizeType]]&lt;br /&gt;
*[[WorkMonitor]]&lt;br /&gt;
&lt;br /&gt;
|valign=&amp;quot;top&amp;quot; width=&amp;quot;160&amp;quot;|&lt;br /&gt;
*[[Billboard]]&lt;br /&gt;
*[[ComUnit]]&lt;br /&gt;
*[[Config]]&lt;br /&gt;
*[[ConfigItem]]&lt;br /&gt;
*[[Core]]&lt;br /&gt;
*[[Client]]&lt;br /&gt;
*[[Cursor]]&lt;br /&gt;
*[[File]]&lt;br /&gt;
*[[FontCharacter]]&lt;br /&gt;
*[[Global]]&lt;br /&gt;
*[[Input]]&lt;br /&gt;
*[[Key]]&lt;br /&gt;
*[[KeyBind]]&lt;br /&gt;
*[[Language]]&lt;br /&gt;
*[[LightType]]&lt;br /&gt;
*[[Listener]]&lt;br /&gt;
*[[String]]&lt;br /&gt;
*[[LuaScript]]&lt;br /&gt;
*[[LuaComMsgType]]&lt;br /&gt;
*[[LuaWrapper]]&lt;br /&gt;
*[[MouseKey]]&lt;br /&gt;
*[[NodeId]]&lt;br /&gt;
*[[BoundType]]&lt;br /&gt;
*[[PlayMode]]&lt;br /&gt;
*[[QueuedMode]]&lt;br /&gt;
*[[RenderMode]]&lt;br /&gt;
*[[Server]]&lt;br /&gt;
*[[ServerTester]]&lt;br /&gt;
*[[Shader]]&lt;br /&gt;
*[[Sound]]&lt;br /&gt;
*[[SoundType]]&lt;br /&gt;
*[[SoundHandler]]&lt;br /&gt;
*[[Stopwatch]]&lt;br /&gt;
*[[Texture]]&lt;br /&gt;
*[[Text]]&lt;br /&gt;
*[[VertexType]]&lt;br /&gt;
*[[Work]]&lt;br /&gt;
*[[Worker]]&lt;br /&gt;
*[[WrapMode]]&lt;br /&gt;
*[[HighScore]]&lt;br /&gt;
*[[Statistics]]&lt;br /&gt;
&lt;br /&gt;
|valign=&amp;quot;top&amp;quot; width=&amp;quot;160&amp;quot;|&lt;br /&gt;
*[[VectorVec3]]&lt;br /&gt;
*[[VectorVec2]]&lt;br /&gt;
*[[ListSplittedMesh]]&lt;br /&gt;
&lt;br /&gt;
|valign=&amp;quot;top&amp;quot; width=&amp;quot;160&amp;quot;|&lt;br /&gt;
*[[RenderScene]]&lt;br /&gt;
*[[GL]]&lt;br /&gt;
*[[GL_Clear]]&lt;br /&gt;
*[[GL_Blend]]&lt;br /&gt;
*[[GL_BlendEquation]]&lt;br /&gt;
*[[GL_State]]&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=Lua&amp;diff=197</id>
		<title>Lua</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=Lua&amp;diff=197"/>
		<updated>2026-01-04T10:37:23Z</updated>

		<summary type="html">&lt;p&gt;Anders: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Lua API documentation&lt;br /&gt;
&lt;br /&gt;
== Class overview ==&lt;br /&gt;
{|cellspacing=&amp;quot;0&amp;quot; cellpadding=&amp;quot;0&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|&#039;&#039;&#039;Nodes&#039;&#039;&#039;&lt;br /&gt;
|&lt;br /&gt;
:&#039;&#039;&#039;Math&#039;&#039;&#039;&lt;br /&gt;
|&lt;br /&gt;
:&#039;&#039;&#039;Form&#039;&#039;&#039;&lt;br /&gt;
|&lt;br /&gt;
:&#039;&#039;&#039;Core&#039;&#039;&#039;&lt;br /&gt;
|&lt;br /&gt;
:&#039;&#039;&#039;Lists&#039;&#039;&#039;&lt;br /&gt;
|&lt;br /&gt;
:&#039;&#039;&#039;Render&#039;&#039;&#039;&lt;br /&gt;
|-&lt;br /&gt;
|valign=&amp;quot;top&amp;quot; width=&amp;quot;160&amp;quot;|&lt;br /&gt;
*[[AmbientLight]]&lt;br /&gt;
*[[AnimationManager]]&lt;br /&gt;
*[[BuildNode]]&lt;br /&gt;
*[[Camera]]&lt;br /&gt;
*[[DirectionalLight]]&lt;br /&gt;
*[[Editor]]&lt;br /&gt;
*[[FileNode]]&lt;br /&gt;
*[[Island]]&lt;br /&gt;
*[[IslandEdge]]&lt;br /&gt;
*[[NavMesh]]&lt;br /&gt;
*[[NodeMesh]]&lt;br /&gt;
*[[NodeMover]]&lt;br /&gt;
*[[Mesh]]&lt;br /&gt;
*[[Model]]&lt;br /&gt;
*[[MeshSplitter]]&lt;br /&gt;
*[[ParticleEffectElectricFlash]]&lt;br /&gt;
*[[ParticleSystem]]&lt;br /&gt;
*[[GraphicParticleSystem]]&lt;br /&gt;
*[[PathListMover]]&lt;br /&gt;
*[[PointLight]]&lt;br /&gt;
*[[PointLightModel]]&lt;br /&gt;
*[[PlayerNode]]&lt;br /&gt;
*[[RenderNode]]&lt;br /&gt;
*[[RootNode]]&lt;br /&gt;
*[[SplittedMesh]]&lt;br /&gt;
*[[SceneNode]]&lt;br /&gt;
*[[SoundSource]]&lt;br /&gt;
*[[SoundNode]]&lt;br /&gt;
*[[SoundHandler]]&lt;br /&gt;
*[[PhysicNode]]&lt;br /&gt;
*[[ToolManager]]&lt;br /&gt;
*[[UnstackableList]]&lt;br /&gt;
&lt;br /&gt;
|valign=&amp;quot;top&amp;quot; width=&amp;quot;160&amp;quot;|&lt;br /&gt;
*[[Box]]&lt;br /&gt;
*[[Collision]]&lt;br /&gt;
*[[Frustrum]]&lt;br /&gt;
*[[Line2D]]&lt;br /&gt;
*[[Line3D]]&lt;br /&gt;
*[[math]]&lt;br /&gt;
*[[Matrix]]&lt;br /&gt;
*[[Quat]]&lt;br /&gt;
*[[Random]]&lt;br /&gt;
*[[Sphere]]&lt;br /&gt;
*[[table]]&lt;br /&gt;
*[[Vec2]]&lt;br /&gt;
*[[Vec2i]]&lt;br /&gt;
*[[Vec3]]&lt;br /&gt;
*[[Vec4]]&lt;br /&gt;
&lt;br /&gt;
|valign=&amp;quot;top&amp;quot; width=&amp;quot;160&amp;quot;|&lt;br /&gt;
*[[Alignment]]&lt;br /&gt;
*[[Anchor]]&lt;br /&gt;
*[[Border]]&lt;br /&gt;
*[[DoubleBorder]]&lt;br /&gt;
*[[BorderSize]]&lt;br /&gt;
*[[Button]]&lt;br /&gt;
*[[ButtonStyle]]&lt;br /&gt;
*[[CheckBox]]&lt;br /&gt;
*[[ColorPicker]]&lt;br /&gt;
*[[ComboBox]]&lt;br /&gt;
*[[FallLayout]]&lt;br /&gt;
*[[FileWindow]]&lt;br /&gt;
*[[FlowLayout]]&lt;br /&gt;
*[[FreeFormLayout]]&lt;br /&gt;
*[[FreeFormLine]]&lt;br /&gt;
*[[FreeFormSprite]]&lt;br /&gt;
*[[FreeFormButton]]&lt;br /&gt;
*[[FreeFormButtonDesign]]&lt;br /&gt;
*[[FreeFormLabel]]&lt;br /&gt;
*[[Form]]&lt;br /&gt;
*[[Gradient]]&lt;br /&gt;
*[[GridLayout]]&lt;br /&gt;
*[[Image]]&lt;br /&gt;
*[[ImageLayout]]&lt;br /&gt;
*[[Label]]&lt;br /&gt;
*[[Layout]]&lt;br /&gt;
*[[Node2DMesh]]&lt;br /&gt;
*[[TextNode]]&lt;br /&gt;
*[[ProgressBar]]&lt;br /&gt;
*[[Render2DNode]]&lt;br /&gt;
*[[Scene2DNode]]&lt;br /&gt;
*[[ScrollBar]]&lt;br /&gt;
*[[Slider]]&lt;br /&gt;
*[[Sprite]]&lt;br /&gt;
*[[TextArea]]&lt;br /&gt;
*[[TextField]]&lt;br /&gt;
*[[Panel]]&lt;br /&gt;
*[[PanelSize]]&lt;br /&gt;
*[[PanelSizeType]]&lt;br /&gt;
*[[WorkMonitor]]&lt;br /&gt;
&lt;br /&gt;
|valign=&amp;quot;top&amp;quot; width=&amp;quot;160&amp;quot;|&lt;br /&gt;
*[[Billboard]]&lt;br /&gt;
*[[ComUnit]]&lt;br /&gt;
*[[Config]]&lt;br /&gt;
*[[ConfigItem]]&lt;br /&gt;
*[[Core]]&lt;br /&gt;
*[[Client]]&lt;br /&gt;
*[[Cursor]]&lt;br /&gt;
*[[File]]&lt;br /&gt;
*[[FontCharacter]]&lt;br /&gt;
*[[Global]]&lt;br /&gt;
*[[Input]]&lt;br /&gt;
*[[Key]]&lt;br /&gt;
*[[KeyBind]]&lt;br /&gt;
*[[Language]]&lt;br /&gt;
*[[LightType]]&lt;br /&gt;
*[[Listener]]&lt;br /&gt;
*[[String]]&lt;br /&gt;
*[[LuaScript]]&lt;br /&gt;
*[[LuaComMsgType]]&lt;br /&gt;
*[[LuaWrapper]]&lt;br /&gt;
*[[MouseKey]]&lt;br /&gt;
*[[NodeId]]&lt;br /&gt;
*[[BoundType]]&lt;br /&gt;
*[[PlayMode]]&lt;br /&gt;
*[[QueuedMode]]&lt;br /&gt;
*[[RenderMode]]&lt;br /&gt;
*[[Server]]&lt;br /&gt;
*[[ServerTester]]&lt;br /&gt;
*[[Shader]]&lt;br /&gt;
*[[Sound]]&lt;br /&gt;
*[[SoundType]]&lt;br /&gt;
*[[Stopwatch]]&lt;br /&gt;
*[[Texture]]&lt;br /&gt;
*[[Text]]&lt;br /&gt;
*[[VertexType]]&lt;br /&gt;
*[[Work]]&lt;br /&gt;
*[[Worker]]&lt;br /&gt;
*[[WrapMode]]&lt;br /&gt;
*[[HighScore]]&lt;br /&gt;
*[[Statistics]]&lt;br /&gt;
&lt;br /&gt;
|valign=&amp;quot;top&amp;quot; width=&amp;quot;160&amp;quot;|&lt;br /&gt;
*[[VectorVec3]]&lt;br /&gt;
*[[VectorVec2]]&lt;br /&gt;
*[[ListSplittedMesh]]&lt;br /&gt;
&lt;br /&gt;
|valign=&amp;quot;top&amp;quot; width=&amp;quot;160&amp;quot;|&lt;br /&gt;
*[[RenderScene]]&lt;br /&gt;
*[[GL]]&lt;br /&gt;
*[[GL_Clear]]&lt;br /&gt;
*[[GL_Blend]]&lt;br /&gt;
*[[GL_BlendEquation]]&lt;br /&gt;
*[[GL_State]]&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=AnimationManager&amp;diff=196</id>
		<title>AnimationManager</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=AnimationManager&amp;diff=196"/>
		<updated>2026-01-03T10:55:15Z</updated>

		<summary type="html">&lt;p&gt;Anders: /* Functions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:AnimationManagerExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Constructor==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|AnimationManager()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[AnimationManager:update(float deltaTime))|update]](float deltaTime))&lt;br /&gt;
|Update the animation, step animation one frame forward. This is done automatically in [[model]].&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[AnimationManager:stopFade(string name, float time)|stopFade]]([[string]] name, float time)&lt;br /&gt;
|Stop the named animation over the given time.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[AnimationManager:stopFade(float time)|stopFade]](float time)&lt;br /&gt;
|Stop all animation over the given time.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[AnimationManager:stop(string name)|stop]]([[string]] name)&lt;br /&gt;
|Stop the named animation immediately.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[AnimationManager:stop()|stop]]()&lt;br /&gt;
|Stop all animation immediately.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[AnimationManager:rewind(string name)|rewind]]([[string]] name)&lt;br /&gt;
|Set current time of an animation to 0.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[AnimationManager:fastForwardAnimations(float time)|fastForwardAnimations]](float time)&lt;br /&gt;
|moves all animations forward with set amount.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[AnimationManager:isPlaying(string name)|isPlaying]]([[string]] name)&lt;br /&gt;
|Is the named animation playing.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[AnimationManager:isPlaying()|isPlaying]]()&lt;br /&gt;
|Is any animation playing.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[AnimationManager:play(string name, number speed, PlayMode mode)|play]]([[string]] name, number speed, [[PlayMode]] mode)&lt;br /&gt;
|Play the given animation at a fixed speed.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[AnimationManager:blend(string name, float fadeLength, PlayMode mode)|blend]]([[string]] name, float fadeLength, [[PlayMode]] mode)&lt;br /&gt;
|Blend in animation. and stop other animation.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[AnimationManager:crossFade(string name, float fadeLength, PlayMode mode)|crossFade]]([[string]] name, float fadeLength, [[PlayMode]] mode)&lt;br /&gt;
|Blend in animation. ande fade out other animations&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[AnimationManager:crossFadeQueued(string name, float fadeLength, QueuedMode mode, PlayMode mode)|crossFadeQueued]]([[string]] name, float fadeLength, [[QueuedMode]] mode, [[PlayMode]] mode)&lt;br /&gt;
|Blend in animation. ande fade out other animations&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[AnimationManager:play(string name, QueuedMode mode, PlayMode mode)|play]]([[string]] name, [[QueuedMode]] mode, [[PlayMode]] mode)&lt;br /&gt;
|Play the given animation as fast the queueing is done.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec3]]&lt;br /&gt;
|[[AnimationManager:getBonePosition(string name)|getBonePosition]]([[string]] name)&lt;br /&gt;
|Get bone local position from name.&lt;br /&gt;
|-&lt;br /&gt;
|[[Matrix]]&lt;br /&gt;
|[[AnimationManager:getBoneMatrix(string name)|getBoneMatrix]]([[string]] name)&lt;br /&gt;
|Get bone local [[matrix]] from name.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[AnimationManager:getFrameTimeFromClip(string name)|getFrameTimeFromClip]]([[string]] name)&lt;br /&gt;
|Returns the frame the animation is on if it isPlaying(name), or it returns -1&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[AnimationManager:getLengthOfClip(string name)|getLengthOfClip]]([[string]] name)&lt;br /&gt;
|Returns the length of the animation if found, or it returns -1&lt;br /&gt;
|-&lt;br /&gt;
|table&lt;br /&gt;
|[[AnimationManager:getNameListOfClips()|getNameListOfClips]]()&lt;br /&gt;
|Returns a table with the names of all animations&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[AnimationManager:setAnimationSpeed(float animationSpeed)|setAnimationSpeed]](float animationSpeed)&lt;br /&gt;
|Set the animation speed default 1.0&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=Gradient&amp;diff=195</id>
		<title>Gradient</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=Gradient&amp;diff=195"/>
		<updated>2026-01-03T10:34:45Z</updated>

		<summary type="html">&lt;p&gt;Anders: /* Functions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:GradientExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Inheritance==&lt;br /&gt;
[[Render2DNode]]&lt;br /&gt;
&lt;br /&gt;
==Constructor==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|Gradient()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Gradient([[Vec3]] color)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Gradient([[Vec4]] color)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Gradient([[Vec3]] topColor, [[Vec3]] bottomColor)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Gradient([[Vec4]] topColor, [[Vec4]] bottomColor)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Gradient([[Vec3]] topLeftColor, [[Vec3]] topRightColor, [[Vec3]] bottomLeftColor, [[Vec3]] bottomRightColor)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Gradient([[Vec4]] topLeftColor, [[Vec4]] topRightColor, [[Vec4]] bottomLeftColor, [[Vec4]] bottomRightColor)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Gradient:setGradientColor(Vec3 color)|setGradientColor]]([[Vec3]] color)&lt;br /&gt;
|Set Gradient color.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Gradient:setGradientColor(Vec4 color)|setGradientColor]]([[Vec4]] color)&lt;br /&gt;
|Set Gradient color.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Gradient:setGradientColor(Vec3 topColor, Vec3 bottomColor)|setGradientColor]]([[Vec3]] topColor, [[Vec3]] bottomColor)&lt;br /&gt;
|Set Gradient color.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Gradient:setGradientColor(Vec4 topColor, Vec4 bottomColor)|setGradientColor]]([[Vec4]] topColor, [[Vec4]] bottomColor)&lt;br /&gt;
|Set Gradient color.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Gradient:setGradientColor(Vec3 topLeftColor, Vec3 topRightColor, Vec3 bottomLeftColor, Vec3 bottomRightColor)|setGradientColor]]([[Vec3]] topLeftColor, [[Vec3]] topRightColor, [[Vec3]] bottomLeftColor, [[Vec3]] bottomRightColor)&lt;br /&gt;
|Set Gradient color.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Gradient:setGradientColor(Vec4 topLeftColor, Vec4 topRightColor, Vec4 bottomLeftColor, Vec4 bottomRightColor)|setGradientColor]]([[Vec4]] topLeftColor, [[Vec4]] topRightColor, [[Vec4]] bottomLeftColor, [[Vec4]] bottomRightColor)&lt;br /&gt;
|Set Gradient color.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Gradient:setGradientColorsHorizontal(table colorList)|setGradientColorsHorizontal]]([[table]] colorList)&lt;br /&gt;
|Set Gradient color in horizontal mode.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Gradient:setGradientColorsVertical(table colorList)|setGradientColorsVertical]]([[table]] colorList)&lt;br /&gt;
|Set Gradient color in vertical mode.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Gradient:resize(Vec2 offset, Vec2 panelSize)|resize]]([[Vec2 ]] offset, [[Vec2]] panelSize)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=Gradient&amp;diff=194</id>
		<title>Gradient</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=Gradient&amp;diff=194"/>
		<updated>2026-01-03T10:34:24Z</updated>

		<summary type="html">&lt;p&gt;Anders: /* Functions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:GradientExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Inheritance==&lt;br /&gt;
[[Render2DNode]]&lt;br /&gt;
&lt;br /&gt;
==Constructor==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|Gradient()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Gradient([[Vec3]] color)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Gradient([[Vec4]] color)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Gradient([[Vec3]] topColor, [[Vec3]] bottomColor)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Gradient([[Vec4]] topColor, [[Vec4]] bottomColor)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Gradient([[Vec3]] topLeftColor, [[Vec3]] topRightColor, [[Vec3]] bottomLeftColor, [[Vec3]] bottomRightColor)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Gradient([[Vec4]] topLeftColor, [[Vec4]] topRightColor, [[Vec4]] bottomLeftColor, [[Vec4]] bottomRightColor)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Gradient:setGradientColor(Vec3 color)|setGradientColor]]([[Vec3]] color)&lt;br /&gt;
|Set Gradient color.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Gradient:setGradientColor(Vec4 color)|setGradientColor]]([[Vec4]] color)&lt;br /&gt;
|Set Gradient color.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Gradient:setGradientColor(Vec3 topColor, Vec3 bottomColor)|setGradientColor]]([[Vec3]] topColor, [[Vec3]] bottomColor)&lt;br /&gt;
|Set Gradient color.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Gradient:setGradientColor(Vec4 topColor, Vec4 bottomColor)|setGradientColor]]([[Vec4]] topColor, [[Vec4]] bottomColor)&lt;br /&gt;
|Set Gradient color.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Gradient:setGradientColor(Vec3 topLeftColor, Vec3 topRightColor, Vec3 bottomLeftColor, Vec3 bottomRightColor)|setGradientColor]]([[Vec3]] topLeftColor, [[Vec3]] topRightColor, [[Vec3]] bottomLeftColor, [[Vec3]] bottomRightColor)&lt;br /&gt;
|Set Gradient color.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Gradient:setGradientColor(Vec4 topLeftColor, Vec4 topRightColor, Vec4 bottomLeftColor, Vec4 bottomRightColor)|setGradientColor]]([[Vec4]] topLeftColor, [[Vec4]] topRightColor, [[Vec4]] bottomLeftColor, [[Vec4]] bottomRightColor)&lt;br /&gt;
|Set Gradient color.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Gradient:setGradientColorsHorizontal(table colorList)|setGradientColorsHorizontal]]([[table]] colorList)&lt;br /&gt;
|Set Gradient color in horizontal mode.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Gradient:setGradientColorsVertical(table colorList)|setGradientColorsVertical]]([[table]] colorList)&lt;br /&gt;
|Set Gradient color in vertical mode.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Gradient:resize(Vec2 offset, Vec2 panelSize)|resize]]([[Vec4]] topLeftColor, [[Vec2 ]] offset, [[Vec2 ]] panelSize)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=AnimationManager&amp;diff=193</id>
		<title>AnimationManager</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=AnimationManager&amp;diff=193"/>
		<updated>2026-01-01T16:01:34Z</updated>

		<summary type="html">&lt;p&gt;Anders: /* Functions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:AnimationManagerExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Constructor==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|AnimationManager()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[AnimationManager:update(float deltaTime))|update]](float deltaTime))&lt;br /&gt;
|Update the animation, step animation one frame forward. This is done automatically in [[model]].&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[AnimationManager:stopFade(string name, float time)|stopFade]]([[string]] name, float time)&lt;br /&gt;
|Stop the named animation over the given time.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[AnimationManager:stopFade(float time)|stopFade]](float time)&lt;br /&gt;
|Stop all animation over the given time.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[AnimationManager:stop(string name)|stop]]([[string]] name)&lt;br /&gt;
|Stop the named animation immediately.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[AnimationManager:stop()|stop]]()&lt;br /&gt;
|Stop all animation immediately.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[AnimationManager:rewind(string name)|rewind]]([[string]] name)&lt;br /&gt;
|Set current time of an animation to 0.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[AnimationManager:fastForwardAnimations(float time)|fastForwardAnimations]](float time)&lt;br /&gt;
|moves all animations forward with set amount.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[AnimationManager:isPlaying(string name)|isPlaying]]([[string]] name)&lt;br /&gt;
|Is the named animation playing.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[AnimationManager:isPlaying()|isPlaying]]()&lt;br /&gt;
|Is any animation playing.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[AnimationManager:play(string name, number speed, PlayMode mode)|play]]([[string]] name, number speed, [[PlayMode]] mode)&lt;br /&gt;
|Play the given animation at a fixed speed.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[AnimationManager:blend(string name, float fadeLength, PlayMode mode)|blend]]([[string]] name, float fadeLength, [[PlayMode]] mode)&lt;br /&gt;
|Blend in animation. and stop other animation.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[AnimationManager:crossFade(string name, float fadeLength, PlayMode mode)|crossFade]]([[string]] name, float fadeLength, [[PlayMode]] mode)&lt;br /&gt;
|Blend in animation. ande fade out other animations&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[AnimationManager:crossFadeQueued(string name, float fadeLength, QueuedMode mode, PlayMode mode)|crossFadeQueued]]([[string]] name, float fadeLength, [[QueuedMode]] mode, [[PlayMode]] mode)&lt;br /&gt;
|Blend in animation. ande fade out other animations&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[AnimationManager:play(string name, QueuedMode mode, PlayMode mode)|play]]([[string]] name, [[QueuedMode]] mode, [[PlayMode]] mode)&lt;br /&gt;
|Play the given animation as fast the queueing is done.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec3]]&lt;br /&gt;
|[[AnimationManager:getBonePosition(string name)|getBonePosition]]([[string]] name)&lt;br /&gt;
|Get bone local position from name.&lt;br /&gt;
|-&lt;br /&gt;
|[[Matrix]]&lt;br /&gt;
|[[AnimationManager:getBoneMatrix(string name)|getBoneMatrix]]([[string]] name)&lt;br /&gt;
|Get bone local [[matrix]] from name.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[AnimationManager:getFrameTimeFromClip(string name)|getFrameTimeFromClip]]([[string]] name)&lt;br /&gt;
|Returns the frame the animation is on if it isPlaying(name), or it returns -1&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[AnimationManager:getLengthOfClip(string name)|getLengthOfClip]]([[string]] name)&lt;br /&gt;
|Returns the length of the animation if found, or it returns -1&lt;br /&gt;
|-&lt;br /&gt;
|table&lt;br /&gt;
|[[AnimationManager:getNameListOfClips()|getNameListOfClips]]()&lt;br /&gt;
|Returns a table with the names of all animations&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[AnimationManager:animationSpeed(float animationSpeed)|animationSpeed]](float animationSpeed)&lt;br /&gt;
|Set the animation speed default 1.0&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=Form&amp;diff=192</id>
		<title>Form</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=Form&amp;diff=192"/>
		<updated>2025-08-24T17:38:31Z</updated>

		<summary type="html">&lt;p&gt;Anders: /* Constructor */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:FormExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Inheritance==&lt;br /&gt;
[[Panel]]&lt;br /&gt;
&lt;br /&gt;
==Constructor==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|Form([[Camera]] camera, [[PanelSize]] size, string formName)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Form([[Camera]] camera, [[PanelSize]] size, [[Alignment]] align, string formName)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Form:destroy()|destroy]]()&lt;br /&gt;
|Destroy the form and all children.&lt;br /&gt;
|-&lt;br /&gt;
|[[Work]]&lt;br /&gt;
|[[Form:getWorkUpdater()|getWorkUpdater]]()&lt;br /&gt;
|Get the form last work handler.&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[Form:getRenderLevel()|getRenderLevel]]()&lt;br /&gt;
|Get the forms render level.&lt;br /&gt;
|-&lt;br /&gt;
|[[Alignment]]&lt;br /&gt;
|[[Form:getAlignment()|getAlignment]]()&lt;br /&gt;
|Get alignment.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Form:setAlignment(Alignment align)|setAlignment]]([[Alignment]] align)&lt;br /&gt;
|Set form alignment.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Form:setFormOffset(PanelSize size)|setFormOffset]]([[PanelSize]] size)&lt;br /&gt;
|Set form offset.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Form:setRenderLevel(int renderLevel)|setRenderLevel]](int renderLevel)&lt;br /&gt;
|Set a render level 0 i default. use same render level for none overlaping forms.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Form:update()|update]]()&lt;br /&gt;
|Update form.&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Static functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Form:getDoesAnyFormNeedReRender()|getDoesAnyFormNeedReRender]]()&lt;br /&gt;
|Get if the form need to be renderd.&lt;br /&gt;
|-&lt;br /&gt;
|{Form()}&lt;br /&gt;
|[[Form:getAllFormFromCamera(Camera camera)|getAllFormFromCamera]]([[Camera]] camera)&lt;br /&gt;
|Get all form from camera.&lt;br /&gt;
|-&lt;br /&gt;
|[[Panel]]&lt;br /&gt;
|[[Form:getPanelFromGlobalPos(Vec2 globalPos)|getPanelFromGlobalPos]]([[Vec2]] globalPos)&lt;br /&gt;
|Get all form from camera.&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=FormExampleCode&amp;diff=191</id>
		<title>FormExampleCode</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=FormExampleCode&amp;diff=191"/>
		<updated>2025-08-24T17:37:54Z</updated>

		<summary type="html">&lt;p&gt;Anders: /* Example Code */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Example Code==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
--this = SceneNode()&lt;br /&gt;
function destroy()&lt;br /&gt;
	--clear form&lt;br /&gt;
	form:destroy()&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function create()&lt;br /&gt;
	--Get the camera wich the form will be renderd to.&lt;br /&gt;
	local camera = this:getRootNode():findNodeByName(&amp;quot;MainCamera&amp;quot;)&lt;br /&gt;
	--Check if the camera exist.&lt;br /&gt;
	if camera then&lt;br /&gt;
		--create a form window of size 20% screen width and 20% screen height.&lt;br /&gt;
		form = Form(camera, PanelSize(Vec2(0.2,0.2), &amp;quot;form-name&amp;quot;))&lt;br /&gt;
		--Set layout default is FlowLayout.&lt;br /&gt;
		form:setLayout(FallLayout())&lt;br /&gt;
		--Set background color red.&lt;br /&gt;
		form:setBackground(Sprite(Vec4(1,0,0,1)))&lt;br /&gt;
		&lt;br /&gt;
		--Allign form to top left.&lt;br /&gt;
		form:setAlignment(Alignment.TOP_LEFT)&lt;br /&gt;
		--Set offset from upper left corner to 200 pixel.&lt;br /&gt;
		form:setFormOffset(PanelSize(Vec2(200,200), PanelSizeType.Pixel))	&lt;br /&gt;
	end&lt;br /&gt;
        return true&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function update()&lt;br /&gt;
	form:update()&lt;br /&gt;
	return true&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=Camera&amp;diff=190</id>
		<title>Camera</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=Camera&amp;diff=190"/>
		<updated>2025-08-19T05:45:48Z</updated>

		<summary type="html">&lt;p&gt;Anders: /* Functions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:CameraExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Inheritance==&lt;br /&gt;
[[SceneNode]]&lt;br /&gt;
&lt;br /&gt;
==Static functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Camera:new()|new]]()&lt;br /&gt;
|Create a new Instance of the the Camera&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Camera:new(Text nodeName)|new]]([[Text]] nodeName)&lt;br /&gt;
|Create a new Instance of the the Camera&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Camera:new(Text nodeName, bool canRender3D)|new]]([[Text]] nodeName, bool canRender3D)&lt;br /&gt;
|Create a new Instance of the the Camera&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Camera:new(Text nodeName, bool canRender3D, int frameBufferWidth, int frameBufferHeight)|new]]([[Text]] nodeName, bool canRender3D, int frameBufferWidth, int frameBufferHeight)&lt;br /&gt;
|Create a new Instance of the the Camera&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Camera:new(string nodeName)|new]](string nodeName)&lt;br /&gt;
|Create a new Instance of the the Camera&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Camera:new(string nodeName, bool canRender3D)|new]](string nodeName, bool canRender3D)&lt;br /&gt;
|Create a new Instance of the the Camera&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Camera:new(string nodeName, bool canRender3D, int frameBufferWidth, int frameBufferHeight)|new]](string nodeName, bool canRender3D, int frameBufferWidth, int frameBufferHeight)&lt;br /&gt;
|Create a new Instance of the the Camera&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec3]]&lt;br /&gt;
|[[Camera:getAtVec()|getAtVec]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec3]]&lt;br /&gt;
|[[Camera:getUpVec()|getUpVec]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec3]]&lt;br /&gt;
|[[Camera:getRightVec()|getRightVec]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|{SceneNode()}&lt;br /&gt;
|[[Camera:getAllNodeByTypeInView(NodeId type)|getAllNodeByTypeInView]]([[NodeId]] type)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|{SceneNode()}&lt;br /&gt;
|[[Camera:getAllNodeByTypeInViewFromNode(SceneNode node, NodeId type)|getAllNodeByTypeInViewFromNode]]([[SceneNode]] node, [[NodeId]] type)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Line3D]]&lt;br /&gt;
|[[Camera:getWorldLineFromScreen(Vec2 pos)|getWorldLineFromScreen]]([[Vec2]] pos)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Texture]]&lt;br /&gt;
|[[Camera:getTexture()|getTexture]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[AmbientLight]]&lt;br /&gt;
|[[Camera:getAmbientLight()|getAmbientLight]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[DirectionalLight]]&lt;br /&gt;
|[[Camera:getDirectionLight()|getDirectionLight]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2]]&lt;br /&gt;
|[[Camera:getScreenCoordFromglobalPos(Vec3 globalPosition)|getScreenCoordFromglobalPos]]([[Vec3]] globalPosition)&lt;br /&gt;
|Get screen coordinates from a global position.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2]]&lt;br /&gt;
|[[Camera:getResolution()|getResolution]]()&lt;br /&gt;
|Get the screen resolution of this camera.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Camera:getDynamicLightsEnable()|getDynamicLightsEnable]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Camera:getVisibleInCamera()|getVisibleInCamera]]()&lt;br /&gt;
|Returns true if the node was visible for a camera.&lt;br /&gt;
|-&lt;br /&gt;
|[[Shader]]&lt;br /&gt;
|[[Camera:getDefferRenderShader()|getDefferRenderShader]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setActive(bool active)|setActive]](bool active)&lt;br /&gt;
|Set if the camera should be active, if deactivated the camera will not be sent of to render&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setDefferRenderShader(Shader defferedShader)|setDefferRenderShader]]([[Shader]] defferedShader)&lt;br /&gt;
|Set the shader that will make the final render from deferred buffers to one buffer.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:render()|render]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setLocalMatrix(Matrix mat)|setLocalMatrix]]([[Matrix]] mat)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setLocalPosition(Vec3 position)|setLocalPosition]]([[Vec3]] position)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setUseShadow(bool enable)|setUseShadow]](bool enable)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setUseGlow(bool enable)|setUseGlow]](bool enable)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setUseAntiAliasing(bool enable)|setUseAntiAliasing]](bool enable)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setUseSelectedRender(bool enable)|setUseSelectedRender]](bool enable)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setDynamicLightsEnable(bool enable)|setDynamicLightsEnable]](bool enable)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setClearColor(Vec4 clearColor)|setClearColor]]([[Vec4]] clearColor)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setShadowScale(float scale)|setShadowScale]](float scale)&lt;br /&gt;
|Cameras shadow map is of the same size as the camera resolution but this can be changed by a scalar with this function.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setAmbientLight(AmbientLight light)|setAmbientLight]]([[AmbientLight]] light)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setDirectionLight(DirectionalLight light)|setDirectionLight]]([[DirectionalLight]] light)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setFrameBufferSize(Vec2i size)|setFrameBufferSize]]([[Vec2i]] size)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setRenderScript(string scriptName)|setRenderScript]](string scriptName)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:add2DScene(Scene2DNode scene2DNode)|add2DScene]]([[Scene2DNode]] scene2DNode)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Camera:saveScreenshot(string fileName)|saveScreenshot]](string fileName)&lt;br /&gt;
|return true if the image was successfully saved to file. Cameras rendering directly to screen can not save a screenshot. &lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Camera:remove2DScene(Scene2DNode scene2DNode)|remove2DScene]]([[Scene2DNode]] scene2DNode)&lt;br /&gt;
|return true if the scene2DNode was removed.&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=SceneNode&amp;diff=189</id>
		<title>SceneNode</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=SceneNode&amp;diff=189"/>
		<updated>2025-08-12T18:18:59Z</updated>

		<summary type="html">&lt;p&gt;Anders: /* Functions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:SceneNodeExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Static functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|[[SceneNode]]&lt;br /&gt;
|[[SceneNode:new()|new]]()&lt;br /&gt;
|Create a new Instance of the the SceneNode&lt;br /&gt;
|-&lt;br /&gt;
|[[SceneNode]]&lt;br /&gt;
|[[SceneNode:new(string name)|new]]([[string]] name)&lt;br /&gt;
|Create a new Instance of the the SceneNode&lt;br /&gt;
|-&lt;br /&gt;
|[[SceneNode]]&lt;br /&gt;
|[[SceneNode:newNil()|newNil]]()&lt;br /&gt;
|return a null pointer of type SceneNode&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[SceneNode:destroy()|destroy]]()&lt;br /&gt;
|Destroy this node.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[SceneNode:destroyTree()|destroyTree]]()&lt;br /&gt;
|Destroy this node and all nodes towards leaf nodes.&lt;br /&gt;
This is the only way to a node completely.&lt;br /&gt;
|-&lt;br /&gt;
|[[NodeId]]&lt;br /&gt;
|[[SceneNode:getNodeType()|getNodeType]]()&lt;br /&gt;
|Returns the node id, Check [[NodeId]].&lt;br /&gt;
|-&lt;br /&gt;
|[[SceneNode]]&lt;br /&gt;
|[[SceneNode:toSceneNode()|toSceneNode]]()&lt;br /&gt;
|Converts the pointer to a sceneNode.&lt;br /&gt;
|-&lt;br /&gt;
|[[SceneNode]]&lt;br /&gt;
|[[SceneNode:getRootNode()|getRootNode]]()&lt;br /&gt;
|Returns root node of the scene tree.&lt;br /&gt;
|-&lt;br /&gt;
|[[string]]&lt;br /&gt;
|[[SceneNode:getSceneName()|getSceneName]]()&lt;br /&gt;
|Returns this nodes scene name.&lt;br /&gt;
|-&lt;br /&gt;
|[[SceneNode]]&lt;br /&gt;
|[[SceneNode:getParent()|getParent]]()&lt;br /&gt;
|Returns this nodes parent. If this node is a [[rootNode]] null is returned.&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[SceneNode:getId()|getId]]()&lt;br /&gt;
|Returns this nodes unique id.&lt;br /&gt;
|-&lt;br /&gt;
|[[PlayerNode]]&lt;br /&gt;
|[[SceneNode:getPlayerNode()|getPlayerNode]]()&lt;br /&gt;
|Returns the player node. The player node is only returned if the parent to this node is of the type [[PlayerNode]].&lt;br /&gt;
This should always return a node except when this function is called from [[Camera]] or [[rootNode]]&lt;br /&gt;
|-&lt;br /&gt;
|[[BoundType]]&lt;br /&gt;
|[[SceneNode:getBoundType()|getBoundType]]()&lt;br /&gt;
|Returns the Bounding type.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec3]]&lt;br /&gt;
|[[SceneNode:getGlobalPosition()|getGlobalPosition]]()&lt;br /&gt;
|Returns the [[global]] position.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec3]]&lt;br /&gt;
|[[SceneNode:getLocalPosition()|getLocalPosition]]()&lt;br /&gt;
|Returns the local position.&lt;br /&gt;
|-&lt;br /&gt;
|[[Matrix]]&lt;br /&gt;
|[[SceneNode:getGlobalMatrix()|getGlobalMatrix]]()&lt;br /&gt;
|Returns the [[global]] [[matrix]].&lt;br /&gt;
|-&lt;br /&gt;
|[[Matrix]]&lt;br /&gt;
|[[SceneNode:getLocalMatrix()|getLocalMatrix]]()&lt;br /&gt;
|Returns the local [[matrix]].&lt;br /&gt;
|-&lt;br /&gt;
|[[Box]]&lt;br /&gt;
|[[SceneNode:getGlobalBoundingBox()|getGlobalBoundingBox]]()&lt;br /&gt;
|Returns the [[global]] [[box]].&lt;br /&gt;
|-&lt;br /&gt;
|[[Sphere]]&lt;br /&gt;
|[[SceneNode:getGlobalBoundingSphere()|getGlobalBoundingSphere]]()&lt;br /&gt;
|Returns the [[global]] [[sphere]].&lt;br /&gt;
|-&lt;br /&gt;
|[[LuaScript]]&lt;br /&gt;
|[[SceneNode:getScriptByName(string scriptName)|getScriptByName]]([[string]] scriptName)&lt;br /&gt;
|Returns the script with the given name.&lt;br /&gt;
|-&lt;br /&gt;
|{LuaScript()}&lt;br /&gt;
|[[SceneNode:getAllScript()|getAllScript]]()&lt;br /&gt;
|Return all script from this node.&lt;br /&gt;
|-&lt;br /&gt;
|number&lt;br /&gt;
|[[SceneNode:countAllNodeInTree()|countAllNodeInTree]]()&lt;br /&gt;
|Return a number counting all nodes&lt;br /&gt;
|-&lt;br /&gt;
|[[LuaScript]]&lt;br /&gt;
|[[SceneNode:getCurrentScript()|getCurrentScript]]()&lt;br /&gt;
|Returns the current running script.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[SceneNode:getisUpdatedEnabled()|getisUpdatedEnabled]]()&lt;br /&gt;
|Returns if this node accepts update.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[SceneNode:getVisibleInCamera()|getVisibleInCamera]]()&lt;br /&gt;
|Returns true is this sceneNode was visible in any camera during last frame.&lt;br /&gt;
|-&lt;br /&gt;
|[[Work]]&lt;br /&gt;
|[[SceneNode:getWork()|getWork]]()&lt;br /&gt;
|Returns this nodes worker. &lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[SceneNode:getCollisionEnabled()|getCollisionEnabled]]()&lt;br /&gt;
|Returns true if collision is enabled on this node. &lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[SceneNode:getVisible()|getVisible]]()&lt;br /&gt;
|Returns this nodes visible variable set by setVisible().&lt;br /&gt;
|-&lt;br /&gt;
|{SceneNode()}&lt;br /&gt;
|[[SceneNode:findAllNodeByNameTowardsLeaf(string sceneName)|findAllNodeByNameTowardsLeaf]]([[string]] sceneName)&lt;br /&gt;
|Returns all nodes with the given name towards the leafNodes.&lt;br /&gt;
|-&lt;br /&gt;
|{SceneNode()}&lt;br /&gt;
|[[SceneNode:findAllNodeByNameTowardsLeaf(table sceneNames)|findAllNodeByNameTowardsLeaf]]([[table]] sceneNames)&lt;br /&gt;
|Returns all nodes with the given name towards the leafNodes.&lt;br /&gt;
|-&lt;br /&gt;
|{SceneNode()}&lt;br /&gt;
|[[SceneNode:findAllNodeByNameTowardsRoot(string sceneName)|findAllNodeByNameTowardsRoot]]([[string]] sceneName)&lt;br /&gt;
|Returns all nodes with the given name towards the root node.&lt;br /&gt;
|-&lt;br /&gt;
|{SceneNode()}&lt;br /&gt;
|[[SceneNode:findAllNodeByNameTowardsRoot(table sceneNames)|findAllNodeByNameTowardsRoot]]([[table]] sceneNames)&lt;br /&gt;
|Returns all nodes with the given name towards the root node.&lt;br /&gt;
|-&lt;br /&gt;
|{SceneNode()}&lt;br /&gt;
|[[SceneNode:findAllNodeByTypeTowardsLeaf(NodeId id)|findAllNodeByTypeTowardsLeaf]]([[NodeId]] id)&lt;br /&gt;
|Returns all nodes with the given nodeId towards the leaf node.&lt;br /&gt;
|-&lt;br /&gt;
|{SceneNode()}&lt;br /&gt;
|[[SceneNode:findAllNodeByTypeTowardsLeaf(table idList)|findAllNodeByTypeTowardsLeaf]]([[table]] idList)&lt;br /&gt;
|Returns all nodes with the given nodeIds towards the leaf node.&lt;br /&gt;
|-&lt;br /&gt;
|{SceneNode()}&lt;br /&gt;
|[[SceneNode:getAllNodeByTypeTowardsLeafWithinSphere(NodeId id, Sphere aSphere)|getAllNodeByTypeTowardsLeafWithinSphere]]([[NodeId]] id, [[Sphere]] aSphere)&lt;br /&gt;
|Returns all nodes with the given nodeId within the sphere towards the leaf node.&lt;br /&gt;
|-&lt;br /&gt;
|[[SceneNode]]&lt;br /&gt;
|[[SceneNode:findNodeByName(string sceneName)|findNodeByName]]([[string]] sceneName)&lt;br /&gt;
|Returns the first node with the given name.&lt;br /&gt;
Looks first towards the leafNodes then look toward the root node&lt;br /&gt;
|-&lt;br /&gt;
|[[SceneNode]]&lt;br /&gt;
|[[SceneNode:findNodeByType(NodeId id)|findNodeByType]]([[NodeId]] id)&lt;br /&gt;
|Returns the first node with the given nodeId.&lt;br /&gt;
Looks first towards the leafNodes then look toward the root node&lt;br /&gt;
|-&lt;br /&gt;
|[[SceneNode]]&lt;br /&gt;
|[[SceneNode:findNodeByTypeTowardsLeafe(NodeId id)|findNodeByTypeTowardsLeafe]]([[NodeId]] id)&lt;br /&gt;
|Returns the first node with the given nodeId towards leaf nodes.&lt;br /&gt;
|-&lt;br /&gt;
|[[SceneNode]]&lt;br /&gt;
|[[SceneNode:findNodeByTypeTowardsRoot(NodeId id)|findNodeByTypeTowardsRoot]]([[NodeId]] id)&lt;br /&gt;
|Returns the first node with the given nodeId towards root node.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[SceneNode:setSceneName(string name)|setSceneName]]([[string]] name)&lt;br /&gt;
|Set the name of the sceneNode.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[SceneNode:setLocalMatrix(Matrix mat)|setLocalMatrix]]([[Matrix]] mat)&lt;br /&gt;
|Set local [[matrix]].&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[SceneNode:setLocalPosition(Vec3 position)|setLocalPosition]]([[Vec3]] position)&lt;br /&gt;
|Set local position.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[SceneNode:setVisible(bool visible)|setVisible]](bool visible)&lt;br /&gt;
|Set if node should be visible.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[SceneNode:setParent(SceneNode parent)|setParent]](SceneNode parent)&lt;br /&gt;
|Set the parent.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[SceneNode:setEnableUpdates(bool enabled)|setEnableUpdates]](bool enabled)&lt;br /&gt;
|Set if this node should be updated. if this nodes update is disabeld all children will not ether get updated.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[SceneNode:setCollisionEnabled(bool enabled)|setCollisionEnabled]](bool enabled)&lt;br /&gt;
|Set if this node should have collision enabled, by default all node has collision enabled.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[SceneNode:DisableBoundingVolumesDynamicUpdates()|DisableBoundingVolumesDynamicUpdates]]()&lt;br /&gt;
|changing position rotation and scale should not effect parrent bounding volume. &lt;br /&gt;
This is an optimization for dynamic object that changes it&#039;s local matrix but not actually it&#039;s position.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[SceneNode:setBoundingVolumeCanShrink(bool canShrink)|setBoundingVolumeCanShrink]](bool canShrink)&lt;br /&gt;
|Config the bounding volume never to shrink. this is useful to increase performance on object that may move around internal but have a somewhat constant bounding volume. &lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[SceneNode:createBoundVolumeGroup()|createBoundVolumeGroup]]()&lt;br /&gt;
|Force create a bound volume group.&lt;br /&gt;
|-&lt;br /&gt;
|[[Work]]&lt;br /&gt;
|[[SceneNode:createWork()|createWork]]()&lt;br /&gt;
|create a [[work]] from this node.&lt;br /&gt;
This function is not needed at all. It&#039;s used to make some very specific optimization.&lt;br /&gt;
|-&lt;br /&gt;
|[[SceneNode]]&lt;br /&gt;
|[[SceneNode:collision(Line3D line)|collision]]([[Line3D]] line)&lt;br /&gt;
|Perform [[collision]] against this node. Return this sceneNode if [[collision]] was found.&lt;br /&gt;
|-&lt;br /&gt;
|[[SceneNode]]&lt;br /&gt;
|[[SceneNode:collision(Line3D line, Vec3 normal)|collision]]([[Line3D]] line, [[Vec3]] normal)&lt;br /&gt;
|Perform [[collision]] against this node. Return this sceneNode if [[collision]] was found and the normal of the [[collision]].&lt;br /&gt;
|-&lt;br /&gt;
|[[SceneNode]]&lt;br /&gt;
|[[SceneNode:collisionTree(Line3D line)|collisionTree]]([[Line3D]] line)&lt;br /&gt;
|Perform collision against this node and all nodes towards the leaf nodes. Return the sceneNode from the closest [[collision]]. if no [[collision]] was detected return null.&lt;br /&gt;
|-&lt;br /&gt;
|[[SceneNode]]&lt;br /&gt;
|[[SceneNode:collisionTree(Line3D line, Vec3 normal)|collisionTree]]([[Line3D]] line, [[Vec3]] normal)&lt;br /&gt;
|Perform [[collision]] against this node and all nodes towards the leaf nodes. Return the sceneNode from the closest [[collision]] and the normal. if no [[collision]] was detected return null.&lt;br /&gt;
|-&lt;br /&gt;
|[[SceneNode]]&lt;br /&gt;
|[[SceneNode:collisionTree(Line3D line, NodeId id)|collisionTree]]([[Line3D]] line, [[NodeId]] id)&lt;br /&gt;
|Perform [[collision]] against this node and all towards the leaf nodes with the same [[nodeId]]. Return the sceneNode from the closest [[collision]]. if no [[collision]] was detected return null.&lt;br /&gt;
|-&lt;br /&gt;
|[[SceneNode]]&lt;br /&gt;
|[[SceneNode:collisionTree(Line3D line, table whiteListedNodeIds)|collisionTree]]([[Line3D]] line, table whiteListedNodeIds)&lt;br /&gt;
|Perform collision against this node and all towards the leaf nodes if the NodeId of the sceneNode is contained in the table.&lt;br /&gt;
|-&lt;br /&gt;
|[[SceneNode]]&lt;br /&gt;
|[[SceneNode:collisionTree(Line3D line, Vec3 normal, table whiteListedNodeIds)|collisionTree]]([[Line3D]] line, [[Vec3]] normal, table whiteListedNodeIds)&lt;br /&gt;
|Perform collision against this node and all towards the leaf nodes if the NodeId of the sceneNode is contained in the table.&lt;br /&gt;
|-&lt;br /&gt;
|{SceneNode()}&lt;br /&gt;
|[[SceneNode:collisionTree(Frustrum aFrustrum, table whiteListedNodeIds)|collisionTree]]([[Frustrum]] aFrustruml, table whiteListedNodeIds)&lt;br /&gt;
|Perform collision against this node and all towards the leaf nodes if the NodeId of the sceneNode is contained in the table.&lt;br /&gt;
|-&lt;br /&gt;
|[[SceneNode]]&lt;br /&gt;
|[[SceneNode:addChild(SceneNode child)|addChild]](SceneNode child)&lt;br /&gt;
|Add the node as a child to this one&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[SceneNode:removeChild(SceneNode child)|removeChild]](SceneNode child)&lt;br /&gt;
|Remove the child. Returns true if the child was removed else false. &lt;br /&gt;
|-&lt;br /&gt;
|[[SceneNode]]&lt;br /&gt;
|[[SceneNode:getChildNode(int index)|getChildNode]](int index)&lt;br /&gt;
|Get child by index.&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[SceneNode:getChildSize()|getChildSize]]()&lt;br /&gt;
|Get number of children.&lt;br /&gt;
|-&lt;br /&gt;
|[[SceneNode]]&lt;br /&gt;
|[[SceneNode:getVisibleChildNode(int index)|getVisibleChildNode]](int index)&lt;br /&gt;
|Get visible child by index.&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[SceneNode:getVisibleChildSize()|getVisibleChildSize]]()&lt;br /&gt;
|Get number of visible children.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[SceneNode:getCanBeSaved()|getCanBeSaved]]()&lt;br /&gt;
|Get if the this scene can be saved by the saveScene() function.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[SceneNode:loadLuaScriptAndRunOnce(String scriptName)|loadLuaScriptAndRunOnce]]([[String]] scriptName)&lt;br /&gt;
|Try to load a new script from file and immediately execute the script and then destroy the script.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[SceneNode:loadLuaScriptAndRunOnce(string scriptName)|loadLuaScriptAndRunOnce]]([[string]] scriptName)&lt;br /&gt;
|Try to load a new script from file and immediately execute the script and then destroy the script.&lt;br /&gt;
|-&lt;br /&gt;
|[[LuaScript]]&lt;br /&gt;
|[[SceneNode:loadLuaScript(String scriptName)|loadLuaScript]]([[String]] scriptName)&lt;br /&gt;
|Try to load a new script from file. return null if failed&lt;br /&gt;
|-&lt;br /&gt;
|[[LuaScript]]&lt;br /&gt;
|[[SceneNode:loadLuaScript(string scriptName)|loadLuaScript]](string scriptName)&lt;br /&gt;
|Try to load a new script from file. return null if failed&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[SceneNode:removeScript(String scriptName)|removeScript]]([[String]] scriptName)&lt;br /&gt;
|Removes a script with the given name.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[SceneNode:removeScript(string scriptName)|removeScript]]([[string]] scriptName)&lt;br /&gt;
|Removes a script with the given name.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[SceneNode:update()|update]]()&lt;br /&gt;
|Update node. This function is automatically called by the game if the nood is connected to the main sceneNode.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[SceneNode:setCanBeSaved(bool canBeSaved)|setCanBeSaved]](bool canBeSaved)&lt;br /&gt;
|Set if the this scene can be saved by the saveScene() function.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[SceneNode:saveScene(string fileName)|saveScene]](string fileName)&lt;br /&gt;
|Save the tree hierarchy from this scene node. This will save all nodes and some local state. &lt;br /&gt;
Used to create save and load functionality for map editor.&lt;br /&gt;
This is NOT a in game save functionality.&lt;br /&gt;
|-&lt;br /&gt;
|[[SceneNode]]&lt;br /&gt;
|[[SceneNode:loadScene(string fileName)|loadScene]](string fileName)&lt;br /&gt;
|Load a scene node hierarchy as a child to this node.&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Overloaded returns==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|Parameter&lt;br /&gt;
|-&lt;br /&gt;
|SceneNode&lt;br /&gt;
|findNodeByType&lt;br /&gt;
|id&lt;br /&gt;
|-&lt;br /&gt;
|{SceneNode()}&lt;br /&gt;
|findAllNodeByTypeTowardsLeaf&lt;br /&gt;
|id&lt;br /&gt;
|-&lt;br /&gt;
|SceneNode&lt;br /&gt;
|findNodeByTypeTowardsLeafe&lt;br /&gt;
|id&lt;br /&gt;
|-&lt;br /&gt;
|SceneNode&lt;br /&gt;
|findNodeByTypeTowardsRoot&lt;br /&gt;
|id&lt;br /&gt;
|-&lt;br /&gt;
|{SceneNode()}&lt;br /&gt;
|getAllNodeByTypeTowardsLeafWithinSphere&lt;br /&gt;
|id&lt;br /&gt;
|-&lt;br /&gt;
|SceneNode&lt;br /&gt;
|addChild&lt;br /&gt;
|child&lt;br /&gt;
|-&lt;br /&gt;
|SceneNode&lt;br /&gt;
|[[collision]]&lt;br /&gt;
|id&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=BuildNode&amp;diff=188</id>
		<title>BuildNode</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=BuildNode&amp;diff=188"/>
		<updated>2025-08-05T07:32:55Z</updated>

		<summary type="html">&lt;p&gt;Anders: /* Functions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:BuildNodeNodeExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Inheritance==&lt;br /&gt;
[[SceneNode]]&lt;br /&gt;
&lt;br /&gt;
==Static functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|[[BuildNode]]&lt;br /&gt;
|[[BuildNode:new()|new]]()&lt;br /&gt;
|Create a new Instance of the the BuildNode&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[BuildNode:addPath(SceneNode island1, Vec3 localIslandPosition1, SceneNode island2, Vec3 localIslandPosition2)|addPath]]([[SceneNode]] island1, [[Vec3]] localIslandPosition1, [[SceneNode]] island2, [[Vec3]] localIslandPosition2)&lt;br /&gt;
|Add a protected path that can&#039;t be built ower.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[BuildNode:addProtectedPoint(SceneNode island, Vec3 localIslandPosition)|addProtectedPoint]]([[SceneNode]] island, [[Vec3]] localIslandPosition)&lt;br /&gt;
|Add a protected point where nothinge can be built.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[BuildNode:addProtectedLine(SceneNode island, Vec3 point1, Vec3 point2)|addProtectedLine]]([[SceneNode]] island, [[Vec3]]  point1, [[Vec3]] point2)&lt;br /&gt;
|Add a protected Line on witch no tower can be built.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[BuildNode:addProtectedLine(SceneNode island, line3D localLine)|addProtectedLine]]([[SceneNode]] island, [[Line3D]] localLine)&lt;br /&gt;
|Add a protected Line on witch no tower can be built.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[BuildNode:tryToSnapBuildingInToPlace(SceneNode building, SceneNode collisionNode, Vec3 global pos, float yRotation)|tryToSnapBuildingInToPlace]]([[SceneNode]] building, [[SceneNode]] collisionNode, [[Vec3]] [[global]] pos, float yRotation)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[BuildNode:removeBuilding(SceneNode buildNode)|removeBuilding]]([[SceneNode]] buildNode)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Island]]&lt;br /&gt;
|[[BuildNode:getTargetIsland()|getTargetIsland]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Matrix]]&lt;br /&gt;
|[[BuildNode:getLocalIslandMatrix()|getLocalIslandMatrix]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[SceneNode]]&lt;br /&gt;
|[[BuildNode:TryToBuild()|TryToBuild]]()&lt;br /&gt;
|Return the buildings SceneNode when the building is built else return nil.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[BuildNode:activatePathRender()|activatePathRender]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[BuildNode:clearBuildings()|clearBuildings]]()&lt;br /&gt;
|Try to remove all buildings from the BuildNode. Return true if all buildings was successfully removed.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[BuildNode:sellBuilding(SceneNode buildingNode)|sellBuilding]]([[SceneNode]] buildingNode)&lt;br /&gt;
|Try to sell a building from the BuildNode. Return true if the building was successfully removed.&lt;br /&gt;
|-&lt;br /&gt;
|{SceneNode()}&lt;br /&gt;
|[[BuildNode:getBuildingList()|getBuildingList]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|{SceneNode()}&lt;br /&gt;
|[[BuildNode:getAllBuildingFromPoint(Vec3 position, float radius)|getAllBuildingFromPoint]](Vec3 position, float radius)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[SceneNode]]&lt;br /&gt;
|[[BuildNode:getBuldingFromLine(Line3D line)|getBuldingFromLine]]([[Line3D]] line)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[SceneNode]]&lt;br /&gt;
|[[BuildNode:getNearestBuildingFromLine(Line3D line)|getNearestBuildingFromLine]]([[Line3D]] line)&lt;br /&gt;
|Return the nearest building from the given line. return nil when there is no tower created.&lt;br /&gt;
|-&lt;br /&gt;
|[[Matrix]]&lt;br /&gt;
|[[BuildNode:getCurrentGlobalTowerMatrix()|getCurrentGlobalTowerMatrix]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|{ navMeshPosition=Vec3(), rotation=float, islandId=float, towerLocalIslandMatrix=Matrix(), towerScriptName=string }&lt;br /&gt;
|[[BuildNode:getBuildInfo()|getBuildInfo]]()&lt;br /&gt;
|This function can only be called after a building has been placed. Returns a table with information to build the tower again in the same location.&lt;br /&gt;
|-&lt;br /&gt;
|[[SceneNode]]&lt;br /&gt;
|[[BuildNode:buildFromBuildInfo(SceneNode building, table buildInfo)|buildFromBuildInfo]]([[SceneNode]] building, table buildInfo)&lt;br /&gt;
|Return the buildings SceneNode when the building is built else return nil. buildInfo is the table created by the getBuildInfo() function.&lt;br /&gt;
|-&lt;br /&gt;
|{ { island=Island(), position=Vec3()} }&lt;br /&gt;
|[[BuildNode:getProtectedPoints()|getProtectedPoints]]()&lt;br /&gt;
|This function return all protected points. in following format { {island=Island(),position=Vec3()}, ... }&lt;br /&gt;
|-&lt;br /&gt;
|{ { { island=Island(), position=Vec3()} } }&lt;br /&gt;
|[[BuildNode:getProtectedLines()|getProtectedLines]]()&lt;br /&gt;
|This function return all protected lines. in following format { { {island=Island(),position=Vec3()}, {island=Island(),position=Vec3()} }, ... }, allLines(line(p1, p2))&lt;br /&gt;
|-&lt;br /&gt;
|{ { { island=Island(), position=Vec3()} } }&lt;br /&gt;
|[[BuildNode:getProtectedPaths()|getProtectedPaths]]()&lt;br /&gt;
|This function return all protected paths. in following format { { {island=Island(),position=Vec3()}, {island=Island(),position=Vec3()} }, ... }, allLines(line(p1, p2))&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=Statistics&amp;diff=187</id>
		<title>Statistics</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=Statistics&amp;diff=187"/>
		<updated>2025-08-05T07:29:26Z</updated>

		<summary type="html">&lt;p&gt;Anders: Created page with &amp;quot;{{:StatisticsExampleCode}}  ==Constructor== {| class=&amp;quot;wikitable&amp;quot; !|function !|description |- |Statistics() | |- |}  ==Functions== {| class=&amp;quot;wikitable&amp;quot; !|return !|function !|description |- | |addScriptGroup(string groupName, string scriptNames) |scriptNames are seperated by &amp;#039;;&amp;#039; example skeleton.lua;rat.lua |- | |update() |Calculate previous frame statistics |- |float |Statistics:...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:StatisticsExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Constructor==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|Statistics()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Statistics:addScriptGroup(string groupName, string scriptNames)|addScriptGroup]](string groupName, string scriptNames)&lt;br /&gt;
|scriptNames are seperated by &#039;;&#039; example skeleton.lua;rat.lua&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Statistics:update()|update]]()&lt;br /&gt;
|Calculate previous frame statistics&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Statistics:getAverageThreadTime()|getAverageThreadTime]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Statistics:getMinThreadTime()|getMinThreadTime]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Statistics:getMaxThreadTime()|getMaxThreadTime]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Statistics:getAverageNumWork()|getAverageNumWork]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|number&lt;br /&gt;
|[[Statistics:getNumThreads()|getNumThreads]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|{time=number,maxTime=number,minTime=number,scriptCount=number}&lt;br /&gt;
|[[Statistics:getScriptGroupStatistics(string groupName)|getScriptGroupStatistics]](string groupName)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|{time=number,maxTime=number,minTime=number,scriptCount=number}&lt;br /&gt;
|[[Statistics:getUngroupedScriptStatistics()|getUngroupedScriptStatistics]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Statistics:getUngroupedScriptNames()|getUngroupedScriptNames]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=Lua&amp;diff=186</id>
		<title>Lua</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=Lua&amp;diff=186"/>
		<updated>2025-08-05T07:23:46Z</updated>

		<summary type="html">&lt;p&gt;Anders: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Lua API documentation&lt;br /&gt;
&lt;br /&gt;
== Class overview ==&lt;br /&gt;
{|cellspacing=&amp;quot;0&amp;quot; cellpadding=&amp;quot;0&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|&#039;&#039;&#039;Nodes&#039;&#039;&#039;&lt;br /&gt;
|&lt;br /&gt;
:&#039;&#039;&#039;Math&#039;&#039;&#039;&lt;br /&gt;
|&lt;br /&gt;
:&#039;&#039;&#039;Form&#039;&#039;&#039;&lt;br /&gt;
|&lt;br /&gt;
:&#039;&#039;&#039;Core&#039;&#039;&#039;&lt;br /&gt;
|&lt;br /&gt;
:&#039;&#039;&#039;Lists&#039;&#039;&#039;&lt;br /&gt;
|&lt;br /&gt;
:&#039;&#039;&#039;Render&#039;&#039;&#039;&lt;br /&gt;
|-&lt;br /&gt;
|valign=&amp;quot;top&amp;quot; width=&amp;quot;160&amp;quot;|&lt;br /&gt;
*[[AmbientLight]]&lt;br /&gt;
*[[AnimationManager]]&lt;br /&gt;
*[[BuildNode]]&lt;br /&gt;
*[[Camera]]&lt;br /&gt;
*[[DirectionalLight]]&lt;br /&gt;
*[[Editor]]&lt;br /&gt;
*[[FileNode]]&lt;br /&gt;
*[[Island]]&lt;br /&gt;
*[[IslandEdge]]&lt;br /&gt;
*[[NavMesh]]&lt;br /&gt;
*[[NodeMesh]]&lt;br /&gt;
*[[NodeMover]]&lt;br /&gt;
*[[Mesh]]&lt;br /&gt;
*[[Model]]&lt;br /&gt;
*[[MeshSplitter]]&lt;br /&gt;
*[[ParticleEffectElectricFlash]]&lt;br /&gt;
*[[ParticleSystem]]&lt;br /&gt;
*[[GraphicParticleSystem]]&lt;br /&gt;
*[[PathListMover]]&lt;br /&gt;
*[[PointLight]]&lt;br /&gt;
*[[PointLightModel]]&lt;br /&gt;
*[[PlayerNode]]&lt;br /&gt;
*[[RenderNode]]&lt;br /&gt;
*[[RootNode]]&lt;br /&gt;
*[[SplittedMesh]]&lt;br /&gt;
*[[SceneNode]]&lt;br /&gt;
*[[SoundSource]]&lt;br /&gt;
*[[SoundNode]]&lt;br /&gt;
*[[PhysicNode]]&lt;br /&gt;
*[[ToolManager]]&lt;br /&gt;
*[[UnstackableList]]&lt;br /&gt;
&lt;br /&gt;
|valign=&amp;quot;top&amp;quot; width=&amp;quot;160&amp;quot;|&lt;br /&gt;
*[[Box]]&lt;br /&gt;
*[[Collision]]&lt;br /&gt;
*[[Frustrum]]&lt;br /&gt;
*[[Line2D]]&lt;br /&gt;
*[[Line3D]]&lt;br /&gt;
*[[math]]&lt;br /&gt;
*[[Matrix]]&lt;br /&gt;
*[[Quat]]&lt;br /&gt;
*[[Random]]&lt;br /&gt;
*[[Sphere]]&lt;br /&gt;
*[[table]]&lt;br /&gt;
*[[Vec2]]&lt;br /&gt;
*[[Vec2i]]&lt;br /&gt;
*[[Vec3]]&lt;br /&gt;
*[[Vec4]]&lt;br /&gt;
&lt;br /&gt;
|valign=&amp;quot;top&amp;quot; width=&amp;quot;160&amp;quot;|&lt;br /&gt;
*[[Alignment]]&lt;br /&gt;
*[[Anchor]]&lt;br /&gt;
*[[Border]]&lt;br /&gt;
*[[DoubleBorder]]&lt;br /&gt;
*[[BorderSize]]&lt;br /&gt;
*[[Button]]&lt;br /&gt;
*[[ButtonStyle]]&lt;br /&gt;
*[[CheckBox]]&lt;br /&gt;
*[[ColorPicker]]&lt;br /&gt;
*[[ComboBox]]&lt;br /&gt;
*[[FallLayout]]&lt;br /&gt;
*[[FileWindow]]&lt;br /&gt;
*[[FlowLayout]]&lt;br /&gt;
*[[FreeFormLayout]]&lt;br /&gt;
*[[FreeFormLine]]&lt;br /&gt;
*[[FreeFormSprite]]&lt;br /&gt;
*[[FreeFormButton]]&lt;br /&gt;
*[[FreeFormButtonDesign]]&lt;br /&gt;
*[[FreeFormLabel]]&lt;br /&gt;
*[[Form]]&lt;br /&gt;
*[[Gradient]]&lt;br /&gt;
*[[GridLayout]]&lt;br /&gt;
*[[Image]]&lt;br /&gt;
*[[ImageLayout]]&lt;br /&gt;
*[[Label]]&lt;br /&gt;
*[[Layout]]&lt;br /&gt;
*[[Node2DMesh]]&lt;br /&gt;
*[[TextNode]]&lt;br /&gt;
*[[ProgressBar]]&lt;br /&gt;
*[[Render2DNode]]&lt;br /&gt;
*[[Scene2DNode]]&lt;br /&gt;
*[[ScrollBar]]&lt;br /&gt;
*[[Slider]]&lt;br /&gt;
*[[Sprite]]&lt;br /&gt;
*[[TextArea]]&lt;br /&gt;
*[[TextField]]&lt;br /&gt;
*[[Panel]]&lt;br /&gt;
*[[PanelSize]]&lt;br /&gt;
*[[PanelSizeType]]&lt;br /&gt;
*[[WorkMonitor]]&lt;br /&gt;
&lt;br /&gt;
|valign=&amp;quot;top&amp;quot; width=&amp;quot;160&amp;quot;|&lt;br /&gt;
*[[Billboard]]&lt;br /&gt;
*[[ComUnit]]&lt;br /&gt;
*[[Config]]&lt;br /&gt;
*[[ConfigItem]]&lt;br /&gt;
*[[Core]]&lt;br /&gt;
*[[Client]]&lt;br /&gt;
*[[Cursor]]&lt;br /&gt;
*[[File]]&lt;br /&gt;
*[[FontCharacter]]&lt;br /&gt;
*[[Global]]&lt;br /&gt;
*[[Input]]&lt;br /&gt;
*[[Key]]&lt;br /&gt;
*[[KeyBind]]&lt;br /&gt;
*[[Language]]&lt;br /&gt;
*[[LightType]]&lt;br /&gt;
*[[Listener]]&lt;br /&gt;
*[[String]]&lt;br /&gt;
*[[LuaScript]]&lt;br /&gt;
*[[LuaComMsgType]]&lt;br /&gt;
*[[LuaWrapper]]&lt;br /&gt;
*[[MouseKey]]&lt;br /&gt;
*[[NodeId]]&lt;br /&gt;
*[[BoundType]]&lt;br /&gt;
*[[PlayMode]]&lt;br /&gt;
*[[QueuedMode]]&lt;br /&gt;
*[[RenderMode]]&lt;br /&gt;
*[[Server]]&lt;br /&gt;
*[[ServerTester]]&lt;br /&gt;
*[[Shader]]&lt;br /&gt;
*[[Sound]]&lt;br /&gt;
*[[SoundType]]&lt;br /&gt;
*[[Stopwatch]]&lt;br /&gt;
*[[Texture]]&lt;br /&gt;
*[[Text]]&lt;br /&gt;
*[[VertexType]]&lt;br /&gt;
*[[Work]]&lt;br /&gt;
*[[Worker]]&lt;br /&gt;
*[[WrapMode]]&lt;br /&gt;
*[[HighScore]]&lt;br /&gt;
*[[Statistics]]&lt;br /&gt;
&lt;br /&gt;
|valign=&amp;quot;top&amp;quot; width=&amp;quot;160&amp;quot;|&lt;br /&gt;
*[[VectorVec3]]&lt;br /&gt;
*[[VectorVec2]]&lt;br /&gt;
*[[ListSplittedMesh]]&lt;br /&gt;
&lt;br /&gt;
|valign=&amp;quot;top&amp;quot; width=&amp;quot;160&amp;quot;|&lt;br /&gt;
*[[RenderScene]]&lt;br /&gt;
*[[GL]]&lt;br /&gt;
*[[GL_Clear]]&lt;br /&gt;
*[[GL_Blend]]&lt;br /&gt;
*[[GL_BlendEquation]]&lt;br /&gt;
*[[GL_State]]&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=Core&amp;diff=185</id>
		<title>Core</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=Core&amp;diff=185"/>
		<updated>2025-08-04T08:59:57Z</updated>

		<summary type="html">&lt;p&gt;Anders: /* Static functions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:CoreExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Static functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setUpdateHz(float hz)|setUpdateHz]](float hz)&lt;br /&gt;
|Sets the update frequency of the script based on in game time. minimum hz that can be set is &amp;gt;0.1 below that it will update every frame&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setUpdateHzRealTime(float hz)|setUpdateHzRealTime]](float hz)&lt;br /&gt;
|Sets the update frequency of the script based on real time. minimum hz that can be set is &amp;gt;0.1 below that it will update every frame&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:skipFrames(int frames)|skipFrames]](int frames)&lt;br /&gt;
|Skip a specified number of frames once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:skipTime(float seconds)|skipTime]](float seconds)&lt;br /&gt;
|Skip a specified time only once. This function needs to be called every time the script want to skip a specified number of frames.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getAverageDeltaTime()|getAverageDeltaTime]]()&lt;br /&gt;
|Get the average delta time over the last 100 frames.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getDeltaTime()|getDeltaTime]]()&lt;br /&gt;
|Get the last frames delta time.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getRealDeltaTime()|getRealDeltaTime]]()&lt;br /&gt;
|Get the last frames delta time without speed factor.&lt;br /&gt;
|-&lt;br /&gt;
|double&lt;br /&gt;
|[[Core:getGameTime()|getGameTime]]()&lt;br /&gt;
|Get time since the program started, with speed factor.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getTime()|getTime]]()&lt;br /&gt;
|Get time since the program started.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getTimeSpeed()|getTimeSpeed]]()&lt;br /&gt;
|Get time speed.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setTimeSpeed(float speed)|setTimeSpeed]](float speed)&lt;br /&gt;
|Set time speed bettwen [0,10], defult is 1.0.&lt;br /&gt;
|-&lt;br /&gt;
|[[FontCharacter]]&lt;br /&gt;
|[[Core:getFontCharacter(String font, int fontHeight, String character)|getFontCharacter]](String font, int fontHeight, String character)&lt;br /&gt;
|Get a font character.&lt;br /&gt;
|-&lt;br /&gt;
|[[Sound]]&lt;br /&gt;
|[[Core:getSound()|getSound]]()&lt;br /&gt;
|Load [[sound]].&lt;br /&gt;
|-&lt;br /&gt;
|[[Work]]&lt;br /&gt;
|[[Core:getCurrentWork()|getCurrentWork]]()&lt;br /&gt;
|Return the current work.&lt;br /&gt;
|-&lt;br /&gt;
|[[LuaScript]]&lt;br /&gt;
|[[Core:getCurrentLuaScript()|getCurrentLuaScript]]()&lt;br /&gt;
|Returns the the current executing Lua script.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSoundCamera(Camera camera)|setSoundCamera]]([[Camera]] camera)&lt;br /&gt;
|Set to which camera sound will go. This will be removed in the future.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSoundCameraMatrix(Matrix cameraMatrix)|setSoundCameraMatrix]]([[Matrix]] cameraMatrix)&lt;br /&gt;
|Set sound camera matrix. this is only useful when sound camera is set to nil.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setDebug2DCamera(Camera camera)|setDebug2DCamera]]([[Camera]] camera)&lt;br /&gt;
|Set to which camera 2D debug text should be renderd to.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:addDebugLine(Vec3 l1, Vec3 l2, float time, Vec3 color)|addDebugLine]]([[Vec3]] l1, [[Vec3]] l2, float time, [[Vec3]] color)&lt;br /&gt;
|Add debug line.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:addDebugLine(Line3D line, float time, Vec3 color)|addDebugLine]]([[Line3D]] line, float time, [[Vec3]] color)&lt;br /&gt;
|Add debug line.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:addDebugSphere(Sphere sphere, float time, Vec3 color)|addDebugSphere]]([[Sphere]] [[sphere]], float time, [[Vec3]] color)&lt;br /&gt;
|Add debug [[sphere]].&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:addDebugBox(Box box, float time, Vec3 color)|addDebugBox]]([[Box]] [[box]], float time, [[Vec3]] color)&lt;br /&gt;
|Add debug [[box]].&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:clearDebugLines()|clearDebugLines]]()&lt;br /&gt;
|Clear all debug data, this includes lines, Spheres and debugBoxes.&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[Core:getFrameNumber()|getFrameNumber]]()&lt;br /&gt;
|get number of rendered frame sence program started.&lt;br /&gt;
|-&lt;br /&gt;
|[[Model]]&lt;br /&gt;
|[[Core:getModel(string modelName)|getModel]]([[string]] modelName)&lt;br /&gt;
|Load model.&lt;br /&gt;
|-&lt;br /&gt;
|[[Shader]]&lt;br /&gt;
|[[Core:getShader(string shaderName)|getShader]]([[string]] shaderName)&lt;br /&gt;
|Load shader.&lt;br /&gt;
|-&lt;br /&gt;
|[[Shader]]&lt;br /&gt;
|[[Core:getShader(string shaderName, string definition)|getShader]]([[string]] shaderName, string definition)&lt;br /&gt;
|Load shader with one definition.&lt;br /&gt;
|-&lt;br /&gt;
|[[Shader]]&lt;br /&gt;
|[[Core:getShader(string shaderName, table definitions)|getShader]]([[string]] shaderName, [[table]] definitions)&lt;br /&gt;
|Load shader with one definitions.&lt;br /&gt;
|-&lt;br /&gt;
|[[Texture]]&lt;br /&gt;
|[[Core:getTexture(string textureName)|getTexture]]([[string]] textureName)&lt;br /&gt;
|Load texture.&lt;br /&gt;
|-&lt;br /&gt;
|[[Texture]]&lt;br /&gt;
|[[Core:getTexture(File aFile)|getTexture]]([[File]] aFile)&lt;br /&gt;
|Load texture from a file.&lt;br /&gt;
|-&lt;br /&gt;
|[[File]]&lt;br /&gt;
|[[Core:getDataFolder()|getDataFolder]]()&lt;br /&gt;
|Get main folder.&lt;br /&gt;
|-&lt;br /&gt;
|[[File]]&lt;br /&gt;
|[[Core:getDataFolder(string subFolder)|getDataFolder]]([[string]] subFolder)&lt;br /&gt;
|Get sub folder from main folder.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2]]&lt;br /&gt;
|[[Core:getScreenResolution()|getScreenResolution]]()&lt;br /&gt;
|Get screen resolution.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2]]&lt;br /&gt;
|[[Core:getRenderResolution()|getRenderResolution]]()&lt;br /&gt;
|Get render resolution. &lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getRenderScale()|getRenderScale]]()&lt;br /&gt;
|Get render scale. &lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Core:getSteamName()|getSteamName]]()&lt;br /&gt;
|returns the name of the current steam user, if available.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Core:setScriptNetworkId(string name)|setScriptNetworkId]](string name)&lt;br /&gt;
|Sets the network name of this script. returns true on success. [This name should be set by all clients individually]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:requireScriptNetworkIdToRunUpdate(bool set)|requireScriptNetworkIdToRunUpdate]](bool set)&lt;br /&gt;
|If set true, the script will not run &amp;quot;update&amp;quot; until setScriptNetworkId() is set&lt;br /&gt;
|-&lt;br /&gt;
|number&lt;br /&gt;
|[[Core:getPlayerId()|getPlayerId]]()&lt;br /&gt;
|returns the unique player id of the client. to know where he is supossed to be.&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Core:getNetworkName()|getNetworkName]]()&lt;br /&gt;
|returns netName for the current script&lt;br /&gt;
|-&lt;br /&gt;
|[[Client]]&lt;br /&gt;
|[[Core:getNetworkClient()|getNetworkClient]]()&lt;br /&gt;
|Returns the client, using multiple times will return the same client. (There is one client)&lt;br /&gt;
|-&lt;br /&gt;
|[[Server]]&lt;br /&gt;
|[[Core:getNetworkServer()|getNetworkServer]]()&lt;br /&gt;
|Returns the server, using multiple times will return the same server. (There is one server)&lt;br /&gt;
|-&lt;br /&gt;
|{ {name=string(), ip=string(), port=int(), time=int()} }&lt;br /&gt;
|[[Core:getServerList()|getServerList]]()&lt;br /&gt;
|Returns the global serverlist.&lt;br /&gt;
|-&lt;br /&gt;
|{ {name=string(), ip=string(), port=int(), time=int()} }&lt;br /&gt;
|[[Core:getServerList(int time)|getServerList]](int time)&lt;br /&gt;
|Returns the global serverlist. Time is in the format epoch seconds.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Core:isInMultiplayer()|isInMultiplayer]]()&lt;br /&gt;
|Returns true if the client is connected to a server.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Core:isInFullscreen()|isInFullscreen]]()&lt;br /&gt;
|Returns true if in fullscreen mode&lt;br /&gt;
|-&lt;br /&gt;
|number&lt;br /&gt;
|[[Core:getIndexOfNetworkName(string networkName)|getIndexOfNetworkName]](string networkName)&lt;br /&gt;
|Returns the index of the script with the networkName, or 0 if none was found&lt;br /&gt;
|-&lt;br /&gt;
|[[LuaScript]]&lt;br /&gt;
|[[Core:getScriptOfNetworkName(string networkName)|getScriptOfNetworkName]](string networkName)&lt;br /&gt;
|Returns the script that uses the networkName, or nil if none was found&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Core:getNetworkNameOf(object param)|getNetworkNameOf]](object param)&lt;br /&gt;
|Returns the Network name of the script. takes number(index of a script) or a [[LuaScript]]&lt;br /&gt;
|-&lt;br /&gt;
|[[ComUnit]]&lt;br /&gt;
|[[Core:getComUnit()|getComUnit]]()&lt;br /&gt;
|Get screen resolution.&lt;br /&gt;
|-&lt;br /&gt;
|[[bool]]&lt;br /&gt;
|[[Core:existLuaScript(int luaIndex)|existLuaScript]](int luaIndex)&lt;br /&gt;
|Returns true if lua script is running.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getBillboard()|getBillboard]]()&lt;br /&gt;
|Get the billboard for this script.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getBillboard(int luaIndex)|getBillboard]](int luaIndex)&lt;br /&gt;
|Get the billboard for luaIndex.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getBillboard(string name)|getBillboard]]([[string]] name)&lt;br /&gt;
|Get billboard by name.&lt;br /&gt;
|-&lt;br /&gt;
|[[Input]]&lt;br /&gt;
|[[Core:getInput()|getInput]]()&lt;br /&gt;
|Get input.&lt;br /&gt;
|-&lt;br /&gt;
|[[HighScore]]&lt;br /&gt;
|[[Core:getHighScore()|getHighScore]]()&lt;br /&gt;
|Get HighScore.&lt;br /&gt;
|-&lt;br /&gt;
|[[Cursor]]&lt;br /&gt;
|[[Core:getCursor()|getCursor]]()&lt;br /&gt;
|Get cursor.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:stopCore()|stopCore]]()&lt;br /&gt;
|Stop score.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:quitMainMenu()|quitMainMenu]]()&lt;br /&gt;
|If game is in main menu then the game will be shutdown.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:quitToMainMenu()|quitToMainMenu]]()&lt;br /&gt;
|Quit from mapeditor or game to main menu.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:quitToMapeditor()|quitToMapeditor]]()&lt;br /&gt;
|Quit from game to mapeditor.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Core:isInEditor()|isInEditor]]()&lt;br /&gt;
|Return true when in editor or when testing a map from the editor.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:startMap(string fileName)|startMap]]([[string]] fileName)&lt;br /&gt;
|start map with name like fileName=&amp;quot;Data/Map/fil.map&amp;quot;.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:startMultiplayerClonedMaps(string fileName, nil clientIds)|startMultiplayerClonedMaps]](string fileName, nil clientIds)&lt;br /&gt;
|start map with name like fileName=&amp;quot;Data/Map/fil.map&amp;quot;. &lt;br /&gt;
clientIds is a list of all client ids that need a private world to be loaded. example {2,3,4,5} &lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:startMapInDebugMode(string fileName)|startMapInDebugMode]]([[string]] fileName)&lt;br /&gt;
|start map in debug mode with name like fileName=&amp;quot;Data/Map/fil.map&amp;quot;.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:startMapEditor(string fileName)|startMapEditor]]([[string]] fileName)&lt;br /&gt;
|start mapEditor. If fileName is &amp;quot;&amp;quot; then a new map will be created.&lt;br /&gt;
|-&lt;br /&gt;
|[[Panel]]&lt;br /&gt;
|[[Core:getPanelWithKeyboardFocus()|getPanelWithKeyboardFocus]]()&lt;br /&gt;
|Return the curent [[panel]] with keyboard focus.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getGlobalBillboard(string billboardName)|getGlobalBillboard]]([[string]] billboardName)&lt;br /&gt;
|Create or collect the billboard with a given name. The Billboard will exist unit the game shutsdown. The billboardName must be unique or allready exist as a globalBillboard.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getGameSessionBillboard(string billboardName)|getGameSessionBillboard]]([[string]] billboardName)&lt;br /&gt;
|Create or collect the billboard with a given name. The Billboard will exist unit the game current map is shutdown.&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Core:getMainCamera()|getMainCamera]]()&lt;br /&gt;
|Get the main camera.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setMainCamera(Camera mainCamera)|setMainCamera]]([[Camera]] mainCamera)&lt;br /&gt;
|set the main camera.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setRenderScale(float scale)|setRenderScale]](float scale)&lt;br /&gt;
|set the scale factor of the current render resolution. should be between [0.5,2.0]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setRenderResolution(Vec2 resolution)|setRenderResolution]]([[Vec2]] resolution)&lt;br /&gt;
|set Render resolution.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setMaxFrameRate(int maxFrameRate)|setMaxFrameRate]](int maxFrameRate)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:skipRenderFrame()|skipRenderFrame]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setCursor(string cursorFilePath)|setCursor]]([[string]] cursorFilePath)&lt;br /&gt;
|Set the cursor icon. NOTE! must be a *.bmp file.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSounMasterGain(float gain)|setSounMasterGain]](float gain)&lt;br /&gt;
|set sound master gain, gain is between [0,1]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSoundMusicGain(float gain)|setSoundMusicGain]](float gain)&lt;br /&gt;
|set music gain, gain is between [0,1]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSounEffectGain(float gain)|setSounEffectGain]](float gain)&lt;br /&gt;
|set effect gain, gain is between [0,1]&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getSounMasterGain()|getSounMasterGain]]()&lt;br /&gt;
|get sound master gain&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getSounMusicGain()|getSounMusicGain]]()&lt;br /&gt;
|get sound master gain&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getSounEffectGain()|getSounEffectGain]]()&lt;br /&gt;
|get sound master gain&lt;br /&gt;
|-&lt;br /&gt;
|[[Panel]]&lt;br /&gt;
|[[Core:getPanelWithMouseFocus()|getPanelWithMouseFocus]]()&lt;br /&gt;
|get panel with mouse focus.&lt;br /&gt;
|-&lt;br /&gt;
|[[Panel]]&lt;br /&gt;
|[[Core:getPanelWithKeyboardFocus()|getPanelWithKeyboardFocus]]()&lt;br /&gt;
|get panel with mouse focus.&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Core:getMachineId()|getMachineId]]()&lt;br /&gt;
|get the machine ID.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setFullscreen(bool fullscreen)|setFullscreen]](bool fullscreen)&lt;br /&gt;
|Set if we should use fullscreen.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setVsync(bool vSync)|setVsync]](bool vSync)&lt;br /&gt;
|Set if vSyncshould turned od.&lt;br /&gt;
|-&lt;br /&gt;
|[[DirectionalLight]]&lt;br /&gt;
|[[Core:getDirectionalLight(SceneNode node)|getDirectionalLight]]([[SceneNode]] node)&lt;br /&gt;
|get the current direction light&lt;br /&gt;
|-&lt;br /&gt;
|[[AmbientLight]]&lt;br /&gt;
|[[Core:getAmbientLight(SceneNode node)|getAmbientLight]]([[SceneNode]] node)&lt;br /&gt;
|get the current ambientlight&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=Panel&amp;diff=184</id>
		<title>Panel</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=Panel&amp;diff=184"/>
		<updated>2025-08-04T08:59:12Z</updated>

		<summary type="html">&lt;p&gt;Anders: /* Functions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:PanelExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Constructor==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|Panel([[PanelSize]] size)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Panel(Panel panel)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:clear()|clear]]()&lt;br /&gt;
|Clear panel from all children.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:clearEvents()|clearEvents]]()&lt;br /&gt;
|Clear panel from all events.&lt;br /&gt;
|-&lt;br /&gt;
|Panel&lt;br /&gt;
|[[Panel:add(Panel panel)|add]]([[Panel]] panel)&lt;br /&gt;
|Add child panel.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:addRenderObject(Scene2DNode renderObject)|addRenderObject]]([[Scene2DNode]] renderObject)&lt;br /&gt;
|Add render object to this panel.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Panel:removePanel(Panel panel)|removePanel]]([[Panel]] panel)&lt;br /&gt;
|Remove child panel.&lt;br /&gt;
|-&lt;br /&gt;
|[[Form]]&lt;br /&gt;
|[[Panel:getForm()|getForm]]()&lt;br /&gt;
|Return the form this panel belongs to.&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Panel:getName()|getName]]()&lt;br /&gt;
|Return the name of the panel.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setBackground(Sprite background)|setBackground]]([[Sprite]] background)&lt;br /&gt;
|Set panel background.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setBackground(Sprite background, PanelSize backgroundSize)|setBackground]]([[Sprite]] background, [[PanelSize]] backgroundSize)&lt;br /&gt;
|Set panel background. BackgroundSize set the size of the background the background is aligned to the center.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setBackground(Gradient background)|setBackground]]([[Gradient]] background)&lt;br /&gt;
|Set panel background.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setBackground(Gradient background, PanelSize backgroundSize)|setBackground]]([[Gradient]] background, [[PanelSize]] backgroundSize)&lt;br /&gt;
|Set panel background. BackgroundSize set the size of the background the background is aligned to the center.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setBorder(BaseBorder panelBorder)|setBorder]]([[BaseBorder]] panelBorder)&lt;br /&gt;
|Set panel border.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setPadding(BorderSize padding)|setPadding]]([[BorderSize]] padding)&lt;br /&gt;
|Set panel padding.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setMargin(BorderSize margin)|setMargin]]([[BorderSize]] margin)&lt;br /&gt;
|Set panel margin.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setPanelId(string panelId)|setPanelId]]([[string]] panelId)&lt;br /&gt;
|Set panelsize.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setPanelSize(PanelSize size)|setPanelSize]]([[PanelSize]] size)&lt;br /&gt;
|Set panel id.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setLayout(Layout layout)|setLayout]]([[Layout]] [[layout]])&lt;br /&gt;
|Set panel Layout.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setRender()|setRender]]()&lt;br /&gt;
|Force panel to render.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setVisible(bool visible)|setVisible]](bool visible)&lt;br /&gt;
|Set panel visible.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setEnableScroll()|setEnableScroll]]()&lt;br /&gt;
|Set enable scroll.&lt;br /&gt;
|-&lt;br /&gt;
|[[ScrollBar]]&lt;br /&gt;
|[[Panel:getYScrollBar()|getYScrollBar]]()&lt;br /&gt;
|Get scrrollbar. if no scrollbar has been created return nil.&lt;br /&gt;
|-&lt;br /&gt;
|[[ScrollBar]]&lt;br /&gt;
|[[Panel:getXScrollBar()|getXScrollBar]]()&lt;br /&gt;
|Get scrrollbar. if no scrollbar has been created return nil.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setTag(string tag)|setTag]](string tag)&lt;br /&gt;
|Set tag.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setTag(Text tag)|setTag]]([[Text]] tag)&lt;br /&gt;
|Set tag.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setToolTip(Text toolTip)|setToolTip]]([[Text]] toolTip)&lt;br /&gt;
|Set tag.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setToolTip(string toolTip)|setToolTip]](string toolTip)&lt;br /&gt;
|Set tag.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setToolTip(Panel toolTipPanel)|setToolTip]]([[Panel]] toolTipPanel)&lt;br /&gt;
|Set a panel that will be shown as a tool-tip.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setToolTipParentpanel(Panel panel)|setToolTipParentpanel]]([[Panel]] panel)&lt;br /&gt;
|Set another parent where the tool-tip will be displayed.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setCanHandleInput(bool canTakeInput)|setCanHandleInput]](bool canTakeInput)&lt;br /&gt;
|Set if the panel can access inputs.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setKeyboardOwner()|setKeyboardOwner]]())&lt;br /&gt;
|Set this panel as the keyboard owner.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:clearKeyboardOwner()|clearKeyboardOwner]]())&lt;br /&gt;
|Clear keyboard owner.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setEnabled(bool enabled)|setEnabled]](bool enabled)&lt;br /&gt;
|Set if the panel is enabled. if disabled still visible but cant be changed.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:addEventCallbackExecute(nil function)|addEventCallbackExecute]](nil function)&lt;br /&gt;
|Add callback for execution event.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:addEventCallbackUpdate(nil function)|addEventCallbackUpdate]](nil function)&lt;br /&gt;
|Add callback for update event.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:addEventCallbackResized(nil function)|addEventCallbackResized]](nil function)&lt;br /&gt;
|Add callback for resize event.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:addEventCallbackMouseFocusGain(nil function)|addEventCallbackMouseFocusGain]](nil function)&lt;br /&gt;
|Add mouse focus gain&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:addEventCallbackMouseFocusLost(nil function)|addEventCallbackMouseFocusLost]](nil function)&lt;br /&gt;
|Add callback for focus gain event.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:addEventCallbackKeyboardFocusGain(nil function)|addEventCallbackKeyboardFocusGain]]([nil function)&lt;br /&gt;
|Add callback for keyboard focus gain event.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:addEventCallbackKeyboardFocusLost(nil function)|addEventCallbackKeyboardFocusLost]](nil function)&lt;br /&gt;
|Add callback for keybord focus lost event.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:addEventCallbackChanged(nil function)|addEventCallbackChanged]](nil function)&lt;br /&gt;
|Add callback for when somthinge has changed.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:addEventCallbackOnClick(nil function)|addEventCallbackOnClick]](nil function)&lt;br /&gt;
|Add callback for on mouse left click event.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:addEventCallbackOnRightClick(nil function)|addEventCallbackOnRightClick]](nil function)&lt;br /&gt;
|Add callback for on mouse right click event.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:addEventCallbackOnDoubleclick(nil function)|addEventCallbackOnDoubleclick]](nil function)&lt;br /&gt;
|Add callback for when on mouse left doubleclick event.&lt;br /&gt;
|-&lt;br /&gt;
|Panel&lt;br /&gt;
|[[Panel:getPanelById(string id)|getPanelById]]([[string]] id)&lt;br /&gt;
|Get panel by id.&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[Panel:getNumPanel()|getNumPanel]]()&lt;br /&gt;
|Get num panel children.&lt;br /&gt;
|-&lt;br /&gt;
|Panel&lt;br /&gt;
|[[Panel:getPanel(int index)|getPanel]](int index)&lt;br /&gt;
|Get panel by index.&lt;br /&gt;
|-&lt;br /&gt;
|[[PanelSize]]&lt;br /&gt;
|[[Panel:getPanelSize()|getPanelSize]]()&lt;br /&gt;
|Get panel size.&lt;br /&gt;
|-&lt;br /&gt;
|[[BorderSize]]&lt;br /&gt;
|[[Panel:getMarginSize()|getMarginSize]]()&lt;br /&gt;
|Get margin size.&lt;br /&gt;
|-&lt;br /&gt;
|[[BorderSize]]&lt;br /&gt;
|[[Panel:getPaddingSize()|getPaddingSize]]()&lt;br /&gt;
|Get padding size.&lt;br /&gt;
|-&lt;br /&gt;
|[[Layout]]&lt;br /&gt;
|[[Panel:getLayout()|getLayout]]()&lt;br /&gt;
|Get layout.&lt;br /&gt;
|-&lt;br /&gt;
|[[BaseBorder]]&lt;br /&gt;
|[[Panel:getBorder()|getBorder]]()&lt;br /&gt;
|Get border.&lt;br /&gt;
|-&lt;br /&gt;
|[[string]]&lt;br /&gt;
|[[Panel:getPanelId()|getPanelId]]()&lt;br /&gt;
|Get id.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Panel:getVisible()|getVisible]]()&lt;br /&gt;
|Get if visible.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2i]]&lt;br /&gt;
|[[Panel:getMinPos()|getMinPos]]()&lt;br /&gt;
|Get minPos.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2i]]&lt;br /&gt;
|[[Panel:getMaxPos()|getMaxPos]]()&lt;br /&gt;
|Get max position.&lt;br /&gt;
|-&lt;br /&gt;
|[[Text]]&lt;br /&gt;
|[[Panel:getTag()|getTag]]()&lt;br /&gt;
|Get tag.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Panel:getEnabled()|getEnabled]]()&lt;br /&gt;
|Get is enabled.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2i]]&lt;br /&gt;
|[[Panel:getPanelContentPixelSize()|getPanelContentPixelSize]]()&lt;br /&gt;
|Get panel content size. &lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2i]]&lt;br /&gt;
|[[Panel:getPanelGlobalMinMaxPosition(Vec2 outMin, Vec2 outMax)|getPanelGlobalMinMaxPosition]]([[Vec2]] outMin, [[Vec2]] outMax)&lt;br /&gt;
|Get panel content size. NOTE outmin outMax is set by this function&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Panel:getWillBeRenderd()|getWillBeRenderd]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Panel&lt;br /&gt;
|[[Panel:getParent()|getParent]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Panel:haskeyboardFocus()|haskeyboardFocus]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Panel:hasMouseFocus()|hasMouseFocus]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setName(string name)|setName]](string name)&lt;br /&gt;
|Set name of the panel.&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Operators==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Panel]] == [[Panel]]&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Overloaded returns==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|Parameter&lt;br /&gt;
|-&lt;br /&gt;
|Panel&lt;br /&gt;
|add&lt;br /&gt;
|panel&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=Island&amp;diff=183</id>
		<title>Island</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=Island&amp;diff=183"/>
		<updated>2025-08-04T08:53:38Z</updated>

		<summary type="html">&lt;p&gt;Anders: /* Functions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:IslandExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Inheritance==&lt;br /&gt;
[[SceneNode]]&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2]]&lt;br /&gt;
|[[Island:convertFromIslandLocalSpaceToNavMeshSpace(Vec3 localIslandPosition)|convertFromIslandLocalSpaceToNavMeshSpace]]([[Vec3]] localIslandPosition)&lt;br /&gt;
|Returns a local position for the navmesh.&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[Island:getIslandId()|getIslandId]]()&lt;br /&gt;
|Get unique island id.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Island:getDistanceToIsland(Vec3 position)|getDistanceToIsland]]([[Vec3]] position)&lt;br /&gt;
|Get distance between this island and the given position.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec3]]&lt;br /&gt;
|[[Island:getVelocity()|getVelocity]]()&lt;br /&gt;
|Get the islands velocity.&lt;br /&gt;
|-&lt;br /&gt;
|[[Box]]&lt;br /&gt;
|[[Island:getBoundingBox()|getBoundingBox]]()&lt;br /&gt;
|Get the islands global BoundingBox.&lt;br /&gt;
|-&lt;br /&gt;
|[[Texture]]&lt;br /&gt;
|[[Island:getIslandTexture(int index)|getIslandTexture]](int index)&lt;br /&gt;
|Get island texture. index is between [1,3].&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[Island:getPlayerId()|getPlayerId]]()&lt;br /&gt;
|Get island player id. Player is between [0,n] 0 represent that island belong to no player player id larger then 0 represent a player id.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Island:setNextLocalPosition(Vec3 position)|setNextLocalPosition]]([[Vec3]] position)&lt;br /&gt;
|Set the island position for the next frame.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Island:setNextLocalMatrix(Matrix localMatrix)|setNextLocalMatrix]]([[Matrix]] localMatrix)&lt;br /&gt;
|Set the island local matrix for the next frame.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Island:setBoundingSphere(Sphere boundingSphere)|setBoundingSphere]]([[Sphere]] boundingSphere)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Island:setBoundingBox(Box boundingBox)|setBoundingBox]]([[Box]] boundingBox)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Island:lockDownIslandMovment()|lockDownIslandMovment]]()&lt;br /&gt;
|Stop the island from moving by itselef&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Island:unLockIslandMovment()|unLockIslandMovment]]()&lt;br /&gt;
|Allow the island from moving by itselef&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Island:setPlayerId(int playerId)|setPlayerId]](int playerId)&lt;br /&gt;
|Set island player id. Player id should be between [0,n] &lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Island:setPaintBrushTexture(Texture texture)|setPaintBrushTexture]]([[Texture]] texture)&lt;br /&gt;
|Set paint brush texture.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Island:setPaintBrushTexture(string textureName)|setPaintBrushTexture]](string texture)&lt;br /&gt;
|Set paint brush texture by name.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Island:setPaintBrushColor(Vec3 color)|setPaintBrushColor]]([[Vec3]] color)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Island:paint(Vec3 globalPos, float brushSize, float brushStrength)|paint]]([[Vec3]] globalPos, float brushSize, float brushStrength)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Island:setIslandTexture(int index, Texture texture)|setIslandTexture]](int index, [[Texture]] texture)&lt;br /&gt;
|Set island texture. index is between [1,3].&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=NodeMover&amp;diff=182</id>
		<title>NodeMover</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=NodeMover&amp;diff=182"/>
		<updated>2025-08-04T08:23:03Z</updated>

		<summary type="html">&lt;p&gt;Anders: /* Functions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:NodeMoverExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Constructor==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|NodeMover([[SceneNode]] nodeToMove, float walkSize, float walkSpeed, float pathOffset)&lt;br /&gt;
|pathOffset accept a value bettwen [-1,1].&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[NodeMover:isAtFinalDestination()|isAtFinalDestination]]()&lt;br /&gt;
|Returns true if the node has reach the final destination.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec3]]&lt;br /&gt;
|[[NodeMover:getFuturePosition(float time)|getFuturePosition]](float time)&lt;br /&gt;
|Get the future position of the node, after a set time. (This only works if the entire path is known, special case is the mine cart which this may not be true for.)&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec3]]&lt;br /&gt;
|[[NodeMover:getCurrentPosition()|getCurrentPosition]]()&lt;br /&gt;
|Return the current global position.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec3]]&lt;br /&gt;
|[[NodeMover:getCurrentVelocity()|getCurrentVelocity]]()&lt;br /&gt;
|Return the current velocity.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[NodeMover:getCurrentSpeed()|getCurrentSpeed]]()&lt;br /&gt;
|Return the walk speed.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec3]]&lt;br /&gt;
|[[NodeMover:getTargetGlobalPosition()|getTargetGlobalPosition]]()&lt;br /&gt;
|Return the next Path points global position&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec3]]&lt;br /&gt;
|[[NodeMover:getPositionFromFrame(number frameId)|getPositionFromFrame]](number frameId)&lt;br /&gt;
|get a position from a frame, we only store position for 5 frames&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[NodeMover:getDistanceToExit()|getDistanceToExit]]()&lt;br /&gt;
|Return distance to exit.&lt;br /&gt;
|-&lt;br /&gt;
|Table&lt;br /&gt;
|[[NodeMover:getPathPoints(float ignorePointsWithinDistance)|getPathPoints]](float ignorePointsWithinDistance)&lt;br /&gt;
|Return main pathPoints. return in format &#039;&#039;&#039;{{navMeshPos = [[Vec2]](), localIslandPos = [[Vec3]](), islandId = number()},...}&#039;&#039;&#039;&lt;br /&gt;
|-&lt;br /&gt;
|Table&lt;br /&gt;
|[[NodeMover:setPathPoints(Table pathPoints)|setPathPoints]](Table pathPoints)&lt;br /&gt;
|Set main pathPoints same format as given by getPathPoints().&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMover:setWalkSpeed(float walkSpeed)|setWalkSpeed]](float walkSpeed)&lt;br /&gt;
|Set walk speed&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMover:setMaxWalkSpeed(float maxWalkSpeed)|setMaxWalkSpeed]](float maxWalkSpeed)&lt;br /&gt;
|Caps the speed that the npc can walk. speed = min(walkSpeed,maxWalkSpeed)&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMover:setWalkSize(float size)|setWalkSize]](float size)&lt;br /&gt;
|Set the size of the npc&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMover:addCallbackWayPointReached(string functionName)|addCallbackWayPointReached]](string functionName)&lt;br /&gt;
|Function name&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMover:addMoveTo(SceneNode island, Vec3 localPosition)|addMoveTo]](SceneNode island, Vec3 localPosition)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMover:followNode(SceneNode node)|followNode]](SceneNode node)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMover:update()|update]]()&lt;br /&gt;
|Update the nodeMover and move the node towards the final position.&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=PhysicNode&amp;diff=181</id>
		<title>PhysicNode</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=PhysicNode&amp;diff=181"/>
		<updated>2025-08-03T13:40:34Z</updated>

		<summary type="html">&lt;p&gt;Anders: /* Functions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:PhysicNodeExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Inheritance==&lt;br /&gt;
[[SceneNode]]&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[PhysicNode:addRigidBodyRotationLimit(SceneNode node, Vec3 velocity, Vec3 Rotation, float rotationSpeed, float rotateLimit, float timeToLive)|addRigidBodyRotationLimit]]([[SceneNode ]] node, [[Vec3]] velocity, [[Vec3]] Rotation, float rotationSpeed, float rotateLimit, float timeToLive)&lt;br /&gt;
|Add a [[SceneNode]] to be handled by the Very Basic Physic&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[PhysicNode:addRigidBody(SceneNode mesh, Vec3 velocity, Vec3 Rotation, float rotationSpeed, float timeToLive)|addRigidBody]]([[SceneNode]] mesh, [[Vec3]] velocity, [[Vec3]] Rotation, float rotationSpeed, float timeToLive)&lt;br /&gt;
|Add a SceneNode to be handled by the Very Basic Physic&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=NodeMover&amp;diff=180</id>
		<title>NodeMover</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=NodeMover&amp;diff=180"/>
		<updated>2025-08-03T13:35:52Z</updated>

		<summary type="html">&lt;p&gt;Anders: /* Functions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:NodeMoverExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Constructor==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|NodeMover([[SceneNode]] nodeToMove, float walkSize, float walkSpeed, float pathOffset)&lt;br /&gt;
|pathOffset accept a value bettwen [-1,1].&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[NodeMover:isAtFinalDestination()|isAtFinalDestination]]()&lt;br /&gt;
|Returns true if the node has reach the final destination.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec3]]&lt;br /&gt;
|[[NodeMover:getFuturePosition(float time)|getFuturePosition]](float time)&lt;br /&gt;
|Get the future position of the node, after a set time. (This only works if the entire path is known, special case is the mine cart which this may not be true for.)&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec3]]&lt;br /&gt;
|[[NodeMover:getCurrentPosition()|getCurrentPosition]]()&lt;br /&gt;
|Return the current global position.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec3]]&lt;br /&gt;
|[[NodeMover:getCurrentVelocity()|getCurrentVelocity]]()&lt;br /&gt;
|Return the current velocity.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[NodeMover:getCurrentSpeed()|getCurrentSpeed]]()&lt;br /&gt;
|Return the walk speed.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec3]]&lt;br /&gt;
|[[NodeMover:getTargetGlobalPosition()|getTargetGlobalPosition]]()&lt;br /&gt;
|Return the next Path points global position&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[NodeMover:getDistanceToExit()|getDistanceToExit]]()&lt;br /&gt;
|Return distance to exit.&lt;br /&gt;
|-&lt;br /&gt;
|Table&lt;br /&gt;
|[[NodeMover:getPathPoints(float ignorePointsWithinDistance)|getPathPoints]](float ignorePointsWithinDistance)&lt;br /&gt;
|Return main pathPoints. return in format &#039;&#039;&#039;{{navMeshPos = [[Vec2]](), localIslandPos = [[Vec3]](), islandId = number()},...}&#039;&#039;&#039;&lt;br /&gt;
|-&lt;br /&gt;
|Table&lt;br /&gt;
|[[NodeMover:setPathPoints(Table pathPoints)|setPathPoints]](Table pathPoints)&lt;br /&gt;
|Set main pathPoints same format as given by getPathPoints().&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMover:setWalkSpeed(float walkSpeed)|setWalkSpeed]](float walkSpeed)&lt;br /&gt;
|Set walk speed&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMover:setMaxWalkSpeed(float maxWalkSpeed)|setMaxWalkSpeed]](float maxWalkSpeed)&lt;br /&gt;
|Caps the speed that the npc can walk. speed = min(walkSpeed,maxWalkSpeed)&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMover:setWalkSize(float size)|setWalkSize]](float size)&lt;br /&gt;
|Set the size of the npc&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMover:addCallbackWayPointReached(string functionName)|addCallbackWayPointReached]](string functionName)&lt;br /&gt;
|Function name&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMover:addMoveTo(SceneNode island, Vec3 localPosition)|addMoveTo]](SceneNode island, Vec3 localPosition)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMover:followNode(SceneNode node)|followNode]](SceneNode node)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMover:update()|update]]()&lt;br /&gt;
|Update the nodeMover and move the node towards the final position.&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=Global&amp;diff=179</id>
		<title>Global</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=Global&amp;diff=179"/>
		<updated>2025-08-03T13:15:55Z</updated>

		<summary type="html">&lt;p&gt;Anders: /* Global functions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:GlobalExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Global members==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
&lt;br /&gt;
!|type&lt;br /&gt;
!|variable&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|PI&lt;br /&gt;
|3.14159265359&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|LUA_INDEX&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[LuaWrapper]]&lt;br /&gt;
|LUA&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Global functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Global:require(string path)|require]]([[string]] path)&lt;br /&gt;
|Include another lua file.&lt;br /&gt;
This is equal to just past in the [[file]] on this row.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Global:setRestoreData(nil data)|setRestoreData]](nil data)&lt;br /&gt;
|Set restore data object. if data is set and the Lua script crashes the restore function is called with the first parameter being the restore data object.&lt;br /&gt;
If nil is set as data no restore function is called upon a Lua script crash.&lt;br /&gt;
|-&lt;br /&gt;
|nil,nil&lt;br /&gt;
|[[Global:ipairs(table tab)|ipairs]]([[table]] tab)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|nil,nil&lt;br /&gt;
|[[Global:pairs(table tab)|pairs]]([[table]] tab)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|nil,nil&lt;br /&gt;
|[[Global:spairs(table tab)|spairs]]([[table]] tab)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Global:assert(object input1,string output)|assert]](object input1,string output)&lt;br /&gt;
|if input1 is false or nil, it will raises an error and print the output message&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Global:abort()|abort]]()&lt;br /&gt;
|crashes the lua script&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Global:abort(string message)|abort]]([[string]] message)&lt;br /&gt;
|crashes the lua script with a message&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Global:type(nil variable)|type]](nil variable)&lt;br /&gt;
|returns the type name of the lua object&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Global:print(string msg)|print]](string msg)&lt;br /&gt;
|Print to console&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Global:print(Text msg)|print]]([[Text]] msg)&lt;br /&gt;
|Print to console&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Global:doLineCollide(Line3D line)|doLineCollide]]([[Line3D]] line)&lt;br /&gt;
|Do a [[collision]] against the entire world.&lt;br /&gt;
|-&lt;br /&gt;
|[[VectorVec3]]&lt;br /&gt;
|[[Global:createHullList3d(Mesh aMesh)|createHullList3d]]([[Mesh]] aMesh)&lt;br /&gt;
|Convert a [[mesh]] into a 3d hull.&lt;br /&gt;
|-&lt;br /&gt;
|[[VectorVec2]]&lt;br /&gt;
|[[Global:createHullList2d(Mesh aMesh)|createHullList2d]]([[Mesh]] aMesh)&lt;br /&gt;
|Convert a [[mesh]] into a 2d hull.&lt;br /&gt;
|-&lt;br /&gt;
|[[Matrix]]&lt;br /&gt;
|[[Global:generateRotationMatrix(float x, float y, float z, float rotation)|generateRotationMatrix]](float x, float y, float z, float rotation)&lt;br /&gt;
|Create a rotation [[matrix]].&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Global:ConvertToCamera(SceneNode node)|ConvertToCamera]]([[SceneNode]] node)&lt;br /&gt;
|Typecast node to [[camera]].&lt;br /&gt;
|-&lt;br /&gt;
|[[Panel]]&lt;br /&gt;
|[[Global:convertToPanel(LuaObject node)|convertToPanel]](LuaObject node)&lt;br /&gt;
|Typecast node to [[Panel]].&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Global:getScreenPosInsideAnyForm(Vec2 pos)|getScreenPosInsideAnyForm]]([[Vec2]] pos)&lt;br /&gt;
|Return if the screen cordinate is inside any visible [[form]].&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Global:tobool(bool value)|tobool]](bool value)&lt;br /&gt;
|Convert input to boolean.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Global:tobool(float value)|tobool]](float value)&lt;br /&gt;
|Convert input to boolean. 0 is false every thing else is true&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Global:tobool(string value)|tobool]](string value)&lt;br /&gt;
|Convert input to boolean. &amp;quot;true&amp;quot; is true everything else is false&lt;br /&gt;
|-&lt;br /&gt;
|number&lt;br /&gt;
|[[Global:tonumber(number value)|tonumber]](number value)&lt;br /&gt;
|Convert input to number.&lt;br /&gt;
|-&lt;br /&gt;
|number&lt;br /&gt;
|[[Global:tonumber(bool value)|tonumber]](bool value)&lt;br /&gt;
|Convert input to number. return 0 or 1&lt;br /&gt;
|-&lt;br /&gt;
|number&lt;br /&gt;
|[[Global:tonumber(string value)|tonumber]](string value)&lt;br /&gt;
|Convert input to number.&lt;br /&gt;
|-&lt;br /&gt;
|number&lt;br /&gt;
|[[Global:tonumber(Text value)|tonumber]](Text value)&lt;br /&gt;
|Convert input to number.&lt;br /&gt;
|-&lt;br /&gt;
|number&lt;br /&gt;
|[[Global:tonumber(nil value)|tonumber]](nil value)&lt;br /&gt;
|Convert input to number.&lt;br /&gt;
|-&lt;br /&gt;
|number&lt;br /&gt;
|[[Global:tonumber(Object value)|tonumber]](Object value)&lt;br /&gt;
|Convert input to number.&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Global:tostring(nil)|tostring]](nil)&lt;br /&gt;
|Convert input to string.&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Global:tostring(boolean value)|tostring]](boolean value)&lt;br /&gt;
|Convert boolean to string.&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Global:tostring(string value)|tostring]](string value)&lt;br /&gt;
|Convert string to string.&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Global:tostring(table tab)|tostring]](table tab)&lt;br /&gt;
|Converts a table to string. can handle number,string,boolean,Vec2,Vec3,Vec4 and tables. The Table must be in a tree structure, as recursion will create an error&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Global:tabToStrMinimal(table tab)|tabToStrMinimal]](table tab)&lt;br /&gt;
|Converts a table to string. return a minimalistic string without unnecessary spacing and line breaks. return like &amp;quot;{param1=1,param2=23}&amp;quot;.&lt;br /&gt;
|-&lt;br /&gt;
|table&lt;br /&gt;
|[[Global:totable(string str)|totable]](string str)&lt;br /&gt;
|Must be Lua legal code and start with a table like table = {param1=1,param2=&amp;quot;str&amp;quot;}. can handle number,string,boolean,Vec2,Vec3,Vec4 and tables. The Table must be in a tree structure, as recursion will create an error.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2]]&lt;br /&gt;
|[[Global:tovec2(string str)|tovec2]](string str)&lt;br /&gt;
|Convert String of format &amp;quot;Vec2(1,2)&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec3]]&lt;br /&gt;
|[[Global:tovec3(string str)|tovec3]](string str)&lt;br /&gt;
|Convert String of format &amp;quot;Vec3(1,2,3)&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec4]]&lt;br /&gt;
|[[Global:tovec4(string str)|tovec4]](string str)&lt;br /&gt;
|Convert String of format &amp;quot;Vec4(1,2,3,4)&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|number&lt;br /&gt;
|[[Global:getActiveScriptCounterTable()|getActiveScriptCounterTable]]()&lt;br /&gt;
|return the count of running script&lt;br /&gt;
|-&lt;br /&gt;
|{ name=string(), time=number(), count=number() }&lt;br /&gt;
|[[Global:getScriptTimeTable()|getScriptTimeTable]]()&lt;br /&gt;
|return a table of all script and amount of work time&lt;br /&gt;
|-&lt;br /&gt;
|{ name=string(), time=number(), count=number() }&lt;br /&gt;
|[[Global:getGroupScriptTimeTable()|getGroupScriptTimeTable]]()&lt;br /&gt;
|return a table of all script and amount of work time&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Global functions (map creation)==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Global:abort()|abort]]()&lt;br /&gt;
|Crashes the script&lt;br /&gt;
|-&lt;br /&gt;
|table&lt;br /&gt;
|[[Global:getCrashTable()|getCrashTable]]()&lt;br /&gt;
|Get crash table.&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=Billboard&amp;diff=178</id>
		<title>Billboard</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=Billboard&amp;diff=178"/>
		<updated>2025-08-03T12:21:35Z</updated>

		<summary type="html">&lt;p&gt;Anders: /* Functions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:BillboardExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Constructor==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|Billboard()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:clear()|clear]]()&lt;br /&gt;
|Clear billborad from all stored data.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setBool(string name, bool value)|setInt]]([[string]] name, bool value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setInt(string name, int value)|setInt]]([[string]] name, int value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setFloat(string name, float value)|setFloat]]([[string]] name, float value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setDouble(string name, float value)|setDouble]]([[string]] name, float value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setString(string name, string value)|setString]]([[string]] name, [[string]] value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setVec2(string name, Vec2 value)|setVec2]]([[string]] name, [[Vec2]] value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setVec3(string name, Vec3 value)|setVec3]]([[string]] name, [[Vec3]] value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setVec4(string name, Vec4 value)|setVec4]]([[string]] name, [[Vec4]] value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setMatrix(string name, Matrix value)|setMatrix]]([[string]] name, [[Matrix]] value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setVectorVec2(string name, VectorVec2 value)|setVectorVec2]]([[string]] name, [[VectorVec2]] value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setVectorVec3(string name, VectorVec3 value)|setVectorVec3]]([[string]] name, [[VectorVec3]] value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setModel(string name, Model value)|setModel]]([[string]] name, [[Model]] value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setKeyBind(string name, KeyBind value)|setKeyBind]]([[string]] name, [[KeyBind]] value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setTexture(string name, Texture value)|setTexture]]([[string]] name, [[Texture]] value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setShader(string name, Shader value)|setShader]]([[string]] name, [[Shader]] value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setNodeMover(string name, NodeMover value)|setNodeMover]]([[string]] name, [[NodeMover]] value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setSceneNode(string name, SceneNode value)|setSceneNode]]([[string]] name, [[SceneNode]] value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setScene2DNode(string name, Scene2DNode value)|setScene2DNode]]([[string]] name, [[Scene2DNode]] value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setPanel(string name, Panel value)|setPanel]]([[string]] name, [[Panel]] value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setTable(string name, table value)|setTable]]([[string]] name, [[table]] value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Billboard:exist(string name)|exist]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Billboard:erase(string name)|erase]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[string]]&lt;br /&gt;
|[[Billboard:toString()|toString]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Billboard:getBool(string name)|getBool]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[Billboard:getInt(string name)|getInt]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Billboard:getFloat(string name)|getFloat]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|double&lt;br /&gt;
|[[Billboard:getDouble(string name)|getDouble]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[string]]&lt;br /&gt;
|[[Billboard:getString(string name)|getString]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2]]&lt;br /&gt;
|[[Billboard:getVec2(string name)|getVec2]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec3]]&lt;br /&gt;
|[[Billboard:getVec3(string name)|getVec3]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec4]]&lt;br /&gt;
|[[Billboard:getVec4(string name)|getVec4]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[VectorVec2]]&lt;br /&gt;
|[[Billboard:getVectorVec2(string name)|getVectorVec2]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[VectorVec3]]&lt;br /&gt;
|[[Billboard:getVectorVec3(string name)|getVectorVec3]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Matrix]]&lt;br /&gt;
|[[Billboard:getMatrix(string name)|getMatrix]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Model]]&lt;br /&gt;
|[[Billboard:getModel(string name)|getModel]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[KeyBind]]&lt;br /&gt;
|[[Billboard:getKeyBind(string name)|getKeyBind]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Texture]]&lt;br /&gt;
|[[Billboard:getTexture(string name)|getTexture]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Shader]]&lt;br /&gt;
|[[Billboard:getShader(string name)|getShader]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[NodeMover]]&lt;br /&gt;
|[[Billboard:getNodeMover(string name)|getNodeMover]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[SceneNode]]&lt;br /&gt;
|[[Billboard:getSceneNode(string name)|getSceneNode]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Scene2DNode]]&lt;br /&gt;
|[[Billboard:getScene2DNode(string name)|getScene2DNode]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Panel]]&lt;br /&gt;
|[[Billboard:getPanel(string name)|getPanel]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[table]]&lt;br /&gt;
|[[Billboard:getTable(string name)|getTable]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|{string()}&lt;br /&gt;
|[[Billboard:getKeys()|getKeys]]()&lt;br /&gt;
|Return a table of all items name stored in this billboard.&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=Billboard&amp;diff=177</id>
		<title>Billboard</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=Billboard&amp;diff=177"/>
		<updated>2025-08-03T12:21:10Z</updated>

		<summary type="html">&lt;p&gt;Anders: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:BillboardExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Constructor==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|Billboard()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:clear()|clear]]()&lt;br /&gt;
|Clear billborad from all stored data.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setBool(string name, bool value)|setInt]]([[string]] name, bool value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setInt(string name, int value)|setInt]]([[string]] name, int value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setFloat(string name, float value)|setFloat]]([[string]] name, float value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setDouble(string name, float value)|setDouble]]([[string]] name, float value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setString(string name, string value)|setString]]([[string]] name, [[string]] value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setVec2(string name, Vec2 value)|setVec2]]([[string]] name, [[Vec2]] value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setVec3(string name, Vec3 value)|setVec3]]([[string]] name, [[Vec3]] value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setVec4(string name, Vec4 value)|setVec4]]([[string]] name, [[Vec4]] value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setMatrix(string name, Matrix value)|setMatrix]]([[string]] name, [[Matrix]] value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setVectorVec2(string name, VectorVec2 value)|setVectorVec2]]([[string]] name, [[VectorVec2]] value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setVectorVec3(string name, VectorVec3 value)|setVectorVec3]]([[string]] name, [[VectorVec3]] value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setModel(string name, Model value)|setModel]]([[string]] name, [[Model]] value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setKeyBind(string name, KeyBind value)|setKeyBind]]([[string]] name, [[KeyBind]] value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setTexture(string name, Texture value)|setTexture]]([[string]] name, [[Texture]] value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setShader(string name, Shader value)|setShader]]([[string]] name, [[Shader]] value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setNodeMover(string name, NodeMover value)|setNodeMover]]([[string]] name, [[NodeMover]] value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setSceneNode(string name, SceneNode value)|setSceneNode]]([[string]] name, [[SceneNode]] value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setScene2DNode(string name, Scene2DNode value)|setScene2DNode]]([[string]] name, [[Scene2DNode]] value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setPanel(string name, Panel value)|setPanel]]([[string]] name, [[Panel]] value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Billboard:setTable(string name, table value)|setTable]]([[string]] name, [[table]] value)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Billboard:exist(string name)|exist]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Billboard:erase(string name)|erase]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Billboard:toString()|toString]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Billboard:getBool(string name)|getBool]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[Billboard:getInt(string name)|getInt]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Billboard:getFloat(string name)|getFloat]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|double&lt;br /&gt;
|[[Billboard:getDouble(string name)|getDouble]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[string]]&lt;br /&gt;
|[[Billboard:getString(string name)|getString]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2]]&lt;br /&gt;
|[[Billboard:getVec2(string name)|getVec2]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec3]]&lt;br /&gt;
|[[Billboard:getVec3(string name)|getVec3]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec4]]&lt;br /&gt;
|[[Billboard:getVec4(string name)|getVec4]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[VectorVec2]]&lt;br /&gt;
|[[Billboard:getVectorVec2(string name)|getVectorVec2]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[VectorVec3]]&lt;br /&gt;
|[[Billboard:getVectorVec3(string name)|getVectorVec3]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Matrix]]&lt;br /&gt;
|[[Billboard:getMatrix(string name)|getMatrix]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Model]]&lt;br /&gt;
|[[Billboard:getModel(string name)|getModel]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[KeyBind]]&lt;br /&gt;
|[[Billboard:getKeyBind(string name)|getKeyBind]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Texture]]&lt;br /&gt;
|[[Billboard:getTexture(string name)|getTexture]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Shader]]&lt;br /&gt;
|[[Billboard:getShader(string name)|getShader]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[NodeMover]]&lt;br /&gt;
|[[Billboard:getNodeMover(string name)|getNodeMover]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[SceneNode]]&lt;br /&gt;
|[[Billboard:getSceneNode(string name)|getSceneNode]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Scene2DNode]]&lt;br /&gt;
|[[Billboard:getScene2DNode(string name)|getScene2DNode]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Panel]]&lt;br /&gt;
|[[Billboard:getPanel(string name)|getPanel]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[table]]&lt;br /&gt;
|[[Billboard:getTable(string name)|getTable]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|{string()}&lt;br /&gt;
|[[Billboard:getKeys()|getKeys]]()&lt;br /&gt;
|Return a table of all items name stored in this billboard.&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=Vec2i&amp;diff=176</id>
		<title>Vec2i</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=Vec2i&amp;diff=176"/>
		<updated>2025-08-03T12:19:30Z</updated>

		<summary type="html">&lt;p&gt;Anders: /* Constructor */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:Vec2iExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Members==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
&lt;br /&gt;
!|type&lt;br /&gt;
!|variable&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|x&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|y&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Constructor==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|Vec2i(float x, float y)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Vec2i(float xy)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Vec2i([[Vec2i]] vactor)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Vec2i()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Vec2i:dot()|dot]]()&lt;br /&gt;
|Returns the dot product of this vec with itself.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Vec2i:dot(Vec2i vector)|dot]]([[Vec2i]] vector)&lt;br /&gt;
|Return the dot product of this with vector.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Vec2i:length()|length]]()&lt;br /&gt;
|Returns the length of this vector.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Vec2i:getXYDist()|getXYDist]]()&lt;br /&gt;
|Returns x + y.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Vec2i:negate()|negate]]()&lt;br /&gt;
|Negate the vector.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Vec2i:clear()|clear]]()&lt;br /&gt;
|Set vector to zero.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Vec2i:infinity()|infinity]]()&lt;br /&gt;
|Set vector to infinity.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Vec2i:normalize()|normalize]]()&lt;br /&gt;
|Normalize the vector and return the old length.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2i]]&lt;br /&gt;
|[[Vec2i:normalizeV()|normalizeV]]()&lt;br /&gt;
|Return a copy and normalize the return vec.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Vec2i:interPolate(Vec2i vector1, Vec2ivector2, float weight)|interPolate]]([[Vec2i]] vector1, [[Vec2i]] vector2, float weight)&lt;br /&gt;
|Inter polate a vector bettwen two values. weight 0 returns vector1 and at weight 1 vector2 is returned&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2i]]&lt;br /&gt;
|[[Vec2i:interPolateV(Vec2i vector1, Vec2i vector2, float weight)|interPolateV]]([[Vec2i]] vector1, [[Vec2i]] vector2, float weight)&lt;br /&gt;
|Returns a Inter polate a vector bettwen two values. weight 0 returns vector1 and at weight 1 vector2 is returned&lt;br /&gt;
Return (vector1 * weight) + (vector2 * (1-weight));&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Vec2i:isZero()|isZero]]()&lt;br /&gt;
|Returns true when vector length is zero&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Vec2i:isInfinity()|isInfinity]]()&lt;br /&gt;
|Returns true when vetor length is infinity&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Vec2i:minimize(Vec2i vec)|minimize]]([[Vec2i]] vector)&lt;br /&gt;
|Keep the minimum x and y value from this vector and vec&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Vec2i:maximize(Vec2i vec)|maximize]]([[Vec2i]] vector)&lt;br /&gt;
|Keep the maximum x and y value from this vector and vec&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Operators==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2i]]&lt;br /&gt;
|[[Vec2i]] + [[Vec2i]]&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2i]]&lt;br /&gt;
|[[Vec2i]] - [[Vec2i]]&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2i]]&lt;br /&gt;
|[[Vec2i]] * float&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2i]]&lt;br /&gt;
|[[Vec2i]] / float&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Vec2i]] == float&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=NodeMesh&amp;diff=175</id>
		<title>NodeMesh</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=NodeMesh&amp;diff=175"/>
		<updated>2025-08-01T13:54:10Z</updated>

		<summary type="html">&lt;p&gt;Anders: /* Functions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:NodeMeshExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Inheritance==&lt;br /&gt;
[[RenderNode]]&lt;br /&gt;
&lt;br /&gt;
==Static functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|[[NodeMesh]]&lt;br /&gt;
|[[NodeMesh:new()|new]]()&lt;br /&gt;
|Create a new Instance of the the NodeMesh&lt;br /&gt;
|-&lt;br /&gt;
|[[NodeMesh]]&lt;br /&gt;
|[[NodeMesh:new(RenderMode renderMode)|new]]([[RenderMode]] renderMode)&lt;br /&gt;
|Create a new Instance of the the NodeMesh&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:clearMesh()|clearMesh]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertexType(VertexType in1)|setVertexType]]([[VertexType]] in1)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertexType(VertexType in1,VertexType in2)|setVertexType]]([[VertexType]] in1, [[VertexType]] in2)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertexType(VertexType in1,VertexType in2, VertexType in3)|setVertexType]]([[VertexType]] in1, [[VertexType]] in2, [[VertexType]] in3)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertexType(VertexType in1,VertexType in2, VertexType in3, VertexType in4)|setVertexType]]([[VertexType]] in1, [[VertexType]] in2, [[VertexType]] in3, [[VertexType]] in4)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertexType(VertexType in1,VertexType in2, VertexType in3, VertexType in4, VertexType in5)|setVertexType]]([[VertexType]] in1, [[VertexType]] in2, [[VertexType]] in3, [[VertexType]] in4, [[VertexType]] in5)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertexType(VertexType in1,VertexType in2, VertexType in3, VertexType in4, VertexType in5, VertexType in6)|setVertexType]]([[VertexType]] in1, [[VertexType]] in2, [[VertexType]] in3, [[VertexType]] in4, [[VertexType]] in5, [[VertexType]] in6)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertexType(VertexType in1,VertexType in2, VertexType in3, VertexType in4, VertexType in5, VertexType in6, VertexType in7)|setVertexType]]([[VertexType]] in1, [[VertexType]] in2, [[VertexType]] in3, [[VertexType]] in4, [[VertexType]] in5, [[VertexType]] in6, [[VertexType]] in7)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertexType(VertexType in1,VertexType in2, VertexType in3, VertexType in4, VertexType in5, VertexType in6, VertexType in7, VertexType in8)|setVertexType]]([[VertexType]] in1, [[VertexType]] in2, [[VertexType]] in3, [[VertexType]] in4, [[VertexType]] in5, [[VertexType]] in6, [[VertexType]] in7, [[VertexType]] in8)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:bindVertexToShaderName(string name1)|bindVertexToShaderName]](string name1)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:bindVertexToShaderName(string name1, string name2)|bindVertexToShaderName]](string name1, string name2)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:bindVertexToShaderName(string name1, string name2, string name3)|bindVertexToShaderName]](string name1, string name2, string name3)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:bindVertexToShaderName(string name1, string name2, string name3, string name4)|bindVertexToShaderName]](string name1, string name2, string name3, string name4)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:bindVertexToShaderName(string name1, string name2, string name3, string name4, string name5)|bindVertexToShaderName]](string name1, string name2, string name3, string name4, string name5)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:bindVertexToShaderName(string name1, string name2, string name3, string name4, string name5, string name6)|bindVertexToShaderName]](string name1, string name2, string name3, string name4, string name5, string name6)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:bindVertexToShaderName(string name1, string name2, string name3, string name4, string name5, string name6, string name7)|bindVertexToShaderName]](string name1, string name2, string name3, string name4, string name5, string name6, string name7)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:bindVertexToShaderName(string name1, string name2, string name3, string name4, string name5, string name6, string name7, string name8)|bindVertexToShaderName]](string name1, string name2, string name3, string name4, string name5, string name6, string name7, string name8)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec4]]&lt;br /&gt;
|[[NodeMesh:getVertex(int index)|getVertex]](int index)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec4]]&lt;br /&gt;
|[[NodeMesh:getNormal(int index)|getNormal]](int index)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2]]&lt;br /&gt;
|[[NodeMesh:getUvCoord(int index)|getUvCoord]](int index)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec4]]&lt;br /&gt;
|[[NodeMesh:getColor(int index)|getColor]](int index)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec4]]&lt;br /&gt;
|[[NodeMesh:getTangent(int index)|getTangent]](int index)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[NodeMesh:getIndex(int index)|getIndex]](int index)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[NodeMesh:getNumVertex()|getNumVertex]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[NodeMesh:getNumNormal()|getNumNormal]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[NodeMesh:getNumUvCoord()|getNumUvCoord]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[NodeMesh:getNumColor()|getNumColor]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[NodeMesh:getNumTangents()|getNumTangents]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[NodeMesh:getNumIndex()|getNumIndex]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:removeVertex()|removeVertex]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:removeNormal()|removeNormal]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:removeUvCoord()|removeUvCoord]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:removeColor()|removeColor]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:removeTangent()|removeTangent]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:removeIndex()|removeIndex]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setPositions(Object)|setPositions]](Object)&lt;br /&gt;
|Set the full position vertex Array on once call support [[Vec3]] or [[Vec4]]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setPositionsVec3(Object)|setPositionsVec3]](Object)&lt;br /&gt;
|Set the full position vertex Array on once call, takes [[Vec3]] faster then the general setPositions function&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setPositionsVec4(Object)|setPositionsVec4]](Object)&lt;br /&gt;
|Set the full position vertex Array on once call, takes [[Vec4]] faster then the general setPositions function&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setNormals(Object)|setNormals]](Object)&lt;br /&gt;
|Set the full normal vertex Array in one call, takes [[Vec3]]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setUvCoords(Object)|setUvCoords]](Object)&lt;br /&gt;
|Set the full uvCoords vertex Array in one call, takes [[Vec2]]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setColors(Object)|setColors]](Object)&lt;br /&gt;
|Set the full Color vertex Array in one call, takes [[Vec3]] or optionally [[Vec4]]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setTangents(Object)|setTangents]](Object)&lt;br /&gt;
|Set the full Tagent vertex Array in one call, takes [[Vec3]]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setIndices(Object)|setIndices]](Object)&lt;br /&gt;
|Set the all indices Array in one call, takes [[number]]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setBoneWeights(Object)|setBoneWeights]](Object)&lt;br /&gt;
|Set the all Bone weights Array in one call, takes [[Vec3()]]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setBoneIds(Object)|setBoneIds]](Object)&lt;br /&gt;
|Set the all Bone ID&#039;s Array in one call, takes [[number]]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertex(int index, Vec4 vertex)|setVertex]](int index, [[Vec4]] vertex)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setNormal(int index, Vec4 normal)|setNormal]](int index, [[Vec4]] normal)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setUvCoord(int index, Vec2 uvCoord)|setUvCoord]](int index, [[Vec2]] uvCoord)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setColor(int index, Vec4 color)|setColor]](int index, [[Vec4]] color)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setTangent(int index, Vec4 tangent)|setTangent]](int index, [[Vec4]] tangent)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setIndex(int index, int index)|setIndex]](int index, int index)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addVertex(Object in1)|addVertex]]([[Object]] in1)&lt;br /&gt;
|When the setVertexType has been set this function can be used to add an entire vertex at once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addVertex(Object in1, Object in2)|addVertex]]([[Object]] in1, [[Object]] in2,)&lt;br /&gt;
|When the setVertexType has been set this function can be used to add an entire vertex at once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addVertex(Object in1, Object in2, Object in3)|addVertex]]([[Object]] in1, [[Object]] in2, [[Object]] in3)&lt;br /&gt;
|When the setVertexType has been set this function can be used to add an entire vertex at once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addVertex(Object in1, Object in2, Object in3, Object in4)|addVertex]]([[Object]] in1, [[Object]] in2, [[Object]] in3, [[Object]] in4)&lt;br /&gt;
|When the setVertexType has been set this function can be used to add an entire vertex at once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addVertex(Object in1, Object in2, Object in3, Object in4, Object in5)|addVertex]]([[Object]] in1, [[Object]] in2, [[Object]] in3, [[Object]] in4, [[Object]] in5)&lt;br /&gt;
|When the setVertexType has been set this function can be used to add an entire vertex at once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addVertex(Object in1, Object in2, Object in3, Object in4, Object in5, Object in6)|addVertex]]([[Object]] in1, [[Object]] in2, [[Object]] in3, [[Object]] in4, [[Object]] in5, [[Object]] in6)&lt;br /&gt;
|When the setVertexType has been set this function can be used to add an entire vertex at once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addVertex(Object in1, Object in2, Object in3, Object in4, Object in5, Object in6, Object in7)|addVertex]]([[Object]] in1, [[Object]] in2, [[Object]] in3, [[Object]] in4, [[Object]] in5, [[Object]] in6, [[Object]] in7)&lt;br /&gt;
|When the setVertexType has been set this function can be used to add an entire vertex at once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addVertex(Object in1, Object in2, Object in3, Object in4, Object in5, Object in6, Object in7, Object in8)|addVertex]]([[Object]] in1, [[Object]] in2, [[Object]] in3, [[Object]] in4, [[Object]] in5, [[Object]] in6, [[Object]] in7, [[Object]] in8)&lt;br /&gt;
|When the setVertexType has been set this function can be used to add an entire vertex at once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addPosition(Vec3 vertex)|addPosition]]([[Vec3]] vertex)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addPosition(Vec4 vertex)|addPosition]]([[Vec4]] vertex)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addNormal(Vec3 normal)|addNormal]]([[Vec3]] normal)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addNormal(Vec4 normal)|addNormal]]([[Vec4]] normal)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addUvCoord(Vec2 uvCoord)|addUvCoord]]([[Vec2]] uvCoord)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addColor(Vec3 color)|addColor]]([[Vec3]] color)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addColor(Vec4 color)|addColor]]([[Vec4]] color)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addTangent(Vec3 tangent)|addTangent]]([[Vec3]] tangent)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addTangent(Vec4 tangent)|addTangent]]([[Vec4]] tangent)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addIndex(int index)|addIndex]](int index)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addTriangleIndex(int index1, int index2, int index3)|addTriangleIndex]](int index1, int index2, int index3)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[NodeMesh:addMesh(Mesh mesh)|addMesh]]([[Mesh]] mesh)&lt;br /&gt;
|This will make a copy of the mesh in the original position of the mesh.&lt;br /&gt;
Returns true when a copy was made else return false.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:compile()|compile]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=NodeMesh&amp;diff=174</id>
		<title>NodeMesh</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=NodeMesh&amp;diff=174"/>
		<updated>2025-08-01T13:45:16Z</updated>

		<summary type="html">&lt;p&gt;Anders: /* Functions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:NodeMeshExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Inheritance==&lt;br /&gt;
[[RenderNode]]&lt;br /&gt;
&lt;br /&gt;
==Static functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|[[NodeMesh]]&lt;br /&gt;
|[[NodeMesh:new()|new]]()&lt;br /&gt;
|Create a new Instance of the the NodeMesh&lt;br /&gt;
|-&lt;br /&gt;
|[[NodeMesh]]&lt;br /&gt;
|[[NodeMesh:new(RenderMode renderMode)|new]]([[RenderMode]] renderMode)&lt;br /&gt;
|Create a new Instance of the the NodeMesh&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:clearMesh()|clearMesh]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertexType(VertexType in1)|setVertexType]]([[VertexType]] in1)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertexType(VertexType in1,VertexType in2)|setVertexType]]([[VertexType]] in1, [[VertexType]] in2)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertexType(VertexType in1,VertexType in2, VertexType in3)|setVertexType]]([[VertexType]] in1, [[VertexType]] in2, [[VertexType]] in3)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertexType(VertexType in1,VertexType in2, VertexType in3, VertexType in4)|setVertexType]]([[VertexType]] in1, [[VertexType]] in2, [[VertexType]] in3, [[VertexType]] in4)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertexType(VertexType in1,VertexType in2, VertexType in3, VertexType in4, VertexType in5)|setVertexType]]([[VertexType]] in1, [[VertexType]] in2, [[VertexType]] in3, [[VertexType]] in4, [[VertexType]] in5)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertexType(VertexType in1,VertexType in2, VertexType in3, VertexType in4, VertexType in5, VertexType in6)|setVertexType]]([[VertexType]] in1, [[VertexType]] in2, [[VertexType]] in3, [[VertexType]] in4, [[VertexType]] in5, [[VertexType]] in6)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertexType(VertexType in1,VertexType in2, VertexType in3, VertexType in4, VertexType in5, VertexType in6, VertexType in7)|setVertexType]]([[VertexType]] in1, [[VertexType]] in2, [[VertexType]] in3, [[VertexType]] in4, [[VertexType]] in5, [[VertexType]] in6, [[VertexType]] in7)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertexType(VertexType in1,VertexType in2, VertexType in3, VertexType in4, VertexType in5, VertexType in6, VertexType in7, VertexType in8)|setVertexType]]([[VertexType]] in1, [[VertexType]] in2, [[VertexType]] in3, [[VertexType]] in4, [[VertexType]] in5, [[VertexType]] in6, [[VertexType]] in7, [[VertexType]] in8)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:bindVertexToShaderName(string name1)|bindVertexToShaderName]](string name1)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:bindVertexToShaderName(string name1, string name2)|bindVertexToShaderName]](string name1, string name2)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:bindVertexToShaderName(string name1, string name2, string name3)|bindVertexToShaderName]](string name1, string name2, string name3)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:bindVertexToShaderName(string name1, string name2, string name3, string name4)|bindVertexToShaderName]](string name1, string name2, string name3, string name4)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:bindVertexToShaderName(string name1, string name2, string name3, string name4, string name5)|bindVertexToShaderName]](string name1, string name2, string name3, string name4, string name5)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:bindVertexToShaderName(string name1, string name2, string name3, string name4, string name5, string name6)|bindVertexToShaderName]](string name1, string name2, string name3, string name4, string name5, string name6)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:bindVertexToShaderName(string name1, string name2, string name3, string name4, string name5, string name6, string name7)|bindVertexToShaderName]](string name1, string name2, string name3, string name4, string name5, string name6, string name7)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:bindVertexToShaderName(string name1, string name2, string name3, string name4, string name5, string name6, string name7, string name8)|bindVertexToShaderName]](string name1, string name2, string name3, string name4, string name5, string name6, string name7, string name8)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec4]]&lt;br /&gt;
|[[NodeMesh:getVertex(int index)|getVertex]](int index)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec4]]&lt;br /&gt;
|[[NodeMesh:getNormal(int index)|getNormal]](int index)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2]]&lt;br /&gt;
|[[NodeMesh:getUvCoord(int index)|getUvCoord]](int index)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec4]]&lt;br /&gt;
|[[NodeMesh:getColor(int index)|getColor]](int index)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec4]]&lt;br /&gt;
|[[NodeMesh:getTangent(int index)|getTangent]](int index)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[NodeMesh:getIndex(int index)|getIndex]](int index)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[NodeMesh:getNumVertex()|getNumVertex]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[NodeMesh:getNumNormal()|getNumNormal]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[NodeMesh:getNumUvCoord()|getNumUvCoord]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[NodeMesh:getNumColor()|getNumColor]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[NodeMesh:getNumTangents()|getNumTangents]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[NodeMesh:getNumIndex()|getNumIndex]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:removeVertex()|removeVertex]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:removeNormal()|removeNormal]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:removeUvCoord()|removeUvCoord]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:removeColor()|removeColor]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:removeTangent()|removeTangent]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:removeIndex()|removeIndex]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setPositions()|setPositions]]()&lt;br /&gt;
|Set the full position vertex Array on once call support [[Vec3]] or [[Vec4]]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setPositionsVec3({Vec3()})|setPositionsVec3]]({Vec3()})&lt;br /&gt;
|Set the full position vertex Array on once call, takes [[Vec3]] faster then the general setPositions function&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setPositionsVec4({Vec4()})|setPositionsVec4]]({Vec4()})&lt;br /&gt;
|Set the full position vertex Array on once call, takes [[Vec4]] faster then the general setPositions function&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setNormals({Vec3()})|setNormals]]({Vec3()})&lt;br /&gt;
|Set the full normal vertex Array in one call, takes [[Vec3]]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setUvCoords({Vec2()})|setUvCoords]]({Vec2()})&lt;br /&gt;
|Set the full uvCoords vertex Array in one call, takes [[Vec2]]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setColors({})|setColors]]({})&lt;br /&gt;
|Set the full Color vertex Array in one call, takes [[Vec3]] or optionally [[Vec4]]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setTangents({Vec3()})|setTangents]]({Vec3()})&lt;br /&gt;
|Set the full Tagent vertex Array in one call, takes [[Vec3]]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setIndices({number})|setIndices]]({number})&lt;br /&gt;
|Set the all indices Array in one call, takes [[number]]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setBoneWeights({Vec3()})|setBoneWeights]]({Vec3()})&lt;br /&gt;
|Set the all Bone weights Array in one call, takes [[Vec3()]]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setBoneIds({number})|setBoneIds]]({number})&lt;br /&gt;
|Set the all Bone ID&#039;s Array in one call, takes [[number]]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertex(int index, Vec4 vertex)|setVertex]](int index, [[Vec4]] vertex)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setNormal(int index, Vec4 normal)|setNormal]](int index, [[Vec4]] normal)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setUvCoord(int index, Vec2 uvCoord)|setUvCoord]](int index, [[Vec2]] uvCoord)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setColor(int index, Vec4 color)|setColor]](int index, [[Vec4]] color)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setTangent(int index, Vec4 tangent)|setTangent]](int index, [[Vec4]] tangent)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setIndex(int index, int index)|setIndex]](int index, int index)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addVertex(Object in1)|addVertex]]([[Object]] in1)&lt;br /&gt;
|When the setVertexType has been set this function can be used to add an entire vertex at once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addVertex(Object in1, Object in2)|addVertex]]([[Object]] in1, [[Object]] in2,)&lt;br /&gt;
|When the setVertexType has been set this function can be used to add an entire vertex at once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addVertex(Object in1, Object in2, Object in3)|addVertex]]([[Object]] in1, [[Object]] in2, [[Object]] in3)&lt;br /&gt;
|When the setVertexType has been set this function can be used to add an entire vertex at once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addVertex(Object in1, Object in2, Object in3, Object in4)|addVertex]]([[Object]] in1, [[Object]] in2, [[Object]] in3, [[Object]] in4)&lt;br /&gt;
|When the setVertexType has been set this function can be used to add an entire vertex at once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addVertex(Object in1, Object in2, Object in3, Object in4, Object in5)|addVertex]]([[Object]] in1, [[Object]] in2, [[Object]] in3, [[Object]] in4, [[Object]] in5)&lt;br /&gt;
|When the setVertexType has been set this function can be used to add an entire vertex at once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addVertex(Object in1, Object in2, Object in3, Object in4, Object in5, Object in6)|addVertex]]([[Object]] in1, [[Object]] in2, [[Object]] in3, [[Object]] in4, [[Object]] in5, [[Object]] in6)&lt;br /&gt;
|When the setVertexType has been set this function can be used to add an entire vertex at once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addVertex(Object in1, Object in2, Object in3, Object in4, Object in5, Object in6, Object in7)|addVertex]]([[Object]] in1, [[Object]] in2, [[Object]] in3, [[Object]] in4, [[Object]] in5, [[Object]] in6, [[Object]] in7)&lt;br /&gt;
|When the setVertexType has been set this function can be used to add an entire vertex at once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addVertex(Object in1, Object in2, Object in3, Object in4, Object in5, Object in6, Object in7, Object in8)|addVertex]]([[Object]] in1, [[Object]] in2, [[Object]] in3, [[Object]] in4, [[Object]] in5, [[Object]] in6, [[Object]] in7, [[Object]] in8)&lt;br /&gt;
|When the setVertexType has been set this function can be used to add an entire vertex at once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addPosition(Vec3 vertex)|addPosition]]([[Vec3]] vertex)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addPosition(Vec4 vertex)|addPosition]]([[Vec4]] vertex)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addNormal(Vec3 normal)|addNormal]]([[Vec3]] normal)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addNormal(Vec4 normal)|addNormal]]([[Vec4]] normal)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addUvCoord(Vec2 uvCoord)|addUvCoord]]([[Vec2]] uvCoord)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addColor(Vec3 color)|addColor]]([[Vec3]] color)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addColor(Vec4 color)|addColor]]([[Vec4]] color)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addTangent(Vec3 tangent)|addTangent]]([[Vec3]] tangent)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addTangent(Vec4 tangent)|addTangent]]([[Vec4]] tangent)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addIndex(int index)|addIndex]](int index)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addTriangleIndex(int index1, int index2, int index3)|addTriangleIndex]](int index1, int index2, int index3)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[NodeMesh:addMesh(Mesh mesh)|addMesh]]([[Mesh]] mesh)&lt;br /&gt;
|This will make a copy of the mesh in the original position of the mesh.&lt;br /&gt;
Returns true when a copy was made else return false.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:compile()|compile]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=NodeMesh&amp;diff=173</id>
		<title>NodeMesh</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=NodeMesh&amp;diff=173"/>
		<updated>2025-08-01T13:44:45Z</updated>

		<summary type="html">&lt;p&gt;Anders: /* Functions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:NodeMeshExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Inheritance==&lt;br /&gt;
[[RenderNode]]&lt;br /&gt;
&lt;br /&gt;
==Static functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|[[NodeMesh]]&lt;br /&gt;
|[[NodeMesh:new()|new]]()&lt;br /&gt;
|Create a new Instance of the the NodeMesh&lt;br /&gt;
|-&lt;br /&gt;
|[[NodeMesh]]&lt;br /&gt;
|[[NodeMesh:new(RenderMode renderMode)|new]]([[RenderMode]] renderMode)&lt;br /&gt;
|Create a new Instance of the the NodeMesh&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:clearMesh()|clearMesh]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertexType(VertexType in1)|setVertexType]]([[VertexType]] in1)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertexType(VertexType in1,VertexType in2)|setVertexType]]([[VertexType]] in1, [[VertexType]] in2)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertexType(VertexType in1,VertexType in2, VertexType in3)|setVertexType]]([[VertexType]] in1, [[VertexType]] in2, [[VertexType]] in3)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertexType(VertexType in1,VertexType in2, VertexType in3, VertexType in4)|setVertexType]]([[VertexType]] in1, [[VertexType]] in2, [[VertexType]] in3, [[VertexType]] in4)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertexType(VertexType in1,VertexType in2, VertexType in3, VertexType in4, VertexType in5)|setVertexType]]([[VertexType]] in1, [[VertexType]] in2, [[VertexType]] in3, [[VertexType]] in4, [[VertexType]] in5)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertexType(VertexType in1,VertexType in2, VertexType in3, VertexType in4, VertexType in5, VertexType in6)|setVertexType]]([[VertexType]] in1, [[VertexType]] in2, [[VertexType]] in3, [[VertexType]] in4, [[VertexType]] in5, [[VertexType]] in6)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertexType(VertexType in1,VertexType in2, VertexType in3, VertexType in4, VertexType in5, VertexType in6, VertexType in7)|setVertexType]]([[VertexType]] in1, [[VertexType]] in2, [[VertexType]] in3, [[VertexType]] in4, [[VertexType]] in5, [[VertexType]] in6, [[VertexType]] in7)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertexType(VertexType in1,VertexType in2, VertexType in3, VertexType in4, VertexType in5, VertexType in6, VertexType in7, VertexType in8)|setVertexType]]([[VertexType]] in1, [[VertexType]] in2, [[VertexType]] in3, [[VertexType]] in4, [[VertexType]] in5, [[VertexType]] in6, [[VertexType]] in7, [[VertexType]] in8)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:bindVertexToShaderName(string name1)|bindVertexToShaderName]](string name1)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:bindVertexToShaderName(string name1, string name2)|bindVertexToShaderName]](string name1, string name2)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:bindVertexToShaderName(string name1, string name2, string name3)|bindVertexToShaderName]](string name1, string name2, string name3)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:bindVertexToShaderName(string name1, string name2, string name3, string name4)|bindVertexToShaderName]](string name1, string name2, string name3, string name4)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:bindVertexToShaderName(string name1, string name2, string name3, string name4, string name5)|bindVertexToShaderName]](string name1, string name2, string name3, string name4, string name5)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:bindVertexToShaderName(string name1, string name2, string name3, string name4, string name5, string name6)|bindVertexToShaderName]](string name1, string name2, string name3, string name4, string name5, string name6)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:bindVertexToShaderName(string name1, string name2, string name3, string name4, string name5, string name6, string name7)|bindVertexToShaderName]](string name1, string name2, string name3, string name4, string name5, string name6, string name7)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:bindVertexToShaderName(string name1, string name2, string name3, string name4, string name5, string name6, string name7, string name8)|bindVertexToShaderName]](string name1, string name2, string name3, string name4, string name5, string name6, string name7, string name8)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec4]]&lt;br /&gt;
|[[NodeMesh:getVertex(int index)|getVertex]](int index)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec4]]&lt;br /&gt;
|[[NodeMesh:getNormal(int index)|getNormal]](int index)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2]]&lt;br /&gt;
|[[NodeMesh:getUvCoord(int index)|getUvCoord]](int index)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec4]]&lt;br /&gt;
|[[NodeMesh:getColor(int index)|getColor]](int index)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec4]]&lt;br /&gt;
|[[NodeMesh:getTangent(int index)|getTangent]](int index)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[NodeMesh:getIndex(int index)|getIndex]](int index)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[NodeMesh:getNumVertex()|getNumVertex]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[NodeMesh:getNumNormal()|getNumNormal]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[NodeMesh:getNumUvCoord()|getNumUvCoord]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[NodeMesh:getNumColor()|getNumColor]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[NodeMesh:getNumTangents()|getNumTangents]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[NodeMesh:getNumIndex()|getNumIndex]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:removeVertex()|removeVertex]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:removeNormal()|removeNormal]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:removeUvCoord()|removeUvCoord]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:removeColor()|removeColor]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:removeTangent()|removeTangent]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:removeIndex()|removeIndex]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setPositions( { } )|setPositions]]( { } )&lt;br /&gt;
|Set the full position vertex Array on once call support [[Vec3]] or [[Vec4]]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setPositionsVec3({Vec3()})|setPositionsVec3]]({Vec3()})&lt;br /&gt;
|Set the full position vertex Array on once call, takes [[Vec3]] faster then the general setPositions function&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setPositionsVec4({Vec4()})|setPositionsVec4]]({Vec4()})&lt;br /&gt;
|Set the full position vertex Array on once call, takes [[Vec4]] faster then the general setPositions function&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setNormals({Vec3()})|setNormals]]({Vec3()})&lt;br /&gt;
|Set the full normal vertex Array in one call, takes [[Vec3]]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setUvCoords({Vec2()})|setUvCoords]]({Vec2()})&lt;br /&gt;
|Set the full uvCoords vertex Array in one call, takes [[Vec2]]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setColors({})|setColors]]({})&lt;br /&gt;
|Set the full Color vertex Array in one call, takes [[Vec3]] or optionally [[Vec4]]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setTangents({Vec3()})|setTangents]]({Vec3()})&lt;br /&gt;
|Set the full Tagent vertex Array in one call, takes [[Vec3]]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setIndices({number})|setIndices]]({number})&lt;br /&gt;
|Set the all indices Array in one call, takes [[number]]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setBoneWeights({Vec3()})|setBoneWeights]]({Vec3()})&lt;br /&gt;
|Set the all Bone weights Array in one call, takes [[Vec3()]]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setBoneIds({number})|setBoneIds]]({number})&lt;br /&gt;
|Set the all Bone ID&#039;s Array in one call, takes [[number]]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertex(int index, Vec4 vertex)|setVertex]](int index, [[Vec4]] vertex)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setNormal(int index, Vec4 normal)|setNormal]](int index, [[Vec4]] normal)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setUvCoord(int index, Vec2 uvCoord)|setUvCoord]](int index, [[Vec2]] uvCoord)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setColor(int index, Vec4 color)|setColor]](int index, [[Vec4]] color)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setTangent(int index, Vec4 tangent)|setTangent]](int index, [[Vec4]] tangent)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setIndex(int index, int index)|setIndex]](int index, int index)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addVertex(Object in1)|addVertex]]([[Object]] in1)&lt;br /&gt;
|When the setVertexType has been set this function can be used to add an entire vertex at once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addVertex(Object in1, Object in2)|addVertex]]([[Object]] in1, [[Object]] in2,)&lt;br /&gt;
|When the setVertexType has been set this function can be used to add an entire vertex at once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addVertex(Object in1, Object in2, Object in3)|addVertex]]([[Object]] in1, [[Object]] in2, [[Object]] in3)&lt;br /&gt;
|When the setVertexType has been set this function can be used to add an entire vertex at once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addVertex(Object in1, Object in2, Object in3, Object in4)|addVertex]]([[Object]] in1, [[Object]] in2, [[Object]] in3, [[Object]] in4)&lt;br /&gt;
|When the setVertexType has been set this function can be used to add an entire vertex at once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addVertex(Object in1, Object in2, Object in3, Object in4, Object in5)|addVertex]]([[Object]] in1, [[Object]] in2, [[Object]] in3, [[Object]] in4, [[Object]] in5)&lt;br /&gt;
|When the setVertexType has been set this function can be used to add an entire vertex at once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addVertex(Object in1, Object in2, Object in3, Object in4, Object in5, Object in6)|addVertex]]([[Object]] in1, [[Object]] in2, [[Object]] in3, [[Object]] in4, [[Object]] in5, [[Object]] in6)&lt;br /&gt;
|When the setVertexType has been set this function can be used to add an entire vertex at once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addVertex(Object in1, Object in2, Object in3, Object in4, Object in5, Object in6, Object in7)|addVertex]]([[Object]] in1, [[Object]] in2, [[Object]] in3, [[Object]] in4, [[Object]] in5, [[Object]] in6, [[Object]] in7)&lt;br /&gt;
|When the setVertexType has been set this function can be used to add an entire vertex at once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addVertex(Object in1, Object in2, Object in3, Object in4, Object in5, Object in6, Object in7, Object in8)|addVertex]]([[Object]] in1, [[Object]] in2, [[Object]] in3, [[Object]] in4, [[Object]] in5, [[Object]] in6, [[Object]] in7, [[Object]] in8)&lt;br /&gt;
|When the setVertexType has been set this function can be used to add an entire vertex at once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addPosition(Vec3 vertex)|addPosition]]([[Vec3]] vertex)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addPosition(Vec4 vertex)|addPosition]]([[Vec4]] vertex)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addNormal(Vec3 normal)|addNormal]]([[Vec3]] normal)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addNormal(Vec4 normal)|addNormal]]([[Vec4]] normal)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addUvCoord(Vec2 uvCoord)|addUvCoord]]([[Vec2]] uvCoord)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addColor(Vec3 color)|addColor]]([[Vec3]] color)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addColor(Vec4 color)|addColor]]([[Vec4]] color)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addTangent(Vec3 tangent)|addTangent]]([[Vec3]] tangent)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addTangent(Vec4 tangent)|addTangent]]([[Vec4]] tangent)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addIndex(int index)|addIndex]](int index)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addTriangleIndex(int index1, int index2, int index3)|addTriangleIndex]](int index1, int index2, int index3)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[NodeMesh:addMesh(Mesh mesh)|addMesh]]([[Mesh]] mesh)&lt;br /&gt;
|This will make a copy of the mesh in the original position of the mesh.&lt;br /&gt;
Returns true when a copy was made else return false.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:compile()|compile]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=NodeMesh&amp;diff=172</id>
		<title>NodeMesh</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=NodeMesh&amp;diff=172"/>
		<updated>2025-08-01T13:42:56Z</updated>

		<summary type="html">&lt;p&gt;Anders: /* Functions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:NodeMeshExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Inheritance==&lt;br /&gt;
[[RenderNode]]&lt;br /&gt;
&lt;br /&gt;
==Static functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|[[NodeMesh]]&lt;br /&gt;
|[[NodeMesh:new()|new]]()&lt;br /&gt;
|Create a new Instance of the the NodeMesh&lt;br /&gt;
|-&lt;br /&gt;
|[[NodeMesh]]&lt;br /&gt;
|[[NodeMesh:new(RenderMode renderMode)|new]]([[RenderMode]] renderMode)&lt;br /&gt;
|Create a new Instance of the the NodeMesh&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:clearMesh()|clearMesh]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertexType(VertexType in1)|setVertexType]]([[VertexType]] in1)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertexType(VertexType in1,VertexType in2)|setVertexType]]([[VertexType]] in1, [[VertexType]] in2)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertexType(VertexType in1,VertexType in2, VertexType in3)|setVertexType]]([[VertexType]] in1, [[VertexType]] in2, [[VertexType]] in3)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertexType(VertexType in1,VertexType in2, VertexType in3, VertexType in4)|setVertexType]]([[VertexType]] in1, [[VertexType]] in2, [[VertexType]] in3, [[VertexType]] in4)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertexType(VertexType in1,VertexType in2, VertexType in3, VertexType in4, VertexType in5)|setVertexType]]([[VertexType]] in1, [[VertexType]] in2, [[VertexType]] in3, [[VertexType]] in4, [[VertexType]] in5)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertexType(VertexType in1,VertexType in2, VertexType in3, VertexType in4, VertexType in5, VertexType in6)|setVertexType]]([[VertexType]] in1, [[VertexType]] in2, [[VertexType]] in3, [[VertexType]] in4, [[VertexType]] in5, [[VertexType]] in6)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertexType(VertexType in1,VertexType in2, VertexType in3, VertexType in4, VertexType in5, VertexType in6, VertexType in7)|setVertexType]]([[VertexType]] in1, [[VertexType]] in2, [[VertexType]] in3, [[VertexType]] in4, [[VertexType]] in5, [[VertexType]] in6, [[VertexType]] in7)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertexType(VertexType in1,VertexType in2, VertexType in3, VertexType in4, VertexType in5, VertexType in6, VertexType in7, VertexType in8)|setVertexType]]([[VertexType]] in1, [[VertexType]] in2, [[VertexType]] in3, [[VertexType]] in4, [[VertexType]] in5, [[VertexType]] in6, [[VertexType]] in7, [[VertexType]] in8)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:bindVertexToShaderName(string name1)|bindVertexToShaderName]](string name1)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:bindVertexToShaderName(string name1, string name2)|bindVertexToShaderName]](string name1, string name2)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:bindVertexToShaderName(string name1, string name2, string name3)|bindVertexToShaderName]](string name1, string name2, string name3)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:bindVertexToShaderName(string name1, string name2, string name3, string name4)|bindVertexToShaderName]](string name1, string name2, string name3, string name4)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:bindVertexToShaderName(string name1, string name2, string name3, string name4, string name5)|bindVertexToShaderName]](string name1, string name2, string name3, string name4, string name5)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:bindVertexToShaderName(string name1, string name2, string name3, string name4, string name5, string name6)|bindVertexToShaderName]](string name1, string name2, string name3, string name4, string name5, string name6)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:bindVertexToShaderName(string name1, string name2, string name3, string name4, string name5, string name6, string name7)|bindVertexToShaderName]](string name1, string name2, string name3, string name4, string name5, string name6, string name7)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:bindVertexToShaderName(string name1, string name2, string name3, string name4, string name5, string name6, string name7, string name8)|bindVertexToShaderName]](string name1, string name2, string name3, string name4, string name5, string name6, string name7, string name8)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec4]]&lt;br /&gt;
|[[NodeMesh:getVertex(int index)|getVertex]](int index)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec4]]&lt;br /&gt;
|[[NodeMesh:getNormal(int index)|getNormal]](int index)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2]]&lt;br /&gt;
|[[NodeMesh:getUvCoord(int index)|getUvCoord]](int index)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec4]]&lt;br /&gt;
|[[NodeMesh:getColor(int index)|getColor]](int index)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec4]]&lt;br /&gt;
|[[NodeMesh:getTangent(int index)|getTangent]](int index)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[NodeMesh:getIndex(int index)|getIndex]](int index)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[NodeMesh:getNumVertex()|getNumVertex]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[NodeMesh:getNumNormal()|getNumNormal]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[NodeMesh:getNumUvCoord()|getNumUvCoord]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[NodeMesh:getNumColor()|getNumColor]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[NodeMesh:getNumTangents()|getNumTangents]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[NodeMesh:getNumIndex()|getNumIndex]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:removeVertex()|removeVertex]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:removeNormal()|removeNormal]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:removeUvCoord()|removeUvCoord]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:removeColor()|removeColor]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:removeTangent()|removeTangent]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:removeIndex()|removeIndex]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setPositions({})|setPositions]]({})&lt;br /&gt;
|Set the full position vertex Array on once call support [[Vec3]] or [[Vec4]]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setPositionsVec3({Vec3()})|setPositionsVec3]]({Vec3()})&lt;br /&gt;
|Set the full position vertex Array on once call, takes [[Vec3]] faster then the general setPositions function&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setPositionsVec4({Vec4()})|setPositionsVec4]]({Vec4()})&lt;br /&gt;
|Set the full position vertex Array on once call, takes [[Vec4]] faster then the general setPositions function&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setNormals({Vec3()})|setNormals]]({Vec3()})&lt;br /&gt;
|Set the full normal vertex Array in one call, takes [[Vec3]]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setUvCoords({Vec2()})|setUvCoords]]({Vec2()})&lt;br /&gt;
|Set the full uvCoords vertex Array in one call, takes [[Vec2]]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setColors({})|setColors]]({})&lt;br /&gt;
|Set the full Color vertex Array in one call, takes [[Vec3]] or optionally [[Vec4]]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setTangents({Vec3()})|setTangents]]({Vec3()})&lt;br /&gt;
|Set the full Tagent vertex Array in one call, takes [[Vec3]]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setIndices({number})|setIndices]]({number})&lt;br /&gt;
|Set the all indices Array in one call, takes [[number]]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setBoneWeights({Vec3()})|setBoneWeights]]({Vec3()})&lt;br /&gt;
|Set the all Bone weights Array in one call, takes [[Vec3()]]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setBoneIds({number})|setBoneIds]]({number})&lt;br /&gt;
|Set the all Bone ID&#039;s Array in one call, takes [[number]]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setVertex(int index, Vec4 vertex)|setVertex]](int index, [[Vec4]] vertex)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setNormal(int index, Vec4 normal)|setNormal]](int index, [[Vec4]] normal)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setUvCoord(int index, Vec2 uvCoord)|setUvCoord]](int index, [[Vec2]] uvCoord)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setColor(int index, Vec4 color)|setColor]](int index, [[Vec4]] color)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setTangent(int index, Vec4 tangent)|setTangent]](int index, [[Vec4]] tangent)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:setIndex(int index, int index)|setIndex]](int index, int index)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addVertex(Object in1)|addVertex]]([[Object]] in1)&lt;br /&gt;
|When the setVertexType has been set this function can be used to add an entire vertex at once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addVertex(Object in1, Object in2)|addVertex]]([[Object]] in1, [[Object]] in2,)&lt;br /&gt;
|When the setVertexType has been set this function can be used to add an entire vertex at once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addVertex(Object in1, Object in2, Object in3)|addVertex]]([[Object]] in1, [[Object]] in2, [[Object]] in3)&lt;br /&gt;
|When the setVertexType has been set this function can be used to add an entire vertex at once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addVertex(Object in1, Object in2, Object in3, Object in4)|addVertex]]([[Object]] in1, [[Object]] in2, [[Object]] in3, [[Object]] in4)&lt;br /&gt;
|When the setVertexType has been set this function can be used to add an entire vertex at once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addVertex(Object in1, Object in2, Object in3, Object in4, Object in5)|addVertex]]([[Object]] in1, [[Object]] in2, [[Object]] in3, [[Object]] in4, [[Object]] in5)&lt;br /&gt;
|When the setVertexType has been set this function can be used to add an entire vertex at once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addVertex(Object in1, Object in2, Object in3, Object in4, Object in5, Object in6)|addVertex]]([[Object]] in1, [[Object]] in2, [[Object]] in3, [[Object]] in4, [[Object]] in5, [[Object]] in6)&lt;br /&gt;
|When the setVertexType has been set this function can be used to add an entire vertex at once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addVertex(Object in1, Object in2, Object in3, Object in4, Object in5, Object in6, Object in7)|addVertex]]([[Object]] in1, [[Object]] in2, [[Object]] in3, [[Object]] in4, [[Object]] in5, [[Object]] in6, [[Object]] in7)&lt;br /&gt;
|When the setVertexType has been set this function can be used to add an entire vertex at once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addVertex(Object in1, Object in2, Object in3, Object in4, Object in5, Object in6, Object in7, Object in8)|addVertex]]([[Object]] in1, [[Object]] in2, [[Object]] in3, [[Object]] in4, [[Object]] in5, [[Object]] in6, [[Object]] in7, [[Object]] in8)&lt;br /&gt;
|When the setVertexType has been set this function can be used to add an entire vertex at once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addPosition(Vec3 vertex)|addPosition]]([[Vec3]] vertex)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addPosition(Vec4 vertex)|addPosition]]([[Vec4]] vertex)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addNormal(Vec3 normal)|addNormal]]([[Vec3]] normal)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addNormal(Vec4 normal)|addNormal]]([[Vec4]] normal)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addUvCoord(Vec2 uvCoord)|addUvCoord]]([[Vec2]] uvCoord)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addColor(Vec3 color)|addColor]]([[Vec3]] color)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addColor(Vec4 color)|addColor]]([[Vec4]] color)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addTangent(Vec3 tangent)|addTangent]]([[Vec3]] tangent)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addTangent(Vec4 tangent)|addTangent]]([[Vec4]] tangent)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addIndex(int index)|addIndex]](int index)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:addTriangleIndex(int index1, int index2, int index3)|addTriangleIndex]](int index1, int index2, int index3)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[NodeMesh:addMesh(Mesh mesh)|addMesh]]([[Mesh]] mesh)&lt;br /&gt;
|This will make a copy of the mesh in the original position of the mesh.&lt;br /&gt;
Returns true when a copy was made else return false.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[NodeMesh:compile()|compile]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=Core&amp;diff=171</id>
		<title>Core</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=Core&amp;diff=171"/>
		<updated>2025-08-01T06:36:04Z</updated>

		<summary type="html">&lt;p&gt;Anders: /* Static functions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:CoreExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Static functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setUpdateHz(float hz)|setUpdateHz]](float hz)&lt;br /&gt;
|Sets the update frequency of the script based on in game time. minimum hz that can be set is &amp;gt;0.1 below that it will update every frame&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setUpdateHzRealTime(float hz)|setUpdateHzRealTime]](float hz)&lt;br /&gt;
|Sets the update frequency of the script based on real time. minimum hz that can be set is &amp;gt;0.1 below that it will update every frame&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:skipFrames(int frames)|skipFrames]](int frames)&lt;br /&gt;
|Skip a specified number of frames once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:skipTime(float seconds)|skipTime]](float seconds)&lt;br /&gt;
|Skip a specified time only once. This function needs to be called every time the script want to skip a specified number of frames.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getAverageDeltaTime()|getAverageDeltaTime]]()&lt;br /&gt;
|Get the average delta time over the last 100 frames.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getDeltaTime()|getDeltaTime]]()&lt;br /&gt;
|Get the last frames delta time.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getRealDeltaTime()|getRealDeltaTime]]()&lt;br /&gt;
|Get the last frames delta time without speed factor.&lt;br /&gt;
|-&lt;br /&gt;
|double&lt;br /&gt;
|[[Core:getGameTime()|getGameTime]]()&lt;br /&gt;
|Get time since the program started, with speed factor.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getTime()|getTime]]()&lt;br /&gt;
|Get time since the program started.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getTimeSpeed()|getTimeSpeed]]()&lt;br /&gt;
|Get time speed.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setTimeSpeed(float speed)|setTimeSpeed]](float speed)&lt;br /&gt;
|Set time speed bettwen [0,10], defult is 1.0.&lt;br /&gt;
|-&lt;br /&gt;
|[[FontCharacter]]&lt;br /&gt;
|[[Core:getFontCharacter(String font, int fontHeight, String character)|getFontCharacter]](String font, int fontHeight, String character)&lt;br /&gt;
|Get a font character.&lt;br /&gt;
|-&lt;br /&gt;
|[[Sound]]&lt;br /&gt;
|[[Core:getSound()|getSound]]()&lt;br /&gt;
|Load [[sound]].&lt;br /&gt;
|-&lt;br /&gt;
|[[Work]]&lt;br /&gt;
|[[Core:getCurrentWork()|getCurrentWork]]()&lt;br /&gt;
|Return the current work.&lt;br /&gt;
|-&lt;br /&gt;
|[[LuaScript]]&lt;br /&gt;
|[[Core:getCurrentLuaScript()|getCurrentLuaScript]]()&lt;br /&gt;
|Returns the the current executing Lua script.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSoundCamera(Camera camera)|setSoundCamera]]([[Camera]] camera)&lt;br /&gt;
|Set to which camera sound will go. This will be removed in the future.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSoundCameraMatrix(Matrix cameraMatrix)|setSoundCameraMatrix]]([[Matrix]] cameraMatrix)&lt;br /&gt;
|Set sound camera matrix. this is only useful when sound camera is set to nil.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setDebug2DCamera(Camera camera)|setDebug2DCamera]]([[Camera]] camera)&lt;br /&gt;
|Set to which camera 2D debug text should be renderd to.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:addDebugLine(Vec3 l1, Vec3 l2, float time, Vec3 color)|addDebugLine]]([[Vec3]] l1, [[Vec3]] l2, float time, [[Vec3]] color)&lt;br /&gt;
|Add debug line.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:addDebugLine(Line3D line, float time, Vec3 color)|addDebugLine]]([[Line3D]] line, float time, [[Vec3]] color)&lt;br /&gt;
|Add debug line.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:addDebugSphere(Sphere sphere, float time, Vec3 color)|addDebugSphere]]([[Sphere]] [[sphere]], float time, [[Vec3]] color)&lt;br /&gt;
|Add debug [[sphere]].&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:addDebugBox(Box box, float time, Vec3 color)|addDebugBox]]([[Box]] [[box]], float time, [[Vec3]] color)&lt;br /&gt;
|Add debug [[box]].&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:clearDebugLines()|clearDebugLines]]()&lt;br /&gt;
|Clear all debug data, this includes lines, Spheres and debugBoxes.&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[Core:getFrameNumber()|getFrameNumber]]()&lt;br /&gt;
|get number of rendered frame sence program started.&lt;br /&gt;
|-&lt;br /&gt;
|[[Model]]&lt;br /&gt;
|[[Core:getModel(string modelName)|getModel]]([[string]] modelName)&lt;br /&gt;
|Load model.&lt;br /&gt;
|-&lt;br /&gt;
|[[Shader]]&lt;br /&gt;
|[[Core:getShader(string shaderName)|getShader]]([[string]] shaderName)&lt;br /&gt;
|Load shader.&lt;br /&gt;
|-&lt;br /&gt;
|[[Shader]]&lt;br /&gt;
|[[Core:getShader(string shaderName, string definition)|getShader]]([[string]] shaderName, string definition)&lt;br /&gt;
|Load shader with one definition.&lt;br /&gt;
|-&lt;br /&gt;
|[[Shader]]&lt;br /&gt;
|[[Core:getShader(string shaderName, table definitions)|getShader]]([[string]] shaderName, [[table]] definitions)&lt;br /&gt;
|Load shader with one definitions.&lt;br /&gt;
|-&lt;br /&gt;
|[[Texture]]&lt;br /&gt;
|[[Core:getTexture(string textureName)|getTexture]]([[string]] textureName)&lt;br /&gt;
|Load texture.&lt;br /&gt;
|-&lt;br /&gt;
|[[Texture]]&lt;br /&gt;
|[[Core:getTexture(File aFile)|getTexture]]([[File]] aFile)&lt;br /&gt;
|Load texture from a file.&lt;br /&gt;
|-&lt;br /&gt;
|[[File]]&lt;br /&gt;
|[[Core:getDataFolder()|getDataFolder]]()&lt;br /&gt;
|Get main folder.&lt;br /&gt;
|-&lt;br /&gt;
|[[File]]&lt;br /&gt;
|[[Core:getDataFolder(string subFolder)|getDataFolder]]([[string]] subFolder)&lt;br /&gt;
|Get sub folder from main folder.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2]]&lt;br /&gt;
|[[Core:getScreenResolution()|getScreenResolution]]()&lt;br /&gt;
|Get screen resolution.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2]]&lt;br /&gt;
|[[Core:getRenderResolution()|getRenderResolution]]()&lt;br /&gt;
|Get render resolution. &lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getRenderScale()|getRenderScale]]()&lt;br /&gt;
|Get render scale. &lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Core:getSteamName()|getSteamName]]()&lt;br /&gt;
|returns the name of the current steam user, if available.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Core:setScriptNetworkId(string name)|setScriptNetworkId]](string name)&lt;br /&gt;
|Sets the network name of this script. returns true on success. [This name should be set by all clients individually]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:requireScriptNetworkIdToRunUpdate(bool set)|requireScriptNetworkIdToRunUpdate]](bool set)&lt;br /&gt;
|If set true, the script will not run &amp;quot;update&amp;quot; until setScriptNetworkId() is set&lt;br /&gt;
|-&lt;br /&gt;
|number&lt;br /&gt;
|[[Core:getPlayerId()|getPlayerId]]()&lt;br /&gt;
|returns the unique player id of the client. to know where he is supossed to be.&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Core:getNetworkName()|getNetworkName]]()&lt;br /&gt;
|returns netName for the current script&lt;br /&gt;
|-&lt;br /&gt;
|[[Client]]&lt;br /&gt;
|[[Core:getNetworkClient()|getNetworkClient]]()&lt;br /&gt;
|Returns the client, using multiple times will return the same client. (There is one client)&lt;br /&gt;
|-&lt;br /&gt;
|[[Server]]&lt;br /&gt;
|[[Core:getNetworkServer()|getNetworkServer]]()&lt;br /&gt;
|Returns the server, using multiple times will return the same server. (There is one server)&lt;br /&gt;
|-&lt;br /&gt;
|{ {name=string(), ip=string(), port=int(), time=int()} }&lt;br /&gt;
|[[Core:getServerList()|getServerList]]()&lt;br /&gt;
|Returns the global serverlist.&lt;br /&gt;
|-&lt;br /&gt;
|{ {name=string(), ip=string(), port=int(), time=int()} }&lt;br /&gt;
|[[Core:getServerList(int time)|getServerList]](int time)&lt;br /&gt;
|Returns the global serverlist. Time is in the format epoch seconds.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Core:isInMultiplayer()|isInMultiplayer]]()&lt;br /&gt;
|Returns true if the client is connected to a server.&lt;br /&gt;
|-&lt;br /&gt;
|number&lt;br /&gt;
|[[Core:getIndexOfNetworkName(string networkName)|getIndexOfNetworkName]](string networkName)&lt;br /&gt;
|Returns the index of the script with the networkName, or 0 if none was found&lt;br /&gt;
|-&lt;br /&gt;
|[[LuaScript]]&lt;br /&gt;
|[[Core:getScriptOfNetworkName(string networkName)|getScriptOfNetworkName]](string networkName)&lt;br /&gt;
|Returns the script that uses the networkName, or nil if none was found&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Core:getNetworkNameOf(object param)|getNetworkNameOf]](object param)&lt;br /&gt;
|Returns the Network name of the script. takes number(index of a script) or a [[LuaScript]]&lt;br /&gt;
|-&lt;br /&gt;
|[[ComUnit]]&lt;br /&gt;
|[[Core:getComUnit()|getComUnit]]()&lt;br /&gt;
|Get screen resolution.&lt;br /&gt;
|-&lt;br /&gt;
|[[bool]]&lt;br /&gt;
|[[Core:existLuaScript(int luaIndex)|existLuaScript]](int luaIndex)&lt;br /&gt;
|Returns true if lua script is running.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getBillboard()|getBillboard]]()&lt;br /&gt;
|Get the billboard for this script.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getBillboard(int luaIndex)|getBillboard]](int luaIndex)&lt;br /&gt;
|Get the billboard for luaIndex.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getBillboard(string name)|getBillboard]]([[string]] name)&lt;br /&gt;
|Get billboard by name.&lt;br /&gt;
|-&lt;br /&gt;
|[[Input]]&lt;br /&gt;
|[[Core:getInput()|getInput]]()&lt;br /&gt;
|Get input.&lt;br /&gt;
|-&lt;br /&gt;
|[[HighScore]]&lt;br /&gt;
|[[Core:getHighScore()|getHighScore]]()&lt;br /&gt;
|Get HighScore.&lt;br /&gt;
|-&lt;br /&gt;
|[[Cursor]]&lt;br /&gt;
|[[Core:getCursor()|getCursor]]()&lt;br /&gt;
|Get cursor.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:stopCore()|stopCore]]()&lt;br /&gt;
|Stop score.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:quitMainMenu()|quitMainMenu]]()&lt;br /&gt;
|If game is in main menu then the game will be shutdown.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:quitToMainMenu()|quitToMainMenu]]()&lt;br /&gt;
|Quit from mapeditor or game to main menu.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:quitToMapeditor()|quitToMapeditor]]()&lt;br /&gt;
|Quit from game to mapeditor.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Core:isInEditor()|isInEditor]]()&lt;br /&gt;
|Return true when in editor or when testing a map from the editor.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:startMap(string fileName)|startMap]]([[string]] fileName)&lt;br /&gt;
|start map with name like fileName=&amp;quot;Data/Map/fil.map&amp;quot;.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:startMultiplayerClonedMaps(string fileName, nil clientIds)|startMultiplayerClonedMaps]](string fileName, nil clientIds)&lt;br /&gt;
|start map with name like fileName=&amp;quot;Data/Map/fil.map&amp;quot;. &lt;br /&gt;
clientIds is a list of all client ids that need a private world to be loaded. example {2,3,4,5} &lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:startMapInDebugMode(string fileName)|startMapInDebugMode]]([[string]] fileName)&lt;br /&gt;
|start map in debug mode with name like fileName=&amp;quot;Data/Map/fil.map&amp;quot;.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:startMapEditor(string fileName)|startMapEditor]]([[string]] fileName)&lt;br /&gt;
|start mapEditor. If fileName is &amp;quot;&amp;quot; then a new map will be created.&lt;br /&gt;
|-&lt;br /&gt;
|[[Panel]]&lt;br /&gt;
|[[Core:getPanelWithKeyboardFocus()|getPanelWithKeyboardFocus]]()&lt;br /&gt;
|Return the curent [[panel]] with keyboard focus.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getGlobalBillboard(string billboardName)|getGlobalBillboard]]([[string]] billboardName)&lt;br /&gt;
|Create or collect the billboard with a given name. The Billboard will exist unit the game shutsdown. The billboardName must be unique or allready exist as a globalBillboard.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getGameSessionBillboard(string billboardName)|getGameSessionBillboard]]([[string]] billboardName)&lt;br /&gt;
|Create or collect the billboard with a given name. The Billboard will exist unit the game current map is shutdown.&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Core:getMainCamera()|getMainCamera]]()&lt;br /&gt;
|Get the main camera.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setMainCamera(Camera mainCamera)|setMainCamera]]([[Camera]] mainCamera)&lt;br /&gt;
|set the main camera.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setRenderScale(float scale)|setRenderScale]](float scale)&lt;br /&gt;
|set the scale factor of the current render resolution. should be between [0.5,2.0]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setRenderResolution(Vec2 resolution)|setRenderResolution]]([[Vec2]] resolution)&lt;br /&gt;
|set Render resolution.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setMaxFrameRate(int maxFrameRate)|setMaxFrameRate]](int maxFrameRate)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:skipRenderFrame()|skipRenderFrame]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setCursor(string cursorFilePath)|setCursor]]([[string]] cursorFilePath)&lt;br /&gt;
|Set the cursor icon. NOTE! must be a *.bmp file.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSounMasterGain(float gain)|setSounMasterGain]](float gain)&lt;br /&gt;
|set sound master gain, gain is between [0,1]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSoundMusicGain(float gain)|setSoundMusicGain]](float gain)&lt;br /&gt;
|set music gain, gain is between [0,1]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSounEffectGain(float gain)|setSounEffectGain]](float gain)&lt;br /&gt;
|set effect gain, gain is between [0,1]&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getSounMasterGain()|getSounMasterGain]]()&lt;br /&gt;
|get sound master gain&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getSounMusicGain()|getSounMusicGain]]()&lt;br /&gt;
|get sound master gain&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getSounEffectGain()|getSounEffectGain]]()&lt;br /&gt;
|get sound master gain&lt;br /&gt;
|-&lt;br /&gt;
|[[Panel]]&lt;br /&gt;
|[[Core:getPanelWithMouseFocus()|getPanelWithMouseFocus]]()&lt;br /&gt;
|get panel with mouse focus.&lt;br /&gt;
|-&lt;br /&gt;
|[[Panel]]&lt;br /&gt;
|[[Core:getPanelWithKeyboardFocus()|getPanelWithKeyboardFocus]]()&lt;br /&gt;
|get panel with mouse focus.&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Core:getMachineId()|getMachineId]]()&lt;br /&gt;
|get the machine ID.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setFullscreen(bool fullscreen)|setFullscreen]](bool fullscreen)&lt;br /&gt;
|Set if we should use fullscreen.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setVsync(bool vSync)|setVsync]](bool vSync)&lt;br /&gt;
|Set if vSyncshould turned od.&lt;br /&gt;
|-&lt;br /&gt;
|[[DirectionalLight]]&lt;br /&gt;
|[[Core:getDirectionalLight(SceneNode node)|getDirectionalLight]]([[SceneNode]] node)&lt;br /&gt;
|get the current direction light&lt;br /&gt;
|-&lt;br /&gt;
|[[AmbientLight]]&lt;br /&gt;
|[[Core:getAmbientLight(SceneNode node)|getAmbientLight]]([[SceneNode]] node)&lt;br /&gt;
|get the current ambientlight&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=Camera&amp;diff=170</id>
		<title>Camera</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=Camera&amp;diff=170"/>
		<updated>2025-08-01T06:33:00Z</updated>

		<summary type="html">&lt;p&gt;Anders: /* Functions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:CameraExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Inheritance==&lt;br /&gt;
[[SceneNode]]&lt;br /&gt;
&lt;br /&gt;
==Static functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Camera:new()|new]]()&lt;br /&gt;
|Create a new Instance of the the Camera&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Camera:new(Text nodeName)|new]]([[Text]] nodeName)&lt;br /&gt;
|Create a new Instance of the the Camera&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Camera:new(Text nodeName, bool canRender3D)|new]]([[Text]] nodeName, bool canRender3D)&lt;br /&gt;
|Create a new Instance of the the Camera&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Camera:new(Text nodeName, bool canRender3D, int frameBufferWidth, int frameBufferHeight)|new]]([[Text]] nodeName, bool canRender3D, int frameBufferWidth, int frameBufferHeight)&lt;br /&gt;
|Create a new Instance of the the Camera&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Camera:new(string nodeName)|new]](string nodeName)&lt;br /&gt;
|Create a new Instance of the the Camera&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Camera:new(string nodeName, bool canRender3D)|new]](string nodeName, bool canRender3D)&lt;br /&gt;
|Create a new Instance of the the Camera&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Camera:new(string nodeName, bool canRender3D, int frameBufferWidth, int frameBufferHeight)|new]](string nodeName, bool canRender3D, int frameBufferWidth, int frameBufferHeight)&lt;br /&gt;
|Create a new Instance of the the Camera&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec3]]&lt;br /&gt;
|[[Camera:getAtVec()|getAtVec]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec3]]&lt;br /&gt;
|[[Camera:getUpVec()|getUpVec]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec3]]&lt;br /&gt;
|[[Camera:getRightVec()|getRightVec]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|{SceneNode()}&lt;br /&gt;
|[[Camera:getAllNodeByTypeInView(NodeId type)|getAllNodeByTypeInView]]([[NodeId]] type)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|{SceneNode()}&lt;br /&gt;
|[[Camera:getAllNodeByTypeInViewFromNode(SceneNode node, NodeId type)|getAllNodeByTypeInViewFromNode]]([[SceneNode]] node, [[NodeId]] type)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Line3D]]&lt;br /&gt;
|[[Camera:getWorldLineFromScreen(Vec2 pos)|getWorldLineFromScreen]]([[Vec2]] pos)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Texture]]&lt;br /&gt;
|[[Camera:getTexture()|getTexture]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[AmbientLight]]&lt;br /&gt;
|[[Camera:getAmbientLight()|getAmbientLight]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[DirectionalLight]]&lt;br /&gt;
|[[Camera:getDirectionLight()|getDirectionLight]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2]]&lt;br /&gt;
|[[Camera:getScreenCoordFromglobalPos(Vec3 globalPosition)|getScreenCoordFromglobalPos]]([[Vec3]] globalPosition)&lt;br /&gt;
|Get screen coordinates from a global position.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2]]&lt;br /&gt;
|[[Camera:getResolution()|getResolution]]()&lt;br /&gt;
|Get the screen resolution of this camera.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Camera:getDynamicLightsEnable()|getDynamicLightsEnable]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Camera:getVisibleInCamera()|getVisibleInCamera]]()&lt;br /&gt;
|Returns true if the node was visible for a camera.&lt;br /&gt;
|-&lt;br /&gt;
|[[Shader]]&lt;br /&gt;
|[[Camera:getDefferRenderShader()|getDefferRenderShader]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setDefferRenderShader(Shader defferedShader)|setDefferRenderShader]]([[Shader]] defferedShader)&lt;br /&gt;
|Set the shader that will make the final render from deferred buffers to one buffer.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:render()|render]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setLocalMatrix(Matrix mat)|setLocalMatrix]]([[Matrix]] mat)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setLocalPosition(Vec3 position)|setLocalPosition]]([[Vec3]] position)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setUseShadow(bool enable)|setUseShadow]](bool enable)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setUseGlow(bool enable)|setUseGlow]](bool enable)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setUseAntiAliasing(bool enable)|setUseAntiAliasing]](bool enable)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setUseSelectedRender(bool enable)|setUseSelectedRender]](bool enable)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setDynamicLightsEnable(bool enable)|setDynamicLightsEnable]](bool enable)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setClearColor(Vec4 clearColor)|setClearColor]]([[Vec4]] clearColor)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setShadowScale(float scale)|setShadowScale]](float scale)&lt;br /&gt;
|Cameras shadow map is of the same size as the camera resolution but this can be changed by a scalar with this function.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setAmbientLight(AmbientLight light)|setAmbientLight]]([[AmbientLight]] light)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setDirectionLight(DirectionalLight light)|setDirectionLight]]([[DirectionalLight]] light)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setFrameBufferSize(Vec2i size)|setFrameBufferSize]]([[Vec2i]] size)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:setRenderScript(string scriptName)|setRenderScript]](string scriptName)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Camera:add2DScene(Scene2DNode scene2DNode)|add2DScene]]([[Scene2DNode]] scene2DNode)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Camera:saveScreenshot(string fileName)|saveScreenshot]](string fileName)&lt;br /&gt;
|return true if the image was successfully saved to file. Cameras rendering directly to screen can not save a screenshot. &lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Camera:remove2DScene(Scene2DNode scene2DNode)|remove2DScene]]([[Scene2DNode]] scene2DNode)&lt;br /&gt;
|return true if the scene2DNode was removed.&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=Core&amp;diff=169</id>
		<title>Core</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=Core&amp;diff=169"/>
		<updated>2025-08-01T06:31:42Z</updated>

		<summary type="html">&lt;p&gt;Anders: /* Static functions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:CoreExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Static functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setUpdateHz(float hz)|setUpdateHz]](float hz)&lt;br /&gt;
|Sets the update frequency of the script based on in game time. minimum hz that can be set is &amp;gt;0.1 below that it will update every frame&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setUpdateHzRealTime(float hz)|setUpdateHzRealTime]](float hz)&lt;br /&gt;
|Sets the update frequency of the script based on real time. minimum hz that can be set is &amp;gt;0.1 below that it will update every frame&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:skipFrames(int frames)|skipFrames]](int frames)&lt;br /&gt;
|Skip a specified number of frames once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:skipTime(float seconds)|skipTime]](float seconds)&lt;br /&gt;
|Skip a specified time only once. This function needs to be called every time the script want to skip a specified number of frames.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getAverageDeltaTime()|getAverageDeltaTime]]()&lt;br /&gt;
|Get the average delta time over the last 100 frames.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getDeltaTime()|getDeltaTime]]()&lt;br /&gt;
|Get the last frames delta time.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getRealDeltaTime()|getRealDeltaTime]]()&lt;br /&gt;
|Get the last frames delta time without speed factor.&lt;br /&gt;
|-&lt;br /&gt;
|double&lt;br /&gt;
|[[Core:getGameTime()|getGameTime]]()&lt;br /&gt;
|Get time since the program started, with speed factor.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getTime()|getTime]]()&lt;br /&gt;
|Get time since the program started.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getTimeSpeed()|getTimeSpeed]]()&lt;br /&gt;
|Get time speed.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setTimeSpeed(float speed)|setTimeSpeed]](float speed)&lt;br /&gt;
|Set time speed bettwen [0,10], defult is 1.0.&lt;br /&gt;
|-&lt;br /&gt;
|[[FontCharacter]]&lt;br /&gt;
|[[Core:getFontCharacter(String font, int fontHeight, String character)|getFontCharacter]](String font, int fontHeight, String character)&lt;br /&gt;
|Get a font character.&lt;br /&gt;
|-&lt;br /&gt;
|[[Sound]]&lt;br /&gt;
|[[Core:getSound()|getSound]]()&lt;br /&gt;
|Load [[sound]].&lt;br /&gt;
|-&lt;br /&gt;
|[[Work]]&lt;br /&gt;
|[[Core:getCurrentWork()|getCurrentWork]]()&lt;br /&gt;
|Return the current work.&lt;br /&gt;
|-&lt;br /&gt;
|[[LuaScript]]&lt;br /&gt;
|[[Core:getCurrentLuaScript()|getCurrentLuaScript]]()&lt;br /&gt;
|Returns the the current executing Lua script.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSoundCamera(Camera camera)|setSoundCamera]]([[Camera]] camera)&lt;br /&gt;
|Set to which camera sound will go. This will be removed in the future.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSoundCameraMatrix(Matrix cameraMatrix)|setSoundCameraMatrix]]([[Matrix]] cameraMatrix)&lt;br /&gt;
|Set sound camera matrix. this is only useful when sound camera is set to nil.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setDebug2DCamera(Camera camera)|setDebug2DCamera]]([[Camera]] camera)&lt;br /&gt;
|Set to which camera 2D debug text should be renderd to.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:addDebugLine(Vec3 l1, Vec3 l2, float time, Vec3 color)|addDebugLine]]([[Vec3]] l1, [[Vec3]] l2, float time, [[Vec3]] color)&lt;br /&gt;
|Add debug line.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:addDebugLine(Line3D line, float time, Vec3 color)|addDebugLine]]([[Line3D]] line, float time, [[Vec3]] color)&lt;br /&gt;
|Add debug line.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:addDebugSphere(Sphere sphere, float time, Vec3 color)|addDebugSphere]]([[Sphere]] [[sphere]], float time, [[Vec3]] color)&lt;br /&gt;
|Add debug [[sphere]].&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:addDebugBox(Box box, float time, Vec3 color)|addDebugBox]]([[Box]] [[box]], float time, [[Vec3]] color)&lt;br /&gt;
|Add debug [[box]].&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:clearDebugLines()|clearDebugLines]]()&lt;br /&gt;
|Clear all debug data, this includes lines, Spheres and debugBoxes.&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[Core:getFrameNumber()|getFrameNumber]]()&lt;br /&gt;
|get number of rendered frame sence program started.&lt;br /&gt;
|-&lt;br /&gt;
|[[Model]]&lt;br /&gt;
|[[Core:getModel(string modelName)|getModel]]([[string]] modelName)&lt;br /&gt;
|Load model.&lt;br /&gt;
|-&lt;br /&gt;
|[[Shader]]&lt;br /&gt;
|[[Core:getShader(string shaderName)|getShader]]([[string]] shaderName)&lt;br /&gt;
|Load shader.&lt;br /&gt;
|-&lt;br /&gt;
|[[Shader]]&lt;br /&gt;
|[[Core:getShader(string shaderName, string definition)|getShader]]([[string]] shaderName, string definition)&lt;br /&gt;
|Load shader with one definition.&lt;br /&gt;
|-&lt;br /&gt;
|[[Shader]]&lt;br /&gt;
|[[Core:getShader(string shaderName, table definitions)|getShader]]([[string]] shaderName, [[table]] definitions)&lt;br /&gt;
|Load shader with one definitions.&lt;br /&gt;
|-&lt;br /&gt;
|[[Texture]]&lt;br /&gt;
|[[Core:getTexture(string textureName)|getTexture]]([[string]] textureName)&lt;br /&gt;
|Load texture.&lt;br /&gt;
|-&lt;br /&gt;
|[[Texture]]&lt;br /&gt;
|[[Core:getTexture(File aFile)|getTexture]]([[File]] aFile)&lt;br /&gt;
|Load texture from a file.&lt;br /&gt;
|-&lt;br /&gt;
|[[File]]&lt;br /&gt;
|[[Core:getDataFolder()|getDataFolder]]()&lt;br /&gt;
|Get main folder.&lt;br /&gt;
|-&lt;br /&gt;
|[[File]]&lt;br /&gt;
|[[Core:getDataFolder(string subFolder)|getDataFolder]]([[string]] subFolder)&lt;br /&gt;
|Get sub folder from main folder.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2]]&lt;br /&gt;
|[[Core:getScreenResolution()|getScreenResolution]]()&lt;br /&gt;
|Get screen resolution.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2]]&lt;br /&gt;
|[[Core:getRenderResolution()|getRenderResolution]]()&lt;br /&gt;
|Get render resolution. &lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getRenderScale()|getRenderScale]]()&lt;br /&gt;
|Get render scale. &lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Core:getSteamName()|getSteamName]]()&lt;br /&gt;
|returns the name of the current steam user, if available.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Core:setScriptNetworkId(string name)|setScriptNetworkId]](string name)&lt;br /&gt;
|Sets the network name of this script. returns true on success. [This name should be set by all clients individually]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:requireScriptNetworkIdToRunUpdate(bool set)|requireScriptNetworkIdToRunUpdate]](bool set)&lt;br /&gt;
|If set true, the script will not run &amp;quot;update&amp;quot; until setScriptNetworkId() is set&lt;br /&gt;
|-&lt;br /&gt;
|number&lt;br /&gt;
|[[Core:getPlayerId()|getPlayerId]]()&lt;br /&gt;
|returns the unique player id of the client. to know where he is supossed to be.&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Core:getNetworkName()|getNetworkName]]()&lt;br /&gt;
|returns netName for the current script&lt;br /&gt;
|-&lt;br /&gt;
|[[Client]]&lt;br /&gt;
|[[Core:getNetworkClient()|getNetworkClient]]()&lt;br /&gt;
|Returns the client, using multiple times will return the same client. (There is one client)&lt;br /&gt;
|-&lt;br /&gt;
|[[Server]]&lt;br /&gt;
|[[Core:getNetworkServer()|getNetworkServer]]()&lt;br /&gt;
|Returns the server, using multiple times will return the same server. (There is one server)&lt;br /&gt;
|-&lt;br /&gt;
|{ {name=string(), ip=string(), port=int(), time=int()} }&lt;br /&gt;
|[[Core:getServerList()|getServerList]]()&lt;br /&gt;
|Returns the global serverlist.&lt;br /&gt;
|-&lt;br /&gt;
|{ {name=string(), ip=string(), port=int(), time=int()} }&lt;br /&gt;
|[[Core:getServerList(int time)|getServerList]](int time)&lt;br /&gt;
|Returns the global serverlist. Time is in the format epoch seconds.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Core:isInMultiplayer()|isInMultiplayer]]()&lt;br /&gt;
|Returns true if the client is connected to a server.&lt;br /&gt;
|-&lt;br /&gt;
|number&lt;br /&gt;
|[[Core:getIndexOfNetworkName(string networkName)|getIndexOfNetworkName]](string networkName)&lt;br /&gt;
|Returns the index of the script with the networkName, or 0 if none was found&lt;br /&gt;
|-&lt;br /&gt;
|[[LuaScript]]&lt;br /&gt;
|[[Core:getScriptOfNetworkName(string networkName)|getScriptOfNetworkName]](string networkName)&lt;br /&gt;
|Returns the script that uses the networkName, or nil if none was found&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Core:getNetworkNameOf(object param)|getNetworkNameOf]](object param)&lt;br /&gt;
|Returns the Network name of the script. takes number(index of a script) or a [[LuaScript]]&lt;br /&gt;
|-&lt;br /&gt;
|[[ComUnit]]&lt;br /&gt;
|[[Core:getComUnit()|getComUnit]]()&lt;br /&gt;
|Get screen resolution.&lt;br /&gt;
|-&lt;br /&gt;
|[[bool]]&lt;br /&gt;
|[[Core:existLuaScript(int luaIndex)|existLuaScript]](int luaIndex)&lt;br /&gt;
|Returns true if lua script is running.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getBillboard()|getBillboard]]()&lt;br /&gt;
|Get the billboard for this script.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getBillboard(int luaIndex)|getBillboard]](int luaIndex)&lt;br /&gt;
|Get the billboard for luaIndex.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getBillboard(string name)|getBillboard]]([[string]] name)&lt;br /&gt;
|Get billboard by name.&lt;br /&gt;
|-&lt;br /&gt;
|[[Input]]&lt;br /&gt;
|[[Core:getInput()|getInput]]()&lt;br /&gt;
|Get input.&lt;br /&gt;
|-&lt;br /&gt;
|[[HighScore]]&lt;br /&gt;
|[[Core:getHighScore()|getHighScore]]()&lt;br /&gt;
|Get HighScore.&lt;br /&gt;
|-&lt;br /&gt;
|[[Cursor]]&lt;br /&gt;
|[[Core:getCursor()|getCursor]]()&lt;br /&gt;
|Get cursor.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:stopCore()|stopCore]]()&lt;br /&gt;
|Stop score.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:quitMainMenu()|quitMainMenu]]()&lt;br /&gt;
|If game is in main menu then the game will be shutdown.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:quitToMainMenu()|quitToMainMenu]]()&lt;br /&gt;
|Quit from mapeditor or game to main menu.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:quitToMapeditor()|quitToMapeditor]]()&lt;br /&gt;
|Quit from game to mapeditor.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Core:isInEditor()|isInEditor]]()&lt;br /&gt;
|Return true when in editor or when testing a map from the editor.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:startMap(string fileName)|startMap]]([[string]] fileName)&lt;br /&gt;
|start map with name like fileName=&amp;quot;Data/Map/fil.map&amp;quot;.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:startMultiplayerClonedMaps(string fileName, nil clientIds)|startMultiplayerClonedMaps]](string fileName, nil clientIds)&lt;br /&gt;
|start map with name like fileName=&amp;quot;Data/Map/fil.map&amp;quot;. &lt;br /&gt;
clientIds is a list of all client ids that need a private world to be loaded. example {2,3,4,5} &lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:startMapInDebugMode(string fileName)|startMapInDebugMode]]([[string]] fileName)&lt;br /&gt;
|start map in debug mode with name like fileName=&amp;quot;Data/Map/fil.map&amp;quot;.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:startMapEditor(string fileName)|startMapEditor]]([[string]] fileName)&lt;br /&gt;
|start mapEditor. If fileName is &amp;quot;&amp;quot; then a new map will be created.&lt;br /&gt;
|-&lt;br /&gt;
|[[Panel]]&lt;br /&gt;
|[[Core:getPanelWithKeyboardFocus()|getPanelWithKeyboardFocus]]()&lt;br /&gt;
|Return the curent [[panel]] with keyboard focus.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getGlobalBillboard(string billboardName)|getGlobalBillboard]]([[string]] billboardName)&lt;br /&gt;
|Create or collect the billboard with a given name. The Billboard will exist unit the game shutsdown. The billboardName must be unique or allready exist as a globalBillboard.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getGameSessionBillboard(string billboardName)|getGameSessionBillboard]]([[string]] billboardName)&lt;br /&gt;
|Create or collect the billboard with a given name. The Billboard will exist unit the game current map is shutdown.&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Core:getMainCamera()|getMainCamera]]()&lt;br /&gt;
|Get the main camera.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setMainCamera(Camera mainCamera)|setMainCamera]]([[Camera]] mainCamera)&lt;br /&gt;
|set the main camera.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setRenderScale(float scale)|setRenderScale]](float scale)&lt;br /&gt;
|set the scale factor of the current render resolution. should be between [0.5,2.0]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setRenderResolution(Vec2 resolution)|setRenderResolution]]([[Vec2]] resolution)&lt;br /&gt;
|set Render resolution.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setMaxFrameRate(int maxFrameRate)|setMaxFrameRate]](int maxFrameRate)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:skipRenderFrame()|skipRenderFrame]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setCursor(string cursorFilePath)|setCursor]]([[string]] cursorFilePath)&lt;br /&gt;
|Set the cursor icon. NOTE! must be a *.bmp file.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSounMasterGain(float gain)|setSounMasterGain]](float gain)&lt;br /&gt;
|set sound master gain, gain is between [0,1]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSoundMusicGain(float gain)|setSoundMusicGain]](float gain)&lt;br /&gt;
|set music gain, gain is between [0,1]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSounEffectGain(float gain)|setSounEffectGain]](float gain)&lt;br /&gt;
|set effect gain, gain is between [0,1]&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getSounMasterGain()|getSounMasterGain]]()&lt;br /&gt;
|get sound master gain&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getSounMusicGain()|getSounMusicGain]]()&lt;br /&gt;
|get sound master gain&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getSounEffectGain()|getSounEffectGain]]()&lt;br /&gt;
|get sound master gain&lt;br /&gt;
|-&lt;br /&gt;
|[[Panel]]&lt;br /&gt;
|[[Core:getPanelWithMouseFocus()|getPanelWithMouseFocus]]()&lt;br /&gt;
|get panel with mouse focus.&lt;br /&gt;
|-&lt;br /&gt;
|[[Panel]]&lt;br /&gt;
|[[Core:getPanelWithKeyboardFocus()|getPanelWithKeyboardFocus]]()&lt;br /&gt;
|get panel with mouse focus.&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Core:getMachineId()|getMachineId]]()&lt;br /&gt;
|get the machine ID.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setFullscreen(bool fullscreen)|setFullscreen]](bool fullscreen)&lt;br /&gt;
|Set if we should use fullscreen.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setVsync(bool vSync)|setVsync]](bool vSync)&lt;br /&gt;
|Set if vSyncshould turned od.&lt;br /&gt;
|-&lt;br /&gt;
|[[DirectionalLight]]&lt;br /&gt;
|[[Core:getDirectionalLight()|getDirectionalLight]]()&lt;br /&gt;
|get the current direction light&lt;br /&gt;
|-&lt;br /&gt;
|[[AmbientLight]]&lt;br /&gt;
|[[Core:getAmbientLight()|getAmbientLight]]()&lt;br /&gt;
|get the current ambientlight&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=BuildNode&amp;diff=168</id>
		<title>BuildNode</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=BuildNode&amp;diff=168"/>
		<updated>2025-07-31T06:39:55Z</updated>

		<summary type="html">&lt;p&gt;Anders: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:BuildNodeNodeExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Inheritance==&lt;br /&gt;
[[SceneNode]]&lt;br /&gt;
&lt;br /&gt;
==Static functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|[[BuildNode]]&lt;br /&gt;
|[[BuildNode:new()|new]]()&lt;br /&gt;
|Create a new Instance of the the BuildNode&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[BuildNode:addPath(SceneNode island1, Vec3 localIslandPosition1, SceneNode island2, Vec3 localIslandPosition2)|addPath]]([[SceneNode]] island1, [[Vec3]] localIslandPosition1, [[SceneNode]] island2, [[Vec3]] localIslandPosition2)&lt;br /&gt;
|Add a protected path that can&#039;t be built ower.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[BuildNode:addProtectedPoint(SceneNode island, Vec3 localIslandPosition)|addProtectedPoint]]([[SceneNode]] island, [[Vec3]] localIslandPosition)&lt;br /&gt;
|Add a protected point where nothinge can be built.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[BuildNode:addProtectedLine(SceneNode island, Vec3 point1, Vec3 point2)|addProtectedLine]]([[SceneNode]] island, [[Vec3]]  point1, [[Vec3]] point2)&lt;br /&gt;
|Add a protected Line on witch no tower can be built.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[BuildNode:addProtectedLine(SceneNode island, line3D localLine)|addProtectedLine]]([[SceneNode]] island, [[Line3D]] localLine)&lt;br /&gt;
|Add a protected Line on witch no tower can be built.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[BuildNode:tryToSnapBuildingInToPlace(SceneNode building, SceneNode collisionNode, Vec3 global pos, float yRotation)|tryToSnapBuildingInToPlace]]([[SceneNode]] building, [[SceneNode]] collisionNode, [[Vec3]] [[global]] pos, float yRotation)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[BuildNode:removeBuilding(SceneNode buildNode)|removeBuilding]]([[SceneNode]] buildNode)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Island]]&lt;br /&gt;
|[[BuildNode:getTargetIsland()|getTargetIsland]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Matrix]]&lt;br /&gt;
|[[BuildNode:getLocalIslandMatrix()|getLocalIslandMatrix]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[SceneNode]]&lt;br /&gt;
|[[BuildNode:TryToBuild()|TryToBuild]]()&lt;br /&gt;
|Return the buildings SceneNode when the building is built else return nil.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[BuildNode:activatePathRender()|activatePathRender]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[BuildNode:clearBuildings()|clearBuildings]]()&lt;br /&gt;
|Try to remove all buildings from the BuildNode. Return true if all buildings was successfully removed.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[BuildNode:sellBuilding(SceneNode buildingNode)|sellBuilding]]([[SceneNode]] buildingNode)&lt;br /&gt;
|Try to sell a building from the BuildNode. Return true if the building was successfully removed.&lt;br /&gt;
|-&lt;br /&gt;
|{SceneNode()}&lt;br /&gt;
|[[BuildNode:getBuildingList()|getBuildingList]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|{SceneNode()}&lt;br /&gt;
|[[BuildNode:getAllBuildingFromPoint(Vec3 position, float radius)|getAllBuildingFromPoint]](Vec3 position, float radius)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[SceneNode]]&lt;br /&gt;
|[[BuildNode:getBuldingFromLine(Line3D line)|getBuldingFromLine]]([[Line3D]] line)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[SceneNode]]&lt;br /&gt;
|[[BuildNode:getNearestBuildingFromLine(Line3D line)|getNearestBuildingFromLine]]([[Line3D]] line)&lt;br /&gt;
|Return the nearest building from the given line. return nil when there is no tower created.&lt;br /&gt;
|-&lt;br /&gt;
|[[Matrix]]&lt;br /&gt;
|[[BuildNode:getCurrentGlobalTowerMatrix()|getCurrentGlobalTowerMatrix]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|{ }&lt;br /&gt;
|[[BuildNode:getBuildInfo()|getBuildInfo]]()&lt;br /&gt;
|This function can only be called after a building has been placed. Returns a table with information to build the tower again in the same location.&lt;br /&gt;
|-&lt;br /&gt;
|[[SceneNode]]&lt;br /&gt;
|[[BuildNode:buildFromBuildInfo(SceneNode building, table buildInfo)|buildFromBuildInfo]]([[SceneNode]] building, table buildInfo)&lt;br /&gt;
|Return the buildings SceneNode when the building is built else return nil. buildInfo is the table created by the getBuildInfo() function.&lt;br /&gt;
|-&lt;br /&gt;
|{ { island=Island(), position=Vec3()} }&lt;br /&gt;
|[[BuildNode:getProtectedPoints()|getProtectedPoints]]()&lt;br /&gt;
|This function return all protected points. in following format { {island=Island(),position=Vec3()}, ... }&lt;br /&gt;
|-&lt;br /&gt;
|{ { { island=Island(), position=Vec3()} } }&lt;br /&gt;
|[[BuildNode:getProtectedLines()|getProtectedLines]]()&lt;br /&gt;
|This function return all protected lines. in following format { { {island=Island(),position=Vec3()}, {island=Island(),position=Vec3()} }, ... }, allLines(line(p1, p2))&lt;br /&gt;
|-&lt;br /&gt;
|{ { { island=Island(), position=Vec3()} } }&lt;br /&gt;
|[[BuildNode:getProtectedPaths()|getProtectedPaths]]()&lt;br /&gt;
|This function return all protected paths. in following format { { {island=Island(),position=Vec3()}, {island=Island(),position=Vec3()} }, ... }, allLines(line(p1, p2))&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=Panel&amp;diff=167</id>
		<title>Panel</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=Panel&amp;diff=167"/>
		<updated>2025-07-27T10:11:13Z</updated>

		<summary type="html">&lt;p&gt;Anders: /* Functions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:PanelExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Constructor==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|Panel([[PanelSize]] size)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Panel(Panel panel)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:clear()|clear]]()&lt;br /&gt;
|Clear panel from all children.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:clearEvents()|clearEvents]]()&lt;br /&gt;
|Clear panel from all events.&lt;br /&gt;
|-&lt;br /&gt;
|Panel&lt;br /&gt;
|[[Panel:add(Panel panel)|add]]([[Panel]] panel)&lt;br /&gt;
|Add child panel.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:addRenderObject(Scene2DNode renderObject)|addRenderObject]]([[Scene2DNode]] renderObject)&lt;br /&gt;
|Add render object to this panel.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Panel:removePanel(Panel panel)|removePanel]]([[Panel]] panel)&lt;br /&gt;
|Remove child panel.&lt;br /&gt;
|-&lt;br /&gt;
|[[Form]]&lt;br /&gt;
|[[Panel:getForm()|getForm]]()&lt;br /&gt;
|Return the form this panel belongs to.&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Panel:getName()|getName]]()&lt;br /&gt;
|Return the name of the panel.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setBackground(Sprite background)|setBackground]]([[Sprite]] background)&lt;br /&gt;
|Set panel background.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setBackground(Sprite background, PanelSize backgroundSize)|setBackground]]([[Sprite]] background, [[PanelSize]] backgroundSize)&lt;br /&gt;
|Set panel background. BackgroundSize set the size of the background the background is aligned to the center.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setBackground(Gradient background)|setBackground]]([[Gradient]] background)&lt;br /&gt;
|Set panel background.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setBackground(Gradient background, PanelSize backgroundSize)|setBackground]]([[Gradient]] background, [[PanelSize]] backgroundSize)&lt;br /&gt;
|Set panel background. BackgroundSize set the size of the background the background is aligned to the center.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setBorder(BaseBorder panelBorder)|setBorder]]([[BaseBorder]] panelBorder)&lt;br /&gt;
|Set panel border.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setPadding(BorderSize padding)|setPadding]]([[BorderSize]] padding)&lt;br /&gt;
|Set panel padding.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setMargin(BorderSize margin)|setMargin]]([[BorderSize]] margin)&lt;br /&gt;
|Set panel margin.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setPanelId(string panelId)|setPanelId]]([[string]] panelId)&lt;br /&gt;
|Set panelsize.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setPanelSize(PanelSize size)|setPanelSize]]([[PanelSize]] size)&lt;br /&gt;
|Set panel id.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setLayout(Layout layout)|setLayout]]([[Layout]] [[layout]])&lt;br /&gt;
|Set panel Layout.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setRender()|setRender]]()&lt;br /&gt;
|Force panel to render.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setVisible(bool visible)|setVisible]](bool visible)&lt;br /&gt;
|Set panel visible.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setEnableScroll()|setEnableScroll]]()&lt;br /&gt;
|Set enable scroll.&lt;br /&gt;
|-&lt;br /&gt;
|[[ScrollBar]]&lt;br /&gt;
|[[Panel:getYScrollBar()|getYScrollBar]]()&lt;br /&gt;
|Get scrrollbar. if no scrollbar has been created return nil.&lt;br /&gt;
|-&lt;br /&gt;
|[[ScrollBar]]&lt;br /&gt;
|[[Panel:getXScrollBar()|getXScrollBar]]()&lt;br /&gt;
|Get scrrollbar. if no scrollbar has been created return nil.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setTag(string tag)|setTag]](string tag)&lt;br /&gt;
|Set tag.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setTag(Text tag)|setTag]]([[Text]] tag)&lt;br /&gt;
|Set tag.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setToolTip(Text toolTip)|setToolTip]]([[Text]] toolTip)&lt;br /&gt;
|Set tag.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setToolTip(string toolTip)|setToolTip]](string toolTip)&lt;br /&gt;
|Set tag.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setToolTip(Panel toolTipPanel)|setToolTip]]([[Panel]] toolTipPanel)&lt;br /&gt;
|Set a panel that will be shown as a tool-tip.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setToolTipParentpanel(Panel panel)|setToolTipParentpanel]]([[Panel]] panel)&lt;br /&gt;
|Set another parent where the tool-tip will be displayed.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setCanHandleInput(bool canTakeInput)|setCanHandleInput]](bool canTakeInput)&lt;br /&gt;
|Set if the panel can access inputs.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setKeyboardOwner()|setKeyboardOwner]]())&lt;br /&gt;
|Set this panel as the keyboard owner.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:clearKeyboardOwner()|clearKeyboardOwner]]())&lt;br /&gt;
|Clear keyboard owner.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setEnabled(bool enabled)|setEnabled]](bool enabled)&lt;br /&gt;
|Set if the panel is enabled. if disabled still visible but cant be changed.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:addEventCallbackExecute(nil function)|addEventCallbackExecute]](nil function)&lt;br /&gt;
|Add callback for execution event.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:addEventCallbackUpdate(nil function)|addEventCallbackUpdate]](nil function)&lt;br /&gt;
|Add callback for update event.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:addEventCallbackResized(nil function)|addEventCallbackResized]](nil function)&lt;br /&gt;
|Add callback for resize event.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:addEventCallbackMouseFocusGain(nil function)|addEventCallbackMouseFocusGain]](nil function)&lt;br /&gt;
|Add mouse focus gain&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:addEventCallbackMouseFocusLost(nil function)|addEventCallbackMouseFocusLost]](nil function)&lt;br /&gt;
|Add callback for focus gain event.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:addEventCallbackKeyboardFocusGain(nil function)|addEventCallbackKeyboardFocusGain]]([nil function)&lt;br /&gt;
|Add callback for keyboard focus gain event.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:addEventCallbackKeyboardFocusLost(nil function)|addEventCallbackKeyboardFocusLost]](nil function)&lt;br /&gt;
|Add callback for keybord focus lost event.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:addEventCallbackChanged(nil function)|addEventCallbackChanged]](nil function)&lt;br /&gt;
|Add callback for when somthinge has changed.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:addEventCallbackOnClick(nil function)|addEventCallbackOnClick]](nil function)&lt;br /&gt;
|Add callback for on mouse left click event.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:addEventCallbackOnRightClick(nil function)|addEventCallbackOnRightClick]](nil function)&lt;br /&gt;
|Add callback for on mouse right click event.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:addEventCallbackOnDoubleclick(nil function)|addEventCallbackOnDoubleclick]](nil function)&lt;br /&gt;
|Add callback for when on mouse left doubleclick event.&lt;br /&gt;
|-&lt;br /&gt;
|Panel&lt;br /&gt;
|[[Panel:getPanelById(string id)|getPanelById]]([[string]] id)&lt;br /&gt;
|Get panel by id.&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[Panel:getNumPanel()|getNumPanel]]()&lt;br /&gt;
|Get num panel children.&lt;br /&gt;
|-&lt;br /&gt;
|Panel&lt;br /&gt;
|[[Panel:getPanel(int index)|getPanel]](int index)&lt;br /&gt;
|Get panel by index.&lt;br /&gt;
|-&lt;br /&gt;
|[[PanelSize]]&lt;br /&gt;
|[[Panel:getPanelSize()|getPanelSize]]()&lt;br /&gt;
|Get panel size.&lt;br /&gt;
|-&lt;br /&gt;
|[[BorderSize]]&lt;br /&gt;
|[[Panel:getMarginSize()|getMarginSize]]()&lt;br /&gt;
|Get margin size.&lt;br /&gt;
|-&lt;br /&gt;
|[[BorderSize]]&lt;br /&gt;
|[[Panel:getPaddingSize()|getPaddingSize]]()&lt;br /&gt;
|Get padding size.&lt;br /&gt;
|-&lt;br /&gt;
|[[Layout]]&lt;br /&gt;
|[[Panel:getLayout()|getLayout]]()&lt;br /&gt;
|Get layout.&lt;br /&gt;
|-&lt;br /&gt;
|[[BaseBorder]]&lt;br /&gt;
|[[Panel:getBorder()|getBorder]]()&lt;br /&gt;
|Get border.&lt;br /&gt;
|-&lt;br /&gt;
|[[string]]&lt;br /&gt;
|[[Panel:getPanelId()|getPanelId]]()&lt;br /&gt;
|Get id.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Panel:getVisible()|getVisible]]()&lt;br /&gt;
|Get if visible.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2i]]&lt;br /&gt;
|[[Panel:getMinPos()|getMinPos]]()&lt;br /&gt;
|Get minPos.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2i]]&lt;br /&gt;
|[[Panel:getMaxPos()|getMaxPos]]()&lt;br /&gt;
|Get max position.&lt;br /&gt;
|-&lt;br /&gt;
|[[Text]]&lt;br /&gt;
|[[Panel:getTag()|getTag]]()&lt;br /&gt;
|Get tag.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Panel:getEnabled()|getEnabled]]()&lt;br /&gt;
|Get is enabled.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2i]]&lt;br /&gt;
|[[Panel:getPanelContentPixelSize()|getPanelContentPixelSize]]()&lt;br /&gt;
|Get panel content size.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Panel:getWillBeRenderd()|getWillBeRenderd]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Panel&lt;br /&gt;
|[[Panel:getParent()|getParent]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Panel:haskeyboardFocus()|haskeyboardFocus]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Panel:hasMouseFocus()|hasMouseFocus]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Panel:setName(string name)|setName]](string name)&lt;br /&gt;
|Set name of the panel.&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Operators==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Panel]] == [[Panel]]&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Overloaded returns==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|Parameter&lt;br /&gt;
|-&lt;br /&gt;
|Panel&lt;br /&gt;
|add&lt;br /&gt;
|panel&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=Core&amp;diff=166</id>
		<title>Core</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=Core&amp;diff=166"/>
		<updated>2025-07-26T17:39:21Z</updated>

		<summary type="html">&lt;p&gt;Anders: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:CoreExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Static functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setUpdateHz(float hz)|setUpdateHz]](float hz)&lt;br /&gt;
|Sets the update frequency of the script based on in game time. minimum hz that can be set is &amp;gt;0.1 below that it will update every frame&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setUpdateHzRealTime(float hz)|setUpdateHzRealTime]](float hz)&lt;br /&gt;
|Sets the update frequency of the script based on real time. minimum hz that can be set is &amp;gt;0.1 below that it will update every frame&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:skipFrames(int frames)|skipFrames]](int frames)&lt;br /&gt;
|Skip a specified number of frames once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:skipTime(float seconds)|skipTime]](float seconds)&lt;br /&gt;
|Skip a specified time only once. This function needs to be called every time the script want to skip a specified number of frames.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getAverageDeltaTime()|getAverageDeltaTime]]()&lt;br /&gt;
|Get the average delta time over the last 100 frames.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getDeltaTime()|getDeltaTime]]()&lt;br /&gt;
|Get the last frames delta time.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getRealDeltaTime()|getRealDeltaTime]]()&lt;br /&gt;
|Get the last frames delta time without speed factor.&lt;br /&gt;
|-&lt;br /&gt;
|double&lt;br /&gt;
|[[Core:getGameTime()|getGameTime]]()&lt;br /&gt;
|Get time since the program started, with speed factor.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getTime()|getTime]]()&lt;br /&gt;
|Get time since the program started.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getTimeSpeed()|getTimeSpeed]]()&lt;br /&gt;
|Get time speed.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setTimeSpeed(float speed)|setTimeSpeed]](float speed)&lt;br /&gt;
|Set time speed bettwen [0,10], defult is 1.0.&lt;br /&gt;
|-&lt;br /&gt;
|[[FontCharacter]]&lt;br /&gt;
|[[Core:getFontCharacter(String font, int fontHeight, String character)|getFontCharacter]](String font, int fontHeight, String character)&lt;br /&gt;
|Get a font character.&lt;br /&gt;
|-&lt;br /&gt;
|[[Sound]]&lt;br /&gt;
|[[Core:getSound()|getSound]]()&lt;br /&gt;
|Load [[sound]].&lt;br /&gt;
|-&lt;br /&gt;
|[[Work]]&lt;br /&gt;
|[[Core:getCurrentWork()|getCurrentWork]]()&lt;br /&gt;
|Return the current work.&lt;br /&gt;
|-&lt;br /&gt;
|[[LuaScript]]&lt;br /&gt;
|[[Core:getCurrentLuaScript()|getCurrentLuaScript]]()&lt;br /&gt;
|Returns the the current executing Lua script.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSoundCamera(Camera camera)|setSoundCamera]]([[Camera]] camera)&lt;br /&gt;
|Set to which camera sound will go. This will be removed in the future.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSoundCameraMatrix(Matrix cameraMatrix)|setSoundCameraMatrix]]([[Matrix]] cameraMatrix)&lt;br /&gt;
|Set sound camera matrix. this is only useful when sound camera is set to nil.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setDebug2DCamera(Camera camera)|setDebug2DCamera]]([[Camera]] camera)&lt;br /&gt;
|Set to which camera 2D debug text should be renderd to.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:addDebugLine(Vec3 l1, Vec3 l2, float time, Vec3 color)|addDebugLine]]([[Vec3]] l1, [[Vec3]] l2, float time, [[Vec3]] color)&lt;br /&gt;
|Add debug line.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:addDebugLine(Line3D line, float time, Vec3 color)|addDebugLine]]([[Line3D]] line, float time, [[Vec3]] color)&lt;br /&gt;
|Add debug line.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:addDebugSphere(Sphere sphere, float time, Vec3 color)|addDebugSphere]]([[Sphere]] [[sphere]], float time, [[Vec3]] color)&lt;br /&gt;
|Add debug [[sphere]].&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:addDebugBox(Box box, float time, Vec3 color)|addDebugBox]]([[Box]] [[box]], float time, [[Vec3]] color)&lt;br /&gt;
|Add debug [[box]].&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:clearDebugLines()|clearDebugLines]]()&lt;br /&gt;
|Clear all debug data, this includes lines, Spheres and debugBoxes.&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[Core:getFrameNumber()|getFrameNumber]]()&lt;br /&gt;
|get number of rendered frame sence program started.&lt;br /&gt;
|-&lt;br /&gt;
|[[Model]]&lt;br /&gt;
|[[Core:getModel(string modelName)|getModel]]([[string]] modelName)&lt;br /&gt;
|Load model.&lt;br /&gt;
|-&lt;br /&gt;
|[[Shader]]&lt;br /&gt;
|[[Core:getShader(string shaderName)|getShader]]([[string]] shaderName)&lt;br /&gt;
|Load shader.&lt;br /&gt;
|-&lt;br /&gt;
|[[Shader]]&lt;br /&gt;
|[[Core:getShader(string shaderName, string definition)|getShader]]([[string]] shaderName, string definition)&lt;br /&gt;
|Load shader with one definition.&lt;br /&gt;
|-&lt;br /&gt;
|[[Shader]]&lt;br /&gt;
|[[Core:getShader(string shaderName, table definitions)|getShader]]([[string]] shaderName, [[table]] definitions)&lt;br /&gt;
|Load shader with one definitions.&lt;br /&gt;
|-&lt;br /&gt;
|[[Texture]]&lt;br /&gt;
|[[Core:getTexture(string textureName)|getTexture]]([[string]] textureName)&lt;br /&gt;
|Load texture.&lt;br /&gt;
|-&lt;br /&gt;
|[[Texture]]&lt;br /&gt;
|[[Core:getTexture(File aFile)|getTexture]]([[File]] aFile)&lt;br /&gt;
|Load texture from a file.&lt;br /&gt;
|-&lt;br /&gt;
|[[File]]&lt;br /&gt;
|[[Core:getDataFolder()|getDataFolder]]()&lt;br /&gt;
|Get main folder.&lt;br /&gt;
|-&lt;br /&gt;
|[[File]]&lt;br /&gt;
|[[Core:getDataFolder(string subFolder)|getDataFolder]]([[string]] subFolder)&lt;br /&gt;
|Get sub folder from main folder.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2]]&lt;br /&gt;
|[[Core:getScreenResolution()|getScreenResolution]]()&lt;br /&gt;
|Get screen resolution.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2]]&lt;br /&gt;
|[[Core:getRenderResolution()|getRenderResolution]]()&lt;br /&gt;
|Get render resolution. &lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getRenderScale()|getRenderScale]]()&lt;br /&gt;
|Get render scale. &lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Core:getSteamName()|getSteamName]]()&lt;br /&gt;
|returns the name of the current steam user, if available.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Core:setScriptNetworkId(string name)|setScriptNetworkId]](string name)&lt;br /&gt;
|Sets the network name of this script. returns true on success. [This name should be set by all clients individually]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:requireScriptNetworkIdToRunUpdate(bool set)|requireScriptNetworkIdToRunUpdate]](bool set)&lt;br /&gt;
|If set true, the script will not run &amp;quot;update&amp;quot; until setScriptNetworkId() is set&lt;br /&gt;
|-&lt;br /&gt;
|number&lt;br /&gt;
|[[Core:getPlayerId()|getPlayerId]]()&lt;br /&gt;
|returns the unique player id of the client. to know where he is supossed to be.&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Core:getNetworkName()|getNetworkName]]()&lt;br /&gt;
|returns netName for the current script&lt;br /&gt;
|-&lt;br /&gt;
|[[Client]]&lt;br /&gt;
|[[Core:getNetworkClient()|getNetworkClient]]()&lt;br /&gt;
|Returns the client, using multiple times will return the same client. (There is one client)&lt;br /&gt;
|-&lt;br /&gt;
|[[Server]]&lt;br /&gt;
|[[Core:getNetworkServer()|getNetworkServer]]()&lt;br /&gt;
|Returns the server, using multiple times will return the same server. (There is one server)&lt;br /&gt;
|-&lt;br /&gt;
|{ {name=string(), ip=string(), port=int(), time=int()} }&lt;br /&gt;
|[[Core:getServerList()|getServerList]]()&lt;br /&gt;
|Returns the global serverlist.&lt;br /&gt;
|-&lt;br /&gt;
|{ {name=string(), ip=string(), port=int(), time=int()} }&lt;br /&gt;
|[[Core:getServerList(int time)|getServerList]](int time)&lt;br /&gt;
|Returns the global serverlist. Time is in the format epoch seconds.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Core:isInMultiplayer()|isInMultiplayer]]()&lt;br /&gt;
|Returns true if the client is connected to a server.&lt;br /&gt;
|-&lt;br /&gt;
|number&lt;br /&gt;
|[[Core:getIndexOfNetworkName(string networkName)|getIndexOfNetworkName]](string networkName)&lt;br /&gt;
|Returns the index of the script with the networkName, or 0 if none was found&lt;br /&gt;
|-&lt;br /&gt;
|[[LuaScript]]&lt;br /&gt;
|[[Core:getScriptOfNetworkName(string networkName)|getScriptOfNetworkName]](string networkName)&lt;br /&gt;
|Returns the script that uses the networkName, or nil if none was found&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Core:getNetworkNameOf(object param)|getNetworkNameOf]](object param)&lt;br /&gt;
|Returns the Network name of the script. takes number(index of a script) or a [[LuaScript]]&lt;br /&gt;
|-&lt;br /&gt;
|[[ComUnit]]&lt;br /&gt;
|[[Core:getComUnit()|getComUnit]]()&lt;br /&gt;
|Get screen resolution.&lt;br /&gt;
|-&lt;br /&gt;
|[[bool]]&lt;br /&gt;
|[[Core:existLuaScript(int luaIndex)|existLuaScript]](int luaIndex)&lt;br /&gt;
|Returns true if lua script is running.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getBillboard()|getBillboard]]()&lt;br /&gt;
|Get the billboard for this script.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getBillboard(int luaIndex)|getBillboard]](int luaIndex)&lt;br /&gt;
|Get the billboard for luaIndex.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getBillboard(string name)|getBillboard]]([[string]] name)&lt;br /&gt;
|Get billboard by name.&lt;br /&gt;
|-&lt;br /&gt;
|[[Input]]&lt;br /&gt;
|[[Core:getInput()|getInput]]()&lt;br /&gt;
|Get input.&lt;br /&gt;
|-&lt;br /&gt;
|[[HighScore]]&lt;br /&gt;
|[[Core:getHighScore()|getHighScore]]()&lt;br /&gt;
|Get HighScore.&lt;br /&gt;
|-&lt;br /&gt;
|[[Cursor]]&lt;br /&gt;
|[[Core:getCursor()|getCursor]]()&lt;br /&gt;
|Get cursor.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:stopCore()|stopCore]]()&lt;br /&gt;
|Stop score.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:quitMainMenu()|quitMainMenu]]()&lt;br /&gt;
|If game is in main menu then the game will be shutdown.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:quitToMainMenu()|quitToMainMenu]]()&lt;br /&gt;
|Quit from mapeditor or game to main menu.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:quitToMapeditor()|quitToMapeditor]]()&lt;br /&gt;
|Quit from game to mapeditor.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Core:isInEditor()|isInEditor]]()&lt;br /&gt;
|Return true when in editor or when testing a map from the editor.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:startMap(string fileName)|startMap]]([[string]] fileName)&lt;br /&gt;
|start map with name like fileName=&amp;quot;Data/Map/fil.map&amp;quot;.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:startMultiplayerClonedMaps(string fileName, nil clientIds)|startMultiplayerClonedMaps]](string fileName, nil clientIds)&lt;br /&gt;
|start map with name like fileName=&amp;quot;Data/Map/fil.map&amp;quot;. &lt;br /&gt;
clientIds is a list of all client ids that need a private world to be loaded. example {2,3,4,5} &lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:startMapInDebugMode(string fileName)|startMapInDebugMode]]([[string]] fileName)&lt;br /&gt;
|start map in debug mode with name like fileName=&amp;quot;Data/Map/fil.map&amp;quot;.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:startMapEditor(string fileName)|startMapEditor]]([[string]] fileName)&lt;br /&gt;
|start mapEditor. If fileName is &amp;quot;&amp;quot; then a new map will be created.&lt;br /&gt;
|-&lt;br /&gt;
|[[Panel]]&lt;br /&gt;
|[[Core:getPanelWithKeyboardFocus()|getPanelWithKeyboardFocus]]()&lt;br /&gt;
|Return the curent [[panel]] with keyboard focus.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getGlobalBillboard(string billboardName)|getGlobalBillboard]]([[string]] billboardName)&lt;br /&gt;
|Create or collect the billboard with a given name. The Billboard will exist unit the game shutsdown. The billboardName must be unique or allready exist as a globalBillboard.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getGameSessionBillboard(string billboardName)|getGameSessionBillboard]]([[string]] billboardName)&lt;br /&gt;
|Create or collect the billboard with a given name. The Billboard will exist unit the game current map is shutdown.&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Core:getMainCamera()|getMainCamera]]()&lt;br /&gt;
|Get the main camera.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setMainCamera(Camera mainCamera)|setMainCamera]]([[Camera]] mainCamera)&lt;br /&gt;
|set the main camera.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setRenderScale(float scale)|setRenderScale]](float scale)&lt;br /&gt;
|set the scale factor of the current render resolution. should be between [0.5,2.0]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setRenderResolution(Vec2 resolution)|setRenderResolution]]([[Vec2]] resolution)&lt;br /&gt;
|set Render resolution.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setMaxFrameRate(int maxFrameRate)|setMaxFrameRate]](int maxFrameRate)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:skipRenderFrame()|skipRenderFrame]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setCursor(string cursorFilePath)|setCursor]]([[string]] cursorFilePath)&lt;br /&gt;
|Set the cursor icon. NOTE! must be a *.bmp file.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSounMasterGain(float gain)|setSounMasterGain]](float gain)&lt;br /&gt;
|set sound master gain, gain is between [0,1]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSoundMusicGain(float gain)|setSoundMusicGain]](float gain)&lt;br /&gt;
|set music gain, gain is between [0,1]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSounEffectGain(float gain)|setSounEffectGain]](float gain)&lt;br /&gt;
|set effect gain, gain is between [0,1]&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getSounMasterGain()|getSounMasterGain]]()&lt;br /&gt;
|get sound master gain&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getSounMusicGain()|getSounMusicGain]]()&lt;br /&gt;
|get sound master gain&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getSounEffectGain()|getSounEffectGain]]()&lt;br /&gt;
|get sound master gain&lt;br /&gt;
|-&lt;br /&gt;
|[[Panel]]&lt;br /&gt;
|[[Core:getPanelWithMouseFocus()|getPanelWithMouseFocus]]()&lt;br /&gt;
|get panel with mouse focus.&lt;br /&gt;
|-&lt;br /&gt;
|[[Panel]]&lt;br /&gt;
|[[Core:getPanelWithKeyboardFocus()|getPanelWithKeyboardFocus]]()&lt;br /&gt;
|get panel with mouse focus.&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Core:getMachineId()|getMachineId]]()&lt;br /&gt;
|get the machine ID.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setFullscreen(bool fullscreen)|setFullscreen]](bool fullscreen)&lt;br /&gt;
|Set if we should use fullscreen.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setVsync(bool vSync)|setVsync]](bool vSync)&lt;br /&gt;
|Set if vSyncshould turned od.&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=Core&amp;diff=165</id>
		<title>Core</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=Core&amp;diff=165"/>
		<updated>2025-07-26T17:37:56Z</updated>

		<summary type="html">&lt;p&gt;Anders: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:CoreExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Static functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setUpdateHz(float hz)|setUpdateHz]](float hz)&lt;br /&gt;
|Sets the update frequency of the script based on in game time. minimum hz that can be set is &amp;gt;0.1 below that it will update every frame&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setUpdateHzRealTime(float hz)|setUpdateHzRealTime]](float hz)&lt;br /&gt;
|Sets the update frequency of the script based on real time. minimum hz that can be set is &amp;gt;0.1 below that it will update every frame&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:skipFrames(int frames)|skipFrames]](int frames)&lt;br /&gt;
|Skip a specified number of frames once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:skipTime(float seconds)|skipTime]](float seconds)&lt;br /&gt;
|Skip a specified time only once. This function needs to be called every time the script want to skip a specified number of frames.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getAverageDeltaTime()|getAverageDeltaTime]]()&lt;br /&gt;
|Get the average delta time over the last 100 frames.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getDeltaTime()|getDeltaTime]]()&lt;br /&gt;
|Get the last frames delta time.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getRealDeltaTime()|getRealDeltaTime]]()&lt;br /&gt;
|Get the last frames delta time without speed factor.&lt;br /&gt;
|-&lt;br /&gt;
|double&lt;br /&gt;
|[[Core:getGameTime()|getGameTime]]()&lt;br /&gt;
|Get time since the program started, with speed factor.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getTime()|getTime]]()&lt;br /&gt;
|Get time since the program started.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getTimeSpeed()|getTimeSpeed]]()&lt;br /&gt;
|Get time speed.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setTimeSpeed(float speed)|setTimeSpeed]](float speed)&lt;br /&gt;
|Set time speed bettwen [0,10], defult is 1.0.&lt;br /&gt;
|-&lt;br /&gt;
|[[FontCharacter]]&lt;br /&gt;
|[[Core:getFontCharacter(String font, int fontHeight, String character)|getFontCharacter]](String font, int fontHeight, String character)&lt;br /&gt;
|Get a font character.&lt;br /&gt;
|-&lt;br /&gt;
|[[Sound]]&lt;br /&gt;
|[[Core:getSound()|getSound]]()&lt;br /&gt;
|Load [[sound]].&lt;br /&gt;
|-&lt;br /&gt;
|[[Work]]&lt;br /&gt;
|[[Core:getCurrentWork()|getCurrentWork]]()&lt;br /&gt;
|Return the current work.&lt;br /&gt;
|-&lt;br /&gt;
|[[LuaScript]]&lt;br /&gt;
|[[Core:getCurrentLuaScript()|getCurrentLuaScript]]()&lt;br /&gt;
|Returns the the current executing Lua script.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSoundCamera(Camera camera)|setSoundCamera]]([[Camera]] camera)&lt;br /&gt;
|Set to which camera sound will go. This will be removed in the future.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSoundCameraMatrix(Matrix cameraMatrix)|setSoundCameraMatrix]]([[Matrix]] cameraMatrix)&lt;br /&gt;
|Set sound camera matrix. this is only useful when sound camera is set to nil.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setDebug2DCamera(Camera camera)|setDebug2DCamera]]([[Camera]] camera)&lt;br /&gt;
|Set to which camera 2D debug text should be renderd to.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:addDebugLine(Vec3 l1, Vec3 l2, float time, Vec3 color)|addDebugLine]]([[Vec3]] l1, [[Vec3]] l2, float time, [[Vec3]] color)&lt;br /&gt;
|Add debug line.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:addDebugLine(Line3D line, float time, Vec3 color)|addDebugLine]]([[Line3D]] line, float time, [[Vec3]] color)&lt;br /&gt;
|Add debug line.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:addDebugSphere(Sphere sphere, float time, Vec3 color)|addDebugSphere]]([[Sphere]] [[sphere]], float time, [[Vec3]] color)&lt;br /&gt;
|Add debug [[sphere]].&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:addDebugBox(Box box, float time, Vec3 color)|addDebugBox]]([[Box]] [[box]], float time, [[Vec3]] color)&lt;br /&gt;
|Add debug [[box]].&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:clearDebugLines()|clearDebugLines]]()&lt;br /&gt;
|Clear all debug data, this includes lines, Spheres and debugBoxes.&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[Core:getFrameNumber()|getFrameNumber]]()&lt;br /&gt;
|get number of rendered frame sence program started.&lt;br /&gt;
|-&lt;br /&gt;
|[[Model]]&lt;br /&gt;
|[[Core:getModel(string modelName)|getModel]]([[string]] modelName)&lt;br /&gt;
|Load model.&lt;br /&gt;
|-&lt;br /&gt;
|[[Shader]]&lt;br /&gt;
|[[Core:getShader(string shaderName)|getShader]]([[string]] shaderName)&lt;br /&gt;
|Load shader.&lt;br /&gt;
|-&lt;br /&gt;
|[[Shader]]&lt;br /&gt;
|[[Core:getShader(string shaderName, string definition)|getShader]]([[string]] shaderName, string definition)&lt;br /&gt;
|Load shader with one definition.&lt;br /&gt;
|-&lt;br /&gt;
|[[Shader]]&lt;br /&gt;
|[[Core:getShader(string shaderName, table definitions)|getShader]]([[string]] shaderName, [[table]] definitions)&lt;br /&gt;
|Load shader with one definitions.&lt;br /&gt;
|-&lt;br /&gt;
|[[Texture]]&lt;br /&gt;
|[[Core:getTexture(string textureName)|getTexture]]([[string]] textureName)&lt;br /&gt;
|Load texture.&lt;br /&gt;
|-&lt;br /&gt;
|[[Texture]]&lt;br /&gt;
|[[Core:getTexture(File aFile)|getTexture]]([[File]] aFile)&lt;br /&gt;
|Load texture from a file.&lt;br /&gt;
|-&lt;br /&gt;
|[[File]]&lt;br /&gt;
|[[Core:getDataFolder()|getDataFolder]]()&lt;br /&gt;
|Get main folder.&lt;br /&gt;
|-&lt;br /&gt;
|[[File]]&lt;br /&gt;
|[[Core:getDataFolder(string subFolder)|getDataFolder]]([[string]] subFolder)&lt;br /&gt;
|Get sub folder from main folder.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2]]&lt;br /&gt;
|[[Core:getScreenResolution()|getScreenResolution]]()&lt;br /&gt;
|Get screen resolution.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2]]&lt;br /&gt;
|[[Core:getRenderResolution()|getRenderResolution]]()&lt;br /&gt;
|Get render resolution. &lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getRenderScale()|getRenderScale]]()&lt;br /&gt;
|Get render scale. &lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Core:getSteamName()|getSteamName]]()&lt;br /&gt;
|returns the name of the current steam user, if available.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Core:setScriptNetworkId(string name)|setScriptNetworkId]](string name)&lt;br /&gt;
|Sets the network name of this script. returns true on success. [This name should be set by all clients individually]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:requireScriptNetworkIdToRunUpdate(bool set)|requireScriptNetworkIdToRunUpdate]](bool set)&lt;br /&gt;
|If set true, the script will not run &amp;quot;update&amp;quot; until setScriptNetworkId() is set&lt;br /&gt;
|-&lt;br /&gt;
|number&lt;br /&gt;
|[[Core:getPlayerId()|getPlayerId]]()&lt;br /&gt;
|returns the unique player id of the client. to know where he is supossed to be.&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Core:getNetworkName()|getNetworkName]]()&lt;br /&gt;
|returns netName for the current script&lt;br /&gt;
|-&lt;br /&gt;
|[[Client]]&lt;br /&gt;
|[[Core:getNetworkClient()|getNetworkClient]]()&lt;br /&gt;
|Returns the client, using multiple times will return the same client. (There is one client)&lt;br /&gt;
|-&lt;br /&gt;
|[[Server]]&lt;br /&gt;
|[[Core:getNetworkServer()|getNetworkServer]]()&lt;br /&gt;
|Returns the server, using multiple times will return the same server. (There is one server)&lt;br /&gt;
|-&lt;br /&gt;
|{ {name=string(), ip=string(), port=int(), time=int()} }&lt;br /&gt;
|[[Core:getServerList()|getServerList]]()&lt;br /&gt;
|Returns the global serverlist.&lt;br /&gt;
|-&lt;br /&gt;
|{ {name=string(), ip=string(), port=int(), time=int()} }&lt;br /&gt;
|[[Core:getServerList(int time)|getServerList]](int time)&lt;br /&gt;
|Returns the global serverlist. Time is in the format epoch seconds.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Core:isInMultiplayer()|isInMultiplayer]]()&lt;br /&gt;
|Returns true if the client is connected to a server.&lt;br /&gt;
|-&lt;br /&gt;
|number&lt;br /&gt;
|[[Core:getIndexOfNetworkName(string networkName)|getIndexOfNetworkName]](string networkName)&lt;br /&gt;
|Returns the index of the script with the networkName, or 0 if none was found&lt;br /&gt;
|-&lt;br /&gt;
|[[LuaScript]]&lt;br /&gt;
|[[Core:getScriptOfNetworkName(string networkName)|getScriptOfNetworkName]](string networkName)&lt;br /&gt;
|Returns the script that uses the networkName, or nil if none was found&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Core:getNetworkNameOf(object param)|getNetworkNameOf]](object param)&lt;br /&gt;
|Returns the Network name of the script. takes number(index of a script) or a [[LuaScript]]&lt;br /&gt;
|-&lt;br /&gt;
|[[ComUnit]]&lt;br /&gt;
|[[Core:getComUnit()|getComUnit]]()&lt;br /&gt;
|Get screen resolution.&lt;br /&gt;
|-&lt;br /&gt;
|[[bool]]&lt;br /&gt;
|[[Core:existLuaScript(int luaIndex)|existLuaScript]](int luaIndex)&lt;br /&gt;
|Returns true if lua script is running.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getBillboard()|getBillboard]]()&lt;br /&gt;
|Get the billboard for this script.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getBillboard(int luaIndex)|getBillboard]](int luaIndex)&lt;br /&gt;
|Get the billboard for luaIndex.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getBillboard(string name)|getBillboard]]([[string]] name)&lt;br /&gt;
|Get billboard by name.&lt;br /&gt;
|-&lt;br /&gt;
|[[Input]]&lt;br /&gt;
|[[Core:getInput()|getInput]]()&lt;br /&gt;
|Get input.&lt;br /&gt;
|-&lt;br /&gt;
|[[HighScore]]&lt;br /&gt;
|[[Core:getHighScore()|getHighScore]]()&lt;br /&gt;
|Get HighScore.&lt;br /&gt;
|-&lt;br /&gt;
|[[Cursor]]&lt;br /&gt;
|[[Core:getCursor()|getCursor]]()&lt;br /&gt;
|Get cursor.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:stopCore()|stopCore]]()&lt;br /&gt;
|Stop score.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:quitMainMenu()|quitMainMenu]]()&lt;br /&gt;
|If game is in main menu then the game will be shutdown.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:quitToMainMenu()|quitToMainMenu]]()&lt;br /&gt;
|Quit from mapeditor or game to main menu.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:quitToMapeditor()|quitToMapeditor]]()&lt;br /&gt;
|Quit from game to mapeditor.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Core:isInEditor()|isInEditor]]()&lt;br /&gt;
|Return true when in editor or when testing a map from the editor.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:startMap(string fileName)|startMap]]([[string]] fileName)&lt;br /&gt;
|start map with name like fileName=&amp;quot;Data/Map/fil.map&amp;quot;.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:startMultiplayerClonedMaps(string fileName, nil clientIds)|startMultiplayerClonedMaps]](string fileName, nil clientIds)&lt;br /&gt;
|start map with name like fileName=&amp;quot;Data/Map/fil.map&amp;quot;. &lt;br /&gt;
clientIds is a list of all client ids that need a private world to be loaded. example {2,3,4,5} &lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:startMapInDebugMode(string fileName)|startMapInDebugMode]]([[string]] fileName)&lt;br /&gt;
|start map in debug mode with name like fileName=&amp;quot;Data/Map/fil.map&amp;quot;.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:startMapEditor(string fileName)|startMapEditor]]([[string]] fileName)&lt;br /&gt;
|start mapEditor. If fileName is &amp;quot;&amp;quot; then a new map will be created.&lt;br /&gt;
|-&lt;br /&gt;
|[[Panel]]&lt;br /&gt;
|[[Core:getPanelWithKeyboardFocus()|getPanelWithKeyboardFocus]]()&lt;br /&gt;
|Return the curent [[panel]] with keyboard focus.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getGlobalBillboard(string billboardName)|getGlobalBillboard]]([[string]] billboardName)&lt;br /&gt;
|Create or collect the billboard with a given name. The Billboard will exist unit the game shutsdown. The billboardName must be unique or allready exist as a globalBillboard.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getGameSessionBillboard(string billboardName)|getGameSessionBillboard]]([[string]] billboardName)&lt;br /&gt;
|Create or collect the billboard with a given name. The Billboard will exist unit the game current map is shutdown.&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Core:getMainCamera()|getMainCamera]]()&lt;br /&gt;
|Get the main camera.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setMainCamera(Camera mainCamera)|setMainCamera]]([[Camera]] mainCamera)&lt;br /&gt;
|set the main camera.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setRenderScale(float scale)|setRenderScale]](float scale)&lt;br /&gt;
|set the scale factor of the current render resolution. should be between [0.5,2.0]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setRenderResolution(Vec2 resolution)|setRenderResolution]]([[Vec2]] resolution)&lt;br /&gt;
|set Render resolution.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setMaxFrameRate(int maxFrameRate)|setMaxFrameRate]](int maxFrameRate)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:skipRenderFrame()|skipRenderFrame]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setCursor(string cursorFilePath)|setCursor]]([[string]] cursorFilePath)&lt;br /&gt;
|Set the cursor icon. NOTE! must be a *.bmp file.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSounMasterGain(float gain)|setSounMasterGain]](float gain)&lt;br /&gt;
|set sound master gain, gain is between [0,1]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSoundMusicGain(float gain)|setSoundMusicGain]](float gain)&lt;br /&gt;
|set music gain, gain is between [0,1]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSounEffectGain(float gain)|setSounEffectGain]](float gain)&lt;br /&gt;
|set effect gain, gain is between [0,1]&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getSounMasterGain()|getSounMasterGain]]()&lt;br /&gt;
|get sound master gain&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getSounMusicGain()|getSounMusicGain]]()&lt;br /&gt;
|get sound master gain&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getSounEffectGain()|getSounEffectGain]]()&lt;br /&gt;
|get sound master gain&lt;br /&gt;
|-&lt;br /&gt;
|[[Panel]]&lt;br /&gt;
|[[Core:getPanelWithMouseFocus()|getPanelWithMouseFocus]]()&lt;br /&gt;
|get panel with mouse focus.&lt;br /&gt;
|-&lt;br /&gt;
|[[Panel]]&lt;br /&gt;
|[[Core:getPanelWithKeyboardFocus()|getPanelWithKeyboardFocus]]()&lt;br /&gt;
|get panel with mouse focus.&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Core:getMachineId()|getMachineId]]()&lt;br /&gt;
|get the machine ID.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setFullscreen(bool fullscreen)|setFullscreen]](bool fullscreen)&lt;br /&gt;
|Set if we should use fullscreen.&lt;br /&gt;
|-&lt;br /&gt;
&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=Core&amp;diff=164</id>
		<title>Core</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=Core&amp;diff=164"/>
		<updated>2025-07-26T17:36:39Z</updated>

		<summary type="html">&lt;p&gt;Anders: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:CoreExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Static functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setUpdateHz(float hz)|setUpdateHz]](float hz)&lt;br /&gt;
|Sets the update frequency of the script based on in game time. minimum hz that can be set is &amp;gt;0.1 below that it will update every frame&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setUpdateHzRealTime(float hz)|setUpdateHzRealTime]](float hz)&lt;br /&gt;
|Sets the update frequency of the script based on real time. minimum hz that can be set is &amp;gt;0.1 below that it will update every frame&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:skipFrames(int frames)|skipFrames]](int frames)&lt;br /&gt;
|Skip a specified number of frames once.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:skipTime(float seconds)|skipTime]](float seconds)&lt;br /&gt;
|Skip a specified time only once. This function needs to be called every time the script want to skip a specified number of frames.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getAverageDeltaTime()|getAverageDeltaTime]]()&lt;br /&gt;
|Get the average delta time over the last 100 frames.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getDeltaTime()|getDeltaTime]]()&lt;br /&gt;
|Get the last frames delta time.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getRealDeltaTime()|getRealDeltaTime]]()&lt;br /&gt;
|Get the last frames delta time without speed factor.&lt;br /&gt;
|-&lt;br /&gt;
|double&lt;br /&gt;
|[[Core:getGameTime()|getGameTime]]()&lt;br /&gt;
|Get time since the program started, with speed factor.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getTime()|getTime]]()&lt;br /&gt;
|Get time since the program started.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getTimeSpeed()|getTimeSpeed]]()&lt;br /&gt;
|Get time speed.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setTimeSpeed(float speed)|setTimeSpeed]](float speed)&lt;br /&gt;
|Set time speed bettwen [0,10], defult is 1.0.&lt;br /&gt;
|-&lt;br /&gt;
|[[FontCharacter]]&lt;br /&gt;
|[[Core:getFontCharacter(String font, int fontHeight, String character)|getFontCharacter]](String font, int fontHeight, String character)&lt;br /&gt;
|Get a font character.&lt;br /&gt;
|-&lt;br /&gt;
|[[Sound]]&lt;br /&gt;
|[[Core:getSound()|getSound]]()&lt;br /&gt;
|Load [[sound]].&lt;br /&gt;
|-&lt;br /&gt;
|[[Work]]&lt;br /&gt;
|[[Core:getCurrentWork()|getCurrentWork]]()&lt;br /&gt;
|Return the current work.&lt;br /&gt;
|-&lt;br /&gt;
|[[LuaScript]]&lt;br /&gt;
|[[Core:getCurrentLuaScript()|getCurrentLuaScript]]()&lt;br /&gt;
|Returns the the current executing Lua script.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSoundCamera(Camera camera)|setSoundCamera]]([[Camera]] camera)&lt;br /&gt;
|Set to which camera sound will go. This will be removed in the future.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSoundCameraMatrix(Matrix cameraMatrix)|setSoundCameraMatrix]]([[Matrix]] cameraMatrix)&lt;br /&gt;
|Set sound camera matrix. this is only useful when sound camera is set to nil.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setDebug2DCamera(Camera camera)|setDebug2DCamera]]([[Camera]] camera)&lt;br /&gt;
|Set to which camera 2D debug text should be renderd to.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:addDebugLine(Vec3 l1, Vec3 l2, float time, Vec3 color)|addDebugLine]]([[Vec3]] l1, [[Vec3]] l2, float time, [[Vec3]] color)&lt;br /&gt;
|Add debug line.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:addDebugLine(Line3D line, float time, Vec3 color)|addDebugLine]]([[Line3D]] line, float time, [[Vec3]] color)&lt;br /&gt;
|Add debug line.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:addDebugSphere(Sphere sphere, float time, Vec3 color)|addDebugSphere]]([[Sphere]] [[sphere]], float time, [[Vec3]] color)&lt;br /&gt;
|Add debug [[sphere]].&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:addDebugBox(Box box, float time, Vec3 color)|addDebugBox]]([[Box]] [[box]], float time, [[Vec3]] color)&lt;br /&gt;
|Add debug [[box]].&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:clearDebugLines()|clearDebugLines]]()&lt;br /&gt;
|Clear all debug data, this includes lines, Spheres and debugBoxes.&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[Core:getFrameNumber()|getFrameNumber]]()&lt;br /&gt;
|get number of rendered frame sence program started.&lt;br /&gt;
|-&lt;br /&gt;
|[[Model]]&lt;br /&gt;
|[[Core:getModel(string modelName)|getModel]]([[string]] modelName)&lt;br /&gt;
|Load model.&lt;br /&gt;
|-&lt;br /&gt;
|[[Shader]]&lt;br /&gt;
|[[Core:getShader(string shaderName)|getShader]]([[string]] shaderName)&lt;br /&gt;
|Load shader.&lt;br /&gt;
|-&lt;br /&gt;
|[[Shader]]&lt;br /&gt;
|[[Core:getShader(string shaderName, string definition)|getShader]]([[string]] shaderName, string definition)&lt;br /&gt;
|Load shader with one definition.&lt;br /&gt;
|-&lt;br /&gt;
|[[Shader]]&lt;br /&gt;
|[[Core:getShader(string shaderName, table definitions)|getShader]]([[string]] shaderName, [[table]] definitions)&lt;br /&gt;
|Load shader with one definitions.&lt;br /&gt;
|-&lt;br /&gt;
|[[Texture]]&lt;br /&gt;
|[[Core:getTexture(string textureName)|getTexture]]([[string]] textureName)&lt;br /&gt;
|Load texture.&lt;br /&gt;
|-&lt;br /&gt;
|[[Texture]]&lt;br /&gt;
|[[Core:getTexture(File aFile)|getTexture]]([[File]] aFile)&lt;br /&gt;
|Load texture from a file.&lt;br /&gt;
|-&lt;br /&gt;
|[[File]]&lt;br /&gt;
|[[Core:getDataFolder()|getDataFolder]]()&lt;br /&gt;
|Get main folder.&lt;br /&gt;
|-&lt;br /&gt;
|[[File]]&lt;br /&gt;
|[[Core:getDataFolder(string subFolder)|getDataFolder]]([[string]] subFolder)&lt;br /&gt;
|Get sub folder from main folder.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2]]&lt;br /&gt;
|[[Core:getScreenResolution()|getScreenResolution]]()&lt;br /&gt;
|Get screen resolution.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2]]&lt;br /&gt;
|[[Core:getRenderResolution()|getRenderResolution]]()&lt;br /&gt;
|Get render resolution. &lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getRenderScale()|getRenderScale]]()&lt;br /&gt;
|Get render scale. &lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Core:getSteamName()|getSteamName]]()&lt;br /&gt;
|returns the name of the current steam user, if available.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Core:setScriptNetworkId(string name)|setScriptNetworkId]](string name)&lt;br /&gt;
|Sets the network name of this script. returns true on success. [This name should be set by all clients individually]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:requireScriptNetworkIdToRunUpdate(bool set)|requireScriptNetworkIdToRunUpdate]](bool set)&lt;br /&gt;
|If set true, the script will not run &amp;quot;update&amp;quot; until setScriptNetworkId() is set&lt;br /&gt;
|-&lt;br /&gt;
|number&lt;br /&gt;
|[[Core:getPlayerId()|getPlayerId]]()&lt;br /&gt;
|returns the unique player id of the client. to know where he is supossed to be.&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Core:getNetworkName()|getNetworkName]]()&lt;br /&gt;
|returns netName for the current script&lt;br /&gt;
|-&lt;br /&gt;
|[[Client]]&lt;br /&gt;
|[[Core:getNetworkClient()|getNetworkClient]]()&lt;br /&gt;
|Returns the client, using multiple times will return the same client. (There is one client)&lt;br /&gt;
|-&lt;br /&gt;
|[[Server]]&lt;br /&gt;
|[[Core:getNetworkServer()|getNetworkServer]]()&lt;br /&gt;
|Returns the server, using multiple times will return the same server. (There is one server)&lt;br /&gt;
|-&lt;br /&gt;
|{ {name=string(), ip=string(), port=int(), time=int()} }&lt;br /&gt;
|[[Core:getServerList()|getServerList]]()&lt;br /&gt;
|Returns the global serverlist.&lt;br /&gt;
|-&lt;br /&gt;
|{ {name=string(), ip=string(), port=int(), time=int()} }&lt;br /&gt;
|[[Core:getServerList(int time)|getServerList]](int time)&lt;br /&gt;
|Returns the global serverlist. Time is in the format epoch seconds.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Core:isInMultiplayer()|isInMultiplayer]]()&lt;br /&gt;
|Returns true if the client is connected to a server.&lt;br /&gt;
|-&lt;br /&gt;
|number&lt;br /&gt;
|[[Core:getIndexOfNetworkName(string networkName)|getIndexOfNetworkName]](string networkName)&lt;br /&gt;
|Returns the index of the script with the networkName, or 0 if none was found&lt;br /&gt;
|-&lt;br /&gt;
|[[LuaScript]]&lt;br /&gt;
|[[Core:getScriptOfNetworkName(string networkName)|getScriptOfNetworkName]](string networkName)&lt;br /&gt;
|Returns the script that uses the networkName, or nil if none was found&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Core:getNetworkNameOf(object param)|getNetworkNameOf]](object param)&lt;br /&gt;
|Returns the Network name of the script. takes number(index of a script) or a [[LuaScript]]&lt;br /&gt;
|-&lt;br /&gt;
|[[ComUnit]]&lt;br /&gt;
|[[Core:getComUnit()|getComUnit]]()&lt;br /&gt;
|Get screen resolution.&lt;br /&gt;
|-&lt;br /&gt;
|[[bool]]&lt;br /&gt;
|[[Core:existLuaScript(int luaIndex)|existLuaScript]](int luaIndex)&lt;br /&gt;
|Returns true if lua script is running.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getBillboard()|getBillboard]]()&lt;br /&gt;
|Get the billboard for this script.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getBillboard(int luaIndex)|getBillboard]](int luaIndex)&lt;br /&gt;
|Get the billboard for luaIndex.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getBillboard(string name)|getBillboard]]([[string]] name)&lt;br /&gt;
|Get billboard by name.&lt;br /&gt;
|-&lt;br /&gt;
|[[Input]]&lt;br /&gt;
|[[Core:getInput()|getInput]]()&lt;br /&gt;
|Get input.&lt;br /&gt;
|-&lt;br /&gt;
|[[HighScore]]&lt;br /&gt;
|[[Core:getHighScore()|getHighScore]]()&lt;br /&gt;
|Get HighScore.&lt;br /&gt;
|-&lt;br /&gt;
|[[Cursor]]&lt;br /&gt;
|[[Core:getCursor()|getCursor]]()&lt;br /&gt;
|Get cursor.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:stopCore()|stopCore]]()&lt;br /&gt;
|Stop score.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:quitMainMenu()|quitMainMenu]]()&lt;br /&gt;
|If game is in main menu then the game will be shutdown.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:quitToMainMenu()|quitToMainMenu]]()&lt;br /&gt;
|Quit from mapeditor or game to main menu.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:quitToMapeditor()|quitToMapeditor]]()&lt;br /&gt;
|Quit from game to mapeditor.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Core:isInEditor()|isInEditor]]()&lt;br /&gt;
|Return true when in editor or when testing a map from the editor.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:startMap(string fileName)|startMap]]([[string]] fileName)&lt;br /&gt;
|start map with name like fileName=&amp;quot;Data/Map/fil.map&amp;quot;.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:startMultiplayerClonedMaps(string fileName, nil clientIds)|startMultiplayerClonedMaps]](string fileName, nil clientIds)&lt;br /&gt;
|start map with name like fileName=&amp;quot;Data/Map/fil.map&amp;quot;. &lt;br /&gt;
clientIds is a list of all client ids that need a private world to be loaded. example {2,3,4,5} &lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:startMapInDebugMode(string fileName)|startMapInDebugMode]]([[string]] fileName)&lt;br /&gt;
|start map in debug mode with name like fileName=&amp;quot;Data/Map/fil.map&amp;quot;.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:startMapEditor(string fileName)|startMapEditor]]([[string]] fileName)&lt;br /&gt;
|start mapEditor. If fileName is &amp;quot;&amp;quot; then a new map will be created.&lt;br /&gt;
|-&lt;br /&gt;
|[[Panel]]&lt;br /&gt;
|[[Core:getPanelWithKeyboardFocus()|getPanelWithKeyboardFocus]]()&lt;br /&gt;
|Return the curent [[panel]] with keyboard focus.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getGlobalBillboard(string billboardName)|getGlobalBillboard]]([[string]] billboardName)&lt;br /&gt;
|Create or collect the billboard with a given name. The Billboard will exist unit the game shutsdown. The billboardName must be unique or allready exist as a globalBillboard.&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[Core:getGameSessionBillboard(string billboardName)|getGameSessionBillboard]]([[string]] billboardName)&lt;br /&gt;
|Create or collect the billboard with a given name. The Billboard will exist unit the game current map is shutdown.&lt;br /&gt;
|-&lt;br /&gt;
|[[Camera]]&lt;br /&gt;
|[[Core:getMainCamera()|getMainCamera]]()&lt;br /&gt;
|Get the main camera.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setMainCamera(Camera mainCamera)|setMainCamera]]([[Camera]] mainCamera)&lt;br /&gt;
|set the main camera.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setRenderScale(float scale)|setRenderScale]](float scale)&lt;br /&gt;
|set the scale factor of the current render resolution. should be between [0.5,2.0]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setRenderResolution(Vec2 resolution)|setRenderResolution]]([[Vec2]] resolution)&lt;br /&gt;
|set Render resolution.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setMaxFrameRate(int maxFrameRate)|setMaxFrameRate]](int maxFrameRate)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:skipRenderFrame()|skipRenderFrame]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setCursor(string cursorFilePath)|setCursor]]([[string]] cursorFilePath)&lt;br /&gt;
|Set the cursor icon. NOTE! must be a *.bmp file.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSounMasterGain(float gain)|setSounMasterGain]](float gain)&lt;br /&gt;
|set sound master gain, gain is between [0,1]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSoundMusicGain(float gain)|setSoundMusicGain]](float gain)&lt;br /&gt;
|set music gain, gain is between [0,1]&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Core:setSounEffectGain(float gain)|setSounEffectGain]](float gain)&lt;br /&gt;
|set effect gain, gain is between [0,1]&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getSounMasterGain()|getSounMasterGain]]()&lt;br /&gt;
|get sound master gain&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getSounMusicGain()|getSounMusicGain]]()&lt;br /&gt;
|get sound master gain&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Core:getSounEffectGain()|getSounEffectGain]]()&lt;br /&gt;
|get sound master gain&lt;br /&gt;
|-&lt;br /&gt;
|[[Panel]]&lt;br /&gt;
|[[Core:getPanelWithMouseFocus()|getPanelWithMouseFocus]]()&lt;br /&gt;
|get panel with mouse focus.&lt;br /&gt;
|-&lt;br /&gt;
|[[Panel]]&lt;br /&gt;
|[[Core:getPanelWithKeyboardFocus()|getPanelWithKeyboardFocus]]()&lt;br /&gt;
|get panel with mouse focus.&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Core:getMachineId()|getMachineId]]()&lt;br /&gt;
|get the machine ID.&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=Label&amp;diff=163</id>
		<title>Label</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=Label&amp;diff=163"/>
		<updated>2025-07-26T12:08:07Z</updated>

		<summary type="html">&lt;p&gt;Anders: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:LabelExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Inheritance==&lt;br /&gt;
[[Panel]]&lt;br /&gt;
&lt;br /&gt;
==Constructor==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|Label([[PanelSize]] size, [[string]] text)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Label([[PanelSize]] size, [[string]] text, [[Vec3]] textColor)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Label([[PanelSize]] size, [[string]] text, [[Vec4]] textColor)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Label([[PanelSize]] size, [[string]] text, [[Alignment]] align)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Label([[PanelSize]] size, [[string]] text, [[Vec3]] textColor, [[Alignment]] align)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Label([[PanelSize]] size, [[string]] text, [[Vec4]] textColor, [[Alignment]] align)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Label([[PanelSize]] size, [[Text]] text)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Label([[PanelSize]] size, [[Text]] text, [[Vec3]] textColor)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Label([[PanelSize]] size, [[Text]] text, [[Vec4]] textColor)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Label([[PanelSize]] size, [[Text]] text, [[Vec4]] textColor [[Alignment]] align)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Label([[PanelSize]] size, [[Text]] text, [[Vec3]] textColor [[Alignment]] align)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|[[Text]]&lt;br /&gt;
|[[Label:getText()|getText]]()&lt;br /&gt;
|Get text.&lt;br /&gt;
|-&lt;br /&gt;
|Vec4&lt;br /&gt;
|[[Label:getTextColor()|getTextColor]]()&lt;br /&gt;
|Get text.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Label:getTextHeight()|getTextHeight]]()&lt;br /&gt;
|Get text.&lt;br /&gt;
|-&lt;br /&gt;
|[[Alignment]]&lt;br /&gt;
|[[Label:getAlignment()|getAlignment]]()&lt;br /&gt;
|Get text.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2]]&lt;br /&gt;
|[[Label:getTextSizeInPixel()|getTextSizeInPixel]]()&lt;br /&gt;
|Get the recomended size based on current text and text height.&lt;br /&gt;
Return the size in pixel.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Label:setText(string text)|setText]]([[string]] text)&lt;br /&gt;
|Set text.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Label:setText(Text text)|setText]]([[Text]] text)&lt;br /&gt;
|Set text.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Label:setTextHeight(float height)|setTextHeight]](float height)&lt;br /&gt;
|Set text height. if value larger larger then 1.0 height represent height in pixel, bellow 1.0 height represent percent of screen height.&lt;br /&gt;
Example 0.1 is 10% of screen resolution and 10 means the text is 10px high.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Label:setTextAlignment(Alignment align)|setTextAlignment]]([[Alignment]] align)&lt;br /&gt;
|Set alignment.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Label:setTextColor(Vec3 color)|setTextColor]]([[Vec3]] color)&lt;br /&gt;
|Set text color.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Label:setTextColor(Vec4 color)|setTextColor]]([[Vec4]] color)&lt;br /&gt;
|Set text color.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Label:setPanelSizeBasedOnTextSize()|setPanelSizeBasedOnTextSize]]()&lt;br /&gt;
|PanelSize will be based on the text.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Label:setParseTags(bool parseTags)|setParseTags]](bool parseTags)&lt;br /&gt;
|Set text color.&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=Label&amp;diff=162</id>
		<title>Label</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=Label&amp;diff=162"/>
		<updated>2025-07-26T12:05:57Z</updated>

		<summary type="html">&lt;p&gt;Anders: /* Functions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:LabelExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Inheritance==&lt;br /&gt;
[[Panel]]&lt;br /&gt;
&lt;br /&gt;
==Constructor==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|Label([[PanelSize]] size, [[string]] text)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Label([[PanelSize]] size, [[string]] text, [[Vec3]] textColor)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Label([[PanelSize]] size, [[string]] text, [[Vec4]] textColor)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Label([[PanelSize]] size, [[string]] text, [[Alignment]] align)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Label([[PanelSize]] size, [[string]] text, [[Vec3]] textColor, [[Alignment]] align)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Label([[PanelSize]] size, [[string]] text, [[Vec4]] textColor, [[Alignment]] align)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Label([[PanelSize]] size, [[Text]] text)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Label([[PanelSize]] size, [[Text]] text, [[Vec3]] textColor)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Label([[PanelSize]] size, [[Text]] text, [[Vec4]] textColor)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Label([[PanelSize]] size, [[Text]] text, [[Vec4]] textColor [[Alignment]] align)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|Label([[PanelSize]] size, [[Text]] text, [[Vec3]] textColor [[Alignment]] align)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Label:getText()|getText]]()&lt;br /&gt;
|Get text as a string.&lt;br /&gt;
|-&lt;br /&gt;
|Vec4&lt;br /&gt;
|[[Label:getTextColor()|getTextColor]]()&lt;br /&gt;
|Get text.&lt;br /&gt;
|-&lt;br /&gt;
|float&lt;br /&gt;
|[[Label:getTextHeight()|getTextHeight]]()&lt;br /&gt;
|Get text.&lt;br /&gt;
|-&lt;br /&gt;
|[[Alignment]]&lt;br /&gt;
|[[Label:getAlignment()|getAlignment]]()&lt;br /&gt;
|Get text.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec2]]&lt;br /&gt;
|[[Label:getTextSizeInPixel()|getTextSizeInPixel]]()&lt;br /&gt;
|Get the recomended size based on current text and text height.&lt;br /&gt;
Return the size in pixel.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Label:setText(string text)|setText]]([[string]] text)&lt;br /&gt;
|Set text.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Label:setText(Text text)|setText]]([[Text]] text)&lt;br /&gt;
|Set text.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Label:setTextHeight(float height)|setTextHeight]](float height)&lt;br /&gt;
|Set text height. if value larger larger then 1.0 height represent height in pixel, bellow 1.0 height represent percent of screen height.&lt;br /&gt;
Example 0.1 is 10% of screen resolution and 10 means the text is 10px high.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Label:setTextAlignment(Alignment align)|setTextAlignment]]([[Alignment]] align)&lt;br /&gt;
|Set alignment.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Label:setTextColor(Vec3 color)|setTextColor]]([[Vec3]] color)&lt;br /&gt;
|Set text color.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Label:setTextColor(Vec4 color)|setTextColor]]([[Vec4]] color)&lt;br /&gt;
|Set text color.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Label:setPanelSizeBasedOnTextSize()|setPanelSizeBasedOnTextSize]]()&lt;br /&gt;
|PanelSize will be based on the text.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Label:setParseTags(bool parseTags)|setParseTags]](bool parseTags)&lt;br /&gt;
|Set text color.&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=Config&amp;diff=161</id>
		<title>Config</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=Config&amp;diff=161"/>
		<updated>2025-07-26T08:04:34Z</updated>

		<summary type="html">&lt;p&gt;Anders: /* Functions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:ConfigExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Constructor==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|Config([[string]] configName)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Config:save()|save]]()&lt;br /&gt;
|saves the config to file&lt;br /&gt;
|-&lt;br /&gt;
|[[ConfigItem]]&lt;br /&gt;
|[[Config:get(string name)|get]]([[string]] name)&lt;br /&gt;
|returns a configItem&lt;br /&gt;
|-&lt;br /&gt;
|[[ConfigItem]]&lt;br /&gt;
|[[Config:get(string name, bool val)|get]]([[string]] name,bool val)&lt;br /&gt;
|returns a configItem. if item do not exist set default value to val&lt;br /&gt;
|-&lt;br /&gt;
|[[ConfigItem]]&lt;br /&gt;
|[[Config:get(string name, double val)|get]]([[string]] name,double val)&lt;br /&gt;
|returns a configItem. if item do not exist set default value to val&lt;br /&gt;
|-&lt;br /&gt;
|[[ConfigItem]]&lt;br /&gt;
|[[Config:get(string name, string val)|get]]([[string]] name,string val)&lt;br /&gt;
|returns a configItem. if item do not exist set default value to val&lt;br /&gt;
|-&lt;br /&gt;
|[[ConfigItem]]&lt;br /&gt;
|[[Config:get(string name, Vec2 val)|get]]([[string]] name,Vec2 val)&lt;br /&gt;
|returns a configItem. if item do not exist set default value to val&lt;br /&gt;
|-&lt;br /&gt;
|[[ConfigItem]]&lt;br /&gt;
|[[Config:get(string name, Vec3 val)|get]]([[string]] name,Vec3 val)&lt;br /&gt;
|returns a configItem. if item do not exist set default value to val&lt;br /&gt;
|-&lt;br /&gt;
|[[ConfigItem]]&lt;br /&gt;
|[[Config:get(string name, Vec4 val)|get]]([[string]] name,Vec4 val)&lt;br /&gt;
|returns a configItem. if item do not exist set default value to val&lt;br /&gt;
|-&lt;br /&gt;
|Table&lt;br /&gt;
|[[Config:getTable()|getTable]]()&lt;br /&gt;
|returns a complete table with all the children and there values. it will return an empty table if isData()==true.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Config:renameChild(string oldName,string newName)|renameChild]](string oldName,string newName)&lt;br /&gt;
|renames the item with the exakt name.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[Config:remove(string name)|remove]](string name)&lt;br /&gt;
|removes the item with the exakt name.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Config:isData()|isData]]()&lt;br /&gt;
|returns false. because the first layer must be a table.&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Config:exist(string name)|exist]](string name)&lt;br /&gt;
|returns true if there is a child with that exakt name.&lt;br /&gt;
|-&lt;br /&gt;
|[[ConfigItem]]&lt;br /&gt;
|[[Config:getFirst()|getFirst]]()&lt;br /&gt;
|returns first element of its table&lt;br /&gt;
|-&lt;br /&gt;
|[[ConfigItem]]&lt;br /&gt;
|[[Config:getNext()|getNext]]()&lt;br /&gt;
|returns next element in the table&lt;br /&gt;
|-&lt;br /&gt;
|string&lt;br /&gt;
|[[Config:getCurrentName()|getCurrentName]]()&lt;br /&gt;
|returns the name of the active element in the table&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[Config:isEnd()|isEnd]]()&lt;br /&gt;
|returns true if this is the last element in queue&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=MouseKey&amp;diff=160</id>
		<title>MouseKey</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=MouseKey&amp;diff=160"/>
		<updated>2025-07-06T08:03:46Z</updated>

		<summary type="html">&lt;p&gt;Anders: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:MouseKeyExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Enum==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|Name&lt;br /&gt;
!|Value&lt;br /&gt;
!|Description&lt;br /&gt;
|-&lt;br /&gt;
|left&lt;br /&gt;
|1&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|right&lt;br /&gt;
|3&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|middle&lt;br /&gt;
|2&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|x1&lt;br /&gt;
|4&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|x2&lt;br /&gt;
|5&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=PlayMode&amp;diff=159</id>
		<title>PlayMode</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=PlayMode&amp;diff=159"/>
		<updated>2025-07-06T08:03:28Z</updated>

		<summary type="html">&lt;p&gt;Anders: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:PlayModeExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Enum==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|Name&lt;br /&gt;
!|Value&lt;br /&gt;
!|Description&lt;br /&gt;
|-&lt;br /&gt;
|stopAll&lt;br /&gt;
|0&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|stopSameLayer&lt;br /&gt;
|1&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=QueuedMode&amp;diff=158</id>
		<title>QueuedMode</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=QueuedMode&amp;diff=158"/>
		<updated>2025-07-06T08:03:09Z</updated>

		<summary type="html">&lt;p&gt;Anders: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:QueuedModeExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Enum==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|Name&lt;br /&gt;
!|Value&lt;br /&gt;
!|Description&lt;br /&gt;
|-&lt;br /&gt;
|completeOther&lt;br /&gt;
|0&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|completeSameLayer&lt;br /&gt;
|1&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=WrapMode&amp;diff=157</id>
		<title>WrapMode</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=WrapMode&amp;diff=157"/>
		<updated>2025-07-06T08:02:32Z</updated>

		<summary type="html">&lt;p&gt;Anders: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:WrapModeExampleCode}}&lt;br /&gt;
&lt;br /&gt;
==Enum==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|Name&lt;br /&gt;
!|Value&lt;br /&gt;
!|Description&lt;br /&gt;
|-&lt;br /&gt;
|once&lt;br /&gt;
|0&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|loop&lt;br /&gt;
|1&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|clamp&lt;br /&gt;
|2&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
</feed>