Hello.
Can anyone tell me how to load content into memblocks, otherwise I looked at the codes and did not understand anything.
Since I do not understand the method of loading into memblocks and loading from memblocks.
Judging by the description, one object can be crammed into each memblock. Is it possible to shove several objects into memblock?
Thank.
// Project: testmemblock
// Created: 2020-09-23
// show all errors
SetErrorMode(2)
// set window properties
SetWindowTitle( "testmemblock" )
SetWindowSize( 1024, 768, 0 )
SetWindowAllowResize( 1 ) // allow the user to resize the window
// set display properties
SetVirtualResolution( 1024, 768 ) // doesn't have to match the window
SetOrientationAllowed( 1, 1, 1, 1 ) // allow both portrait and landscape on mobile devices
SetSyncRate( 30, 0 ) // 30fps instead of 60 to save battery
SetScissor( 0,0,0,0 ) // use the maximum available screen space, no black borders
UseNewDefaultFonts( 1 ) // since version 2.0.22 we can use nicer default fonts
loadimage(1,"qattack.png")
CreateMemblockFromImage( 1, 1 )
deleteimage(1)
CreateImageFromMemblock( 1, 1 )
sync()
loadobject(1,"Quad Attack.X")
CreateMemblockFromObjectMesh( 2, 1,1 )
deleteobject(1)
CreateObjectFromMeshMemblock( 1, 2 )
setobjectimage(1,1,0)
setobjectposition(1,0,0,1000)
do
Print( ScreenFPS() )
Sync()
loop
How to load several textures into memblocks?
Download all the objects in one memblok and save to a file.