zinador Posted July 10, 2010 Share Posted July 10, 2010 All greetings, have compiled game, for me at the permission 640,480 work perfectly if to put the permission more that at start of my game Windows swear that cannot allocate memory, But an essence not in it. I give to the friend the compiled project with different permissions, and at it Windows too swears that Cannot to allocate memory, in what a problem and how it to correct? I so understand that it in project options it is necessary to climb? Help please source code game #include "engine.h" int main( int argn, char* argv[] ) { Initialize() ; SetAppTitle( "MyGame" ) ; Graphics(640,480 ) ; AFilter() ; TFilter() ; TWorld world; TBuffer gbuffer; TCamera camera; TMesh mesh; TLight light; TMesh ground; TMaterial material; world = CreateWorld() ; if (!world) { MessageBoxA(0,"Error","Failed to create world.",0); return Terminate(); } gbuffer=CreateBuffer(GraphicsWidth(),GraphicsHeight(),BUFFER_COLOR|BUFFER_DEPTH|BUFFER_NORMAL); camera=CreateCamera(); mesh=CreateCube(camera); ground=CreateCube(); ScaleEntity(ground,Vec3(10,1,10)); PositionEntity(ground,Vec3(0,-2,0)); light=CreateDirectionalLight(); RotateEntity(light,Vec3(45,45,45)); //Управление TVec3 camrotation=Vec3(0); float mx=0; float my=0; float move=0; float strafe=0; // Игровой цикл while(!KeyHit(KEY_ESCAPE) && !AppTerminate() ) { //Управление и мышь mx=MouseX()-GraphicsWidth()/2; my=MouseY()-GraphicsHeight()/2; MoveMouse(GraphicsWidth()/2,GraphicsHeight()/2); camrotation.X=camrotation.X+my; camrotation.Y=camrotation.Y-mx; if(camrotation.X>80) { camrotation.X=80; } if(camrotation.X<-40) { camrotation.X=-40; } RotateEntity(camera,camrotation); move=Curve(KeyDown(KEY_W)-KeyDown(KEY_S),move,1000); strafe=Curve(KeyDown(KEY_D)-KeyDown(KEY_A),strafe,1000); MoveEntity(camera,Vec3(strafe,0,move)); if( !AppSuspended() ) { // Обновление времени и мира UpdateAppTime(); UpdateWorld(AppSpeed()) ; // Отрисовка SetBuffer(gbuffer); RenderWorld(); SetBuffer(BackBuffer()); RenderLights(gbuffer); Flip(0) ; } } return Terminate() ; } Quote Link to comment Share on other sites More sharing options...
Laurens Posted July 10, 2010 Share Posted July 10, 2010 Jebus, what? I think it would be wise to just type your question in Russian (based on your comments I would guess you are Russian) and pull it through Google Translate. Also get yourself registered as an SDK developer to get access to the programming forums. http://leadwerks.com/werkspace/index.php?/topic/127-if-you-need-access-to-the-forum/ Cheers! Quote Link to comment Share on other sites More sharing options...
Mumbles Posted July 11, 2010 Share Posted July 11, 2010 What is your graphics card? Quote LE Version: 2.50 (Eventually) Link to comment Share on other sites More sharing options...
AggrorJorn Posted July 11, 2010 Share Posted July 11, 2010 So to sum up your computer only allows a window resolution of 640,480. But when you use higher resolutions it says something like "Can not allocate memory." Can you post a photo or screenshot of the error message? Quote Link to comment Share on other sites More sharing options...
Mumbles Posted July 13, 2010 Share Posted July 13, 2010 Also, which version of Leadwerks is this? (2.0 or 2.3) Edit: Wait a minute - I didn't know the "members" group could access the programming boards... Quote LE Version: 2.50 (Eventually) Link to comment Share on other sites More sharing options...
ArBuZ Posted July 13, 2010 Share Posted July 13, 2010 They can not. I guess, this post was moved from general discussion board. Now if he wants to have an answer, he have to buy the engine Quote Q6600@2.4GHz - 9600GT - 4GB DDR2@800MHz - Windows7 x64 3ds max / photoshop CS3 / C++ http://www.arbuznikov.com Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.