diff options
| author | jussi | 2022-07-26 16:33:04 +0300 |
|---|---|---|
| committer | jussi | 2022-07-26 16:33:04 +0300 |
| commit | 4f54a0a4992358c633e5e3535e2980211028f3a2 (patch) | |
| tree | 05a52f180c6e200b90811d2ec7baef7a7c2c13a8 /examples | |
| parent | 314d0412a53b8e012ec183c503a69cc32e24ab34 (diff) | |
| download | reilua-enhanced-4f54a0a4992358c633e5e3535e2980211028f3a2.tar.gz reilua-enhanced-4f54a0a4992358c633e5e3535e2980211028f3a2.tar.bz2 reilua-enhanced-4f54a0a4992358c633e5e3535e2980211028f3a2.zip | |
Create material using correct texture source.
Diffstat (limited to 'examples')
| -rw-r--r-- | examples/2D_camera/main.lua | 2 | ||||
| -rw-r--r-- | examples/image_draw/main.lua | 2 | ||||
| -rw-r--r-- | examples/platformer/main.lua | 5 |
3 files changed, 7 insertions, 2 deletions
diff --git a/examples/2D_camera/main.lua b/examples/2D_camera/main.lua index 54d3ec6..55c3b5a 100644 --- a/examples/2D_camera/main.lua +++ b/examples/2D_camera/main.lua @@ -36,7 +36,7 @@ function process( delta ) cameraPos[2] = cameraPos[2] - cameraSpeed * delta end -- Rotate. - if RL_IsKeyDown( string.byte( "E" ) ) then + if RL_IsKeyDown( string.byte( "E" ) ) then -- Or RL_IsKeyDown( KEY_E ) cameraRot = cameraRot + cameraRotSpeed * delta elseif RL_IsKeyDown( string.byte( "Q" ) ) then cameraRot = cameraRot - cameraRotSpeed * delta diff --git a/examples/image_draw/main.lua b/examples/image_draw/main.lua index 7d5cb90..2da0c58 100644 --- a/examples/image_draw/main.lua +++ b/examples/image_draw/main.lua @@ -34,7 +34,7 @@ function init() textImage = RL_ImageText( 0, "Cat", 10, 4, WHITE ) local imageSize = RL_GetImageSize( textImage ) RL_ImageDraw( image, textImage, { 0, 0, imageSize[1], imageSize[2] }, { 250, 40, imageSize[1], imageSize[2] }, WHITE ) - + texture = RL_LoadTextureFromImage( image ) end diff --git a/examples/platformer/main.lua b/examples/platformer/main.lua index 5bfa6ab..0032d0d 100644 --- a/examples/platformer/main.lua +++ b/examples/platformer/main.lua @@ -49,6 +49,11 @@ local player = { facing = 1, } +local kissa = { Vec2:new( 2, 4 ), 23 } + +-- print( table.concat( kissa ) ) +print( kissa[1] ) + local function createMap() for x = 1, tilemap.size.x do table.insert( tilemap.tiles, {} ) |
