New pages

From Crumbled World Wiki
New pages
Hide registered users | Hide bots | Show redirects
(newest | oldest) View (newer 50 | ) (20 | 50 | 100 | 250 | 500)
  • 07:29, 5 August 2025Statistics (hist | edit) ‎[1,190 bytes]Anders (talk | contribs) (Created page with "{{:StatisticsExampleCode}} ==Constructor== {| class="wikitable" !|function !|description |- |Statistics() | |- |} ==Functions== {| class="wikitable" !|return !|function !|description |- | |addScriptGroup(string groupName, string scriptNames) |scriptNames are seperated by ';' example skeleton.lua;rat.lua |- | |update() |Calculate previous frame statistics |- |float |Statistics:...")
  • 08:01, 6 July 2025ListenerExampleCode (hist | edit) ‎[634 bytes]Anders (talk | contribs) (Created page with "==Example Code== Script 1 <syntaxhighlight lang="lua"> function create() --Register listener group eventHandler = Listener("groupName") end function update() eventHandler:pushEvent("update") return true end </syntaxhighlight> Script 2 listener <syntaxhighlight lang="lua"> function create() --Register listener group eventListener = Listener("groupName") --listen on update event, call the function eventUpdate when event happens. eve...")
  • 07:59, 6 July 2025ComboBoxExampleCode (hist | edit) ‎[425 bytes]Anders (talk | contribs) (Created page with "==Example== <syntaxhighlight lang="lua"> function changeSetting(button) comboBox:setText(button:getTag()) end comboBox = panel:add(ComboBox(PanelSize(size), items[1])) local items = {"item1","item2","item3","item4"} for i=1, #items do local itemButton = comboBox:addItem( Button(PanelSize(Vec2(-1,0.03)), items[i]) ) itemButton:setTag(items[i]) itemButton:addEventCallbackExecute(changeSetting) end </syntaxhighlight>")
  • 07:58, 6 July 2025FallLayoutExampleCode (hist | edit) ‎[175 bytes]Anders (talk | contribs) (Created page with "==Example== <syntaxhighlight lang="lua"> local panel = form:add(Panel(PanelSize(Vec2(-1)))) --Set a FallLayout to the panel. panel:setLayout(FallLayout()) </syntaxhighlight>")
  • 07:58, 6 July 2025FlowLayoutExampleCode (hist | edit) ‎[253 bytes]Anders (talk | contribs) (Created page with "==Example== <syntaxhighlight lang="lua"> local panel = form:add(Panel(PanelSize(Vec2(-1)))) --Set a FlowLayout to the panel. Note that doing this i meaningless because FlowLayout is the default layout. panel:setLayout(FlowLayout()) </syntaxhighlight>")
  • 07:58, 6 July 2025FormExampleCode (hist | edit) ‎[870 bytes]Anders (talk | contribs) (Created page with "==Example Code== <syntaxhighlight lang="lua"> --this = SceneNode() function destroy() --clear form form:destroy() end function create() --Get the camera wich the form will be renderd to. local camera = this:getRootNode():findNodeByName("MainCamera") --Check if the camera exist. if camera then --create a form window of size 20% screen width and 20% screen height. form = Form(camera, PanelSize(Vec2(0.2,0.2))) --Set layout default is FlowLayout. form:setLayo...")
  • 07:57, 6 July 2025GradientExampleCode (hist | edit) ‎[235 bytes]Anders (talk | contribs) (Created page with "==Example== <syntaxhighlight lang="lua"> local panel = form:add(Panel(PanelSize(Vec2(-1)))) --create a background, white in the top and black at the bottom of the panel panel:setBackground(Gradient(Vec3(1),Vec3())) </syntaxhighlight>")
  • 07:57, 6 July 2025GridLayoutExampleCode (hist | edit) ‎[235 bytes]Anders (talk | contribs) (Created page with "==Example== <syntaxhighlight lang="lua"> local panel = form:add(Panel(PanelSize(Vec2(-1)))) --Set a gidlayout with 2 rows and 4 columns. Only the 8 panels can be added to the panel. panel:setLayout(GridLayout(2,4)) </syntaxhighlight>")
  • 07:57, 6 July 2025ImageExampleCode (hist | edit) ‎[315 bytes]Anders (talk | contribs) (Created page with "==Example== <syntaxhighlight lang="lua"> --add an image to panel with fill and the images width and height need to of equal length. local image = panel:add(Image(PanelSize(Vec2(-1),Vec2(1)), "LoadingScreen\loadingScreen1")) --set image uvcoord image:setUvCoord(Vec2(0.25,0.25),Vec2(0.75,0.75)) </syntaxhighlight>")
  • 07:56, 6 July 2025Node2DMeshExampleCode (hist | edit) ‎[656 bytes]Anders (talk | contribs) (Created page with "==Example== <syntaxhighlight lang="lua"> local renderMesh = Node2DMesh() --add node2DMesh to a panel to be renderd panel:addRenderObject(renderMesh) --clear mesh renderMesh:clearMesh() local minPos = Vec2(0,0) local maxPos = Vec2(100,100) local color = Vec4(1,1,1,1) --add a quad renderMesh:addVertex(Vec2(minPos.x, minPos.y), color) renderMesh:addVertex(Vec2(maxPos.x, minPos.y), color) renderMesh:addVertex(Vec2(maxPos.x, maxPos.y), color) renderMesh:addVertex(Vec...")
  • 07:55, 6 July 2025Vec4ExampleCode (hist | edit) ‎[291 bytes]Anders (talk | contribs) (Created page with "==Example Code== <syntaxhighlight lang="lua"> local a = Vec4(6, 8, 0, 0) local b = a + Vec4(-2,-2, 1, 0) * 2 print(b.x..", "..b.y..", "..b.z..", "..b.w) --print 2.0, 4.0, 2.0, 0.0 a:normalize() print(a.x..", "..a.y..", "..a.z..", "..b.w) --print 0.6, 0.8, 0.0, 0.0 </syntaxhighlight>")
  • 07:54, 6 July 2025Vec3ExampleCode (hist | edit) ‎[273 bytes]Anders (talk | contribs) (Created page with "==Example Code== <syntaxhighlight lang="lua"> local a = Vec3(6,8,0) local b = a + Vec3(-2,-2, 1) * 2 print("Vec3(" . .b.x .. ", " .. b.y .. ", " .. b.z .. ")") --print Vec3(2.0, 4.0, 2.0) a:normalize() print(tostring(a)) --print Vec3(0.6, 0.8, 0.0) </syntaxhighlight>")
  • 07:54, 6 July 2025Vec2iExampleCode (hist | edit) ‎[158 bytes]Anders (talk | contribs) (Created page with "==Example Code== <syntaxhighlight lang="lua"> local a = Vec2(6,8) local b = a + Vec2i(-2,-2) * 2 print(b.x .. ", " .. b.y) --print 2, 4 </syntaxhighlight>")
  • 07:52, 6 July 2025Vec2ExampleCode (hist | edit) ‎[126 bytes]Anders (talk | contribs) (Created page with "==Example== <syntaxhighlight lang="lua"> local vec = Vec2(2,9.2) local anotherVec = vec + (Vec2(-2,-2) * 2) </syntaxhighlight>")
  • 07:49, 6 July 2025CameraExampleCode (hist | edit) ‎[1,244 bytes]Anders (talk | contribs) (Created page with "==Example Code== <syntaxhighlight lang="lua"> --this = Camera() function create() keyBinds = Core.getBillboard("keyBind"); keyBindForward = keyBinds:getKeyBind("forward"); keyBindBackward = keyBinds:getKeyBind("backward"); keyBindLeft = keyBinds:getKeyBind("left"); keyBindRight = keyBinds:getKeyBind("right"); end function update() local deltaTime = Core.getDeltaTime() local localMat = this:getLocalMatrix() if keyBindForward:getHeld() then localMat:setPos...")
  • 14:27, 5 July 2025WrapMode (hist | edit) ‎[133 bytes]Anders (talk | contribs) (Created page with "{{:WrapModeExampleCode}} __NOAUTOLINKS__ ==Enum== {| class="wikitable" !|Name !|Value !|Description |- |once |0 | |- |loop |1 | |- |clamp |2 | |- |}")
  • 14:27, 5 July 2025Worker (hist | edit) ‎[1,333 bytes]Anders (talk | contribs) (Created page with "{{:SceneNodeExampleCode}} ==Constructor== {| class="wikitable" !|function !|description |- |Worker(string luaFilePath) |Create a worker thread and load the luascript thread is destroyed when create or update function returns false. |- |Worker(string luaFilePath, bool cycleWork) |Create a worker thread and load the luascript thread is destroyed when create or update function returns false. If cycleWork is false the thread will run as fast as the cpu and other th...")
  • 14:27, 5 July 2025Work (hist | edit) ‎[659 bytes]Anders (talk | contribs) (Created page with "{{:WorkExampleCode}} ==Functions== {| class="wikitable" !|return !|function !|description |- |string |getName() |Get work name. |- |int |getWeight() |Get work weight. |- | |addDependency(Work dependency) |This work can not be excecuted befor the dependency is done. |- | |removeDependency(Work dependency) |Remove a dependency. |- | |Work:setName(st...")
  • 14:27, 5 July 2025VertexType (hist | edit) ‎[428 bytes]Anders (talk | contribs) (Created page with "{{:VertexTypeExampleCode}} ==Enum== {| class="wikitable" !|Name !|Value !|Description |- |position3 |0 |Is of type Vec3. |- |position4 |1 |Is of type Vec4. |- |normal |2 |Is of type Vec3. |- |uvcoord |3 |Is of type Vec2. |- |tangent |4 |Is of type Vec3. |- |color3 |5 |Is of type Vec3. |- |color4 |6 |Is of type Vec4. |- |boneId |7 |Is of type Vec3. |- |boneWeight |8 |Is of type Vec3. |- |}")
  • 14:27, 5 July 2025Text (hist | edit) ‎[583 bytes]Anders (talk | contribs) (Created page with "{{:LabelExampleCode}} ==Constructor== {| class="wikitable" !|function !|description |- |Text() | |- |Text(string text) | |- |Text(Text text) | |- |} ==Functions== {| class="wikitable" !|return !|function !|description |- |string |toString() |Get string. |- |int |length() |Get text length. |- |Vec2 |getTextScale() |Get text scale. |- |Vec2 |Text:getTextScale(bool parseText)|getTextScal...")
  • 14:26, 5 July 2025Texture (hist | edit) ‎[261 bytes]Anders (talk | contribs) (Created page with "{{:TextureExampleCode}} ==Functions== {| class="wikitable" !|return !|function !|description |- |Text |getName() |Returns the name of the texture. |- |Vec2 |getSize() |Returns texture width and height. |- |}")
  • 14:26, 5 July 2025Stopwatch (hist | edit) ‎[517 bytes]Anders (talk | contribs) (Created page with "{{:StopwatchExampleCode}} ==Constructor== {| class="wikitable" !|function !|description |- |Stopwatch() | |- |} ==Functions== {| class="wikitable" !|return !|function !|description |- | |start() |reset and start watch. |- |float |stop() |Stop watch and return total run time. |- |float |lapTime() |return current time sence start. |- |float |totalRunningTime() |return tie se...")
  • 14:26, 5 July 2025SoundType (hist | edit) ‎[273 bytes]Anders (talk | contribs) (Created page with "{{:SoundTypeExampleCode}} ==Enum== {| class="wikitable" !|Name !|Value !|Description |- |STEREO |0 |Sound is always played at the same sound level and can support stereo sound. |- |EFFECT |1 |Sound that should be played in 3D space sound is always converted to mono. |- |}")
  • 14:26, 5 July 2025Sound (hist | edit) ‎[768 bytes]Anders (talk | contribs) (Created page with "{{:SoundExampleCode}} ==Constructor== {| class="wikitable" !|function !|description |- |Sound(string fileName, SoundType type) | |- |} ==Functions== {| class="wikitable" !|return !|function !|description |- |String |getName() |Get sound file name. |- |bool |successFullyLoaded() |Get if the sound was successfully loaded. |- |SoundSource |playSound(float so...")
  • 14:26, 5 July 2025Shader (hist | edit) ‎[572 bytes]Anders (talk | contribs) (Created page with "{{:ShaderExampleCode}} ==Functions== {| class="wikitable" !|return !|function !|description |- |string |getName() |Get shader name. |- |string |getFullName() |Get shader name and the including defintions. This name can be used to load the shader from Core.getShader(). |- |{string} |getDefinitions() |Get all shader definitions |- | |Shader:bindTextureLocation(string textureName, int glId)|bindTe...")
  • 14:26, 5 July 2025ServerTester (hist | edit) ‎[798 bytes]Anders (talk | contribs) (Created page with "{{:ServerTesterExampleCode}} ==Constructor== {| class="wikitable" !|function !|description |- |ServerTester() | |- |} ==Functions== {| class="wikitable" !|return !|function !|description |- | |parseServerTable(object table) |Parses a server table recived from the internet. |- |bool |hasNewServerInfo() |Returns true if a new server has been confirmed |- |table |ServerTester:popNewServe...")
  • 14:25, 5 July 2025Server (hist | edit) ‎[978 bytes]Anders (talk | contribs) (Created page with "{{:ServerExampleCode}} ==Functions== {| class="wikitable" !|return !|function !|description |- | |enableNewConnections(bool set) |Enables or disable new clients to connect to server, new clients may only connect if server is running |- | |start() |Starts the server. The server it self may run on another machine or localy in a seperat thread |- | |stop() |Stops the server and kicks all connect...")
  • 14:25, 5 July 2025RenderMode (hist | edit) ‎[265 bytes]Anders (talk | contribs) (Created page with "{{:RenderModeExampleCode}} ==Enum== {| class="wikitable" !|Name !|Value !|Description |- |points | | |- |lines | | |- |lineStrip | | |- |lineLoop | | |- |triangles | | |- |triangleStrip | | |- |trinagleFan | | |- |quads | | |- |quadStrip | | |- |polygon | | |- |}")
  • 14:25, 5 July 2025QueuedMode (hist | edit) ‎[142 bytes]Anders (talk | contribs) (Created page with "{{:QueuedModeExampleCode}} __NOAUTOLINKS__ ==Enum== {| class="wikitable" !|Name !|Value !|Description |- |completeOther |0 | |- |completeSameLayer |1 | |- |}")
  • 14:25, 5 July 2025PlayMode (hist | edit) ‎[130 bytes]Anders (talk | contribs) (Created page with "{{:PlayModeExampleCode}} __NOAUTOLINKS__ ==Enum== {| class="wikitable" !|Name !|Value !|Description |- |stopAll |0 | |- |stopSameLayer |1 | |- |}")
  • 14:25, 5 July 2025BoundType (hist | edit) ‎[134 bytes]Anders (talk | contribs) (Created page with "{{:BoundTypeExampleCode}} ==Enum== {| class="wikitable" !|Name !|Value !|Description |- |None |1 | |- |Sphere |2 | |- |Box |3 | |- |}")
  • 14:24, 5 July 2025NodeId (hist | edit) ‎[730 bytes]Anders (talk | contribs) (Created page with "{{:NodeIdExampleCode}} ==Enum== {| class="wikitable" !|Name !|Value !|Description |- |sceneNode |0 | |- |renderNode |1 | |- |camera |2 | |- |nodeMesh |5 | |- |light |7 | |- |fileNode |9 | |- |playerNode |10 | |- |particleSystem |13 | |- |island |21 | |- |islandEdge |23 | |- |islandMesh |24 | |- |navMesh |25 | |- |model |26 | |- |mesh |27 | |- |animatedMesh |28 | |- |ambientLight |41 | |- |directionalLight |42 | |- |pointLight |43 | |- |soulManager |38 | |- |buildNode |5...")
  • 14:24, 5 July 2025MouseKey (hist | edit) ‎[159 bytes]Anders (talk | contribs) (Created page with "{{:MouseKeyExampleCode}} __NOAUTOLINKS__ ==Enum== {| class="wikitable" !|Name !|Value !|Description |- |left |1 | |- |right |3 | |- |middle |2 | |- |x1 |4 | |- |x2 |5 | |- |}")
  • 14:24, 5 July 2025LuaWrapper (hist | edit) ‎[26 bytes]Anders (talk | contribs) (Created page with "{{:LuaWrapperExampleCode}}")
  • 14:24, 5 July 2025LuaComMsgType (hist | edit) ‎[144 bytes]Anders (talk | contribs) (Created page with "{{:LuaComMsgTypeExampleCode}} __NOAUTOLINKS__ ==Enum== {| class="wikitable" !|Name !|Value !|Description |- |none |0 | |- |broadcast |1 | |- |direct |2 | |- |}")
  • 14:24, 5 July 2025LuaScript (hist | edit) ‎[1,319 bytes]Anders (talk | contribs) (Created page with "{{:LuaScriptExampleCode}} ==Functions== {| class="wikitable" !|return !|function !|description |- |string |getName() |Get work name. |- |string |getNetworkName() |Get unique network name. |- |int |getIndex() |Get Lua index, the index is unique. |- |string |getFileName() |Get the file name of the script. folder Path is not included. |- |Billboard |...")
  • 14:23, 5 July 2025String (hist | edit) ‎[1,772 bytes]Anders (talk | contribs) (Created page with "{{:LuaStringExampleCode}} ==Class name== {| class="wikitable" !|string |- |} ==Functions== {| class="wikitable" !|return !|function !|description |- |string |format( nil a ) | |- |string |format( nil a, nil b ) | |- |string |format( nil a, nil b, nil c ) | |- |string |format( nil a, nil b, nil c, nil d ) | |-...")
  • 14:23, 5 July 2025Listener (hist | edit) ‎[592 bytes]Anders (talk | contribs) (Created page with "{{:ListenerExampleCode}} ==Constructor== {| class="wikitable" !|function !|description |- |Listener(string groupName) | |- |} ==Functions== {| class="wikitable" !|return !|function !|description |- | |registerEvent(string eventName, nil function) | |- | |unregisetEvent(string eventName) | |- | |pushEvent(string eventName) | |...")
  • 14:23, 5 July 2025LightType (hist | edit) ‎[143 bytes]Anders (talk | contribs) (Created page with "{{:LightTypeExampleCode}} ==Enum== {| class="wikitable" !|Name !|Value !|Description |- |point |0 | |- |direction |1 | |- |ambient |3 | |- |}")
  • 14:23, 5 July 2025Language (hist | edit) ‎[1,578 bytes]Anders (talk | contribs) (Created page with "{{:LanguageExampleCode}} ==Constructor== {| class="wikitable" !|function !|description |- |Language() | |- |} ==Functions== {| class="wikitable" !|return !|function !|description |- |Text |getText(string name) | |- |Text |getText(Text name) | |- |Text |getText(string name, string language) | |- |Text |Language:getText(string name, s...")
  • 14:23, 5 July 2025KeyBind (hist | edit) ‎[2,813 bytes]Anders (talk | contribs) (Created page with "{{:KeyBindExampleCode}} ==Constructor== {| class="wikitable" !|function !|description |- |KeyBind() | |- |KeyBind(string groupName, string subGroupName, string keyName) | |- |} ==Functions== {| class="wikitable" !|return !|function !|description |- |int |getNumKeyBinds() |Get number of different keybinds. |- |string |getKeyBindName(int id) |Retun the text of the key bind. example "Left Ctrl + A" |- |string...")
  • 14:23, 5 July 2025Key (hist | edit) ‎[2,656 bytes]Anders (talk | contribs) (Created page with "{{:KeyExampleCode}} ==Enum== {| class="wikitable" !|Name |- |k0 |- |k1 |- |k2 |- |k3 |- |k4 |- |k5 |- |k6 |- |k7 |- |k8 |- |k9 |- |a |- |b |- |c |- |d |- |e |- |f |- |g |- |h |- |i |- |j |- |k |- |l |- |m |- |n |- |o |- |p |- |q |- |r |- |s |- |t |- |u |- |v |- |x |- |y |- |z |- |w |- |enter |- |escape |- |backSpace |- |tab |- |space |- |exclaim |- |Quotedbl |- |hash |- |percent |- |dollar |- |ampersand |- |quote |- |leftParen |- |rightParen |- |plus |- |comma |- |plus...")
  • 14:22, 5 July 2025Input (hist | edit) ‎[1,608 bytes]Anders (talk | contribs) (Created page with "{{:InputExampleCode}} ==Functions== {| class="wikitable" !|return !|function !|description |- |bool |getKeyDown(Key key) |return true if the key has been pressed down |- |bool |getKeyHeld(Key key) |return true if the key has been pressed down but not yet released. |- |bool |getKeyPressed(Key key) |return true if the key has been released. |- |bool |Input:getMouseDo...")
  • 14:22, 5 July 2025Global (hist | edit) ‎[5,340 bytes]Anders (talk | contribs) (Created page with "{{:GlobalExampleCode}} ==Global members== {| class="wikitable" !|type !|variable !|description |- |float |PI |3.14159265359 |- |int |LUA_INDEX | |- |LuaWrapper |LUA | |- |} ==Global functions== {| class="wikitable" !|return !|function !|description |- | |require(string path) |Include another lua file. This is equal to just past in the file on this row. |- | |setRestoreData(nil data) |Set r...")
  • 14:22, 5 July 2025FontCharacter (hist | edit) ‎[702 bytes]Anders (talk | contribs) (Created page with "{{:FontCharacterExampleCode}} ==Functions== {| class="wikitable" !|return !|function !|description |- |Vec2 |getOffsetToNextChar() |Distance to the next character including character spacing. |- |Vec2 |getLocalOffset() |Offset when of render position to render correctly example, "agh". This character has all defferent start location. |- |Vec2 |getSize() |C...")
  • 14:22, 5 July 2025File (hist | edit) ‎[1,352 bytes]Anders (talk | contribs) (Created page with "{{:FileExampleCode}} ==Constructor== {| class="wikitable" !|function !|description |- |File(string filePath) |Load a file. |- |File(string fileNodePath, string filePath) |Load a file located in a map. load the file from the map with the name filePath. |- |} ==Functions== {| class="wikitable" !|return !|function !|description |- |string |getName() |Returns the file name. |- |string |getPath() |Returns the file path. |-...")
  • 14:22, 5 July 2025Cursor (hist | edit) ‎[476 bytes]Anders (talk | contribs) (Created page with "{{:CursorExampleCode}} ==Functions== {| class="wikitable" !|return !|function !|description |- | |setVisible(bool visible) |Set if the cursor should be visible. |- | |setRelativeMouseMode(bool mode) |If mode is true the mouse cursor is set to invisible and the relative mouse motion is sent. |- | |warpMousePosition(Vec2 pos) |Set mouse position. |- |}")
  • 14:21, 5 July 2025Core (hist | edit) ‎[11,109 bytes]Anders (talk | contribs) (Created page with "{{:CoreExampleCode}} ==Static functions== {| class="wikitable" !|return !|function !|description |- | |setUpdateHz(float hz) |Sets the update frequency of the script based on in game time. minimum hz that can be set is >0.1 below that it will update every frame |- | |setUpdateHzRealTime(float hz) |Sets the update frequency of the script based on real time. minimum hz that can be set is >0.1 below that...")
  • 14:21, 5 July 2025Client (hist | edit) ‎[3,366 bytes]Anders (talk | contribs) (Created page with "{{:ClientExampleCode}} ==Functions== {| class="wikitable" !|return !|function !|description |- |bool |isConnected() |returns true if connected to a server |- |bool |isLosingConnection() |returns true if no new messages has been received for the pas 2.5s. |- |bool |isAdmin() |returns true if admin of the server |- | |connect(string address) |Tries to connect t...")
  • 14:21, 5 July 2025ConfigItem (hist | edit) ‎[4,349 bytes]Anders (talk | contribs) (Created page with "{{:ConfigItemExampleCode}} ==Constructor== {| class="wikitable" !|function !|description |- |ConfigItem(string fileName) |opens that specific config files using a singleton. |- |} ==Functions== {| class="wikitable" !|return !|function !|description |- | |set(nil) |Can set any value of type number,string,boolean,Vec2,Vec3,Vec4,Matrix,table |- | |setBool(bool val) |sets the boolean, int, float and double value. |-...")
(newest | oldest) View (newer 50 | ) (20 | 50 | 100 | 250 | 500)