Create material using correct texture source.
This commit is contained in:
@@ -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
|
||||
|
||||
@@ -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
|
||||
|
||||
|
||||
@@ -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, {} )
|
||||
|
||||
Reference in New Issue
Block a user