Jump to content


  • Content Count

  • Joined

  • Last visited

Everything posted by MrIslomaniac

  1. thats what I mean =) @MG do you still know how you configured that water to look like this? http://leadwerks.com/werkspace/index.php?app=gallery&module=images&section=viewimage&img=33
  2. MasterXilo, exactly. Why do we need a loadheightmap function?
  3. I just did another calculation, i could make the scale much smaller but I don't know what would happen if i load an object that is 0.1137 meters and i zoom very close... of cause i need to slow down the camera and say that it should not stop rendering whats in front of it ... i'll try that later today, hopefully it will work =) Thanks again
  4. Well the distance between the sun and pluto is 5913520000 km. I already divide every value by 4.000.000 and take the result for the engine in Units ... So for pluto that would be 1.478.380 meters, since you can set the camera view range to 3.000.000 i thought that would work ...
  5. When I change the pointlight line to this: TLight miau = CreatePointLight(1000,0); it happens again ... I know that in the editor you can only set it to 100 but i need it to light for a distance of 15000000 LE units ... Solar system ftw ^^
  6. My version is up to date... Can you look at the dll filesize? are they different? EDIT Yes that was it now it works for me too =) Thank you guys so much =) appreciate it Dustin
  7. hmm weird... which version of the engine are you guys using? i am using 2.31
  8. Thank you for trying mg! Maybe it is something with my graphics card... Nvidia gforce 9600 GT can you or someone else try this? it's the compiled version: http://rapidshare.com/files/355699112/Shadow_Test.zip.html
  9. thats exactly what should happen... But fly around it and look at the shadow edges heres a picture:
  10. Got a little problem here guys. I see the edge of an invisible cube through the shadows of my model, any clues? #include "engine.h" int main(int argc, char** argv) { Initialize(); //Create a graphics context Graphics(800,600); //Create a world if (!CreateWorld()) { MessageBoxA(0,"Error","Failed to create world.",0); goto exitapp; } CreateFramework(); //Create a camera TEntity cam=CreateCamera(); CameraClearColor(cam,Vec4(0,0,1,1)); PositionEntity(cam,Vec3(0,2,-10)); //Create a light TEntity Map = LoadScene("abstract::TestSystem.sbx"); TLight miau = CreatePointLight(100,0); PositionEntity(miau,Vec3(0,0,0)); //Create a render buffer TBuffer buffer=CreateBuffer(800,600,BUFFER_COLOR|BUFFER_DEPTH|BUFFER_NORMAL); int move=0; int strafe=0; TVec3 camrotation=Vec3(0); float mx=0; float my=0; //Main loop while(!AppTerminate()) { //Camera look if (MouseDown(1)){ HideMouse(); mx=Curve(MouseX()-GraphicsWidth()/2,mx,6); my=Curve(MouseY()-GraphicsHeight()/2,my,6); MoveMouse(GraphicsWidth()/2,GraphicsHeight()/2); camrotation.X=camrotation.X+my/10.0; camrotation.Y=camrotation.Y-mx/10.0; RotateEntity(cam,camrotation); } else if (!MouseDown(1)){ ShowMouse(); } RotateEntity(cam,camrotation); //Camera movement move=KeyDown(KEY_W)-KeyDown(KEY_S); strafe= KeyDown(KEY_D)-KeyDown(KEY_A); MoveEntity(cam,Vec3(strafe/10.0,0,move/10.0)); UpdateFramework(); RenderFramework(); //Swap the front and back buffer Flip(0); } exitapp: return Terminate(); } here are the files you need: http://rapidshare.com/files/355513076/Test.rar.html Thank you =)
  11. Can we have a function like this? LoadTerrainVegetationLayer( TEntity terrain, str path, int Layer ) Would be great =) thanks
  12. That sometimes happens to me, but i disabled the console for the release version =) http://www.leadwerks.com/wiki/index.php?title=Setting_Up_Visual_Studio_2008_C%2B%2B_Express at the bottom
  13. I think that the mat file has to be changeg, just like mg's, but unfortunately microsoft office access table is assigned to .mat files and i can't open them ... =( File Extension .MAT - Microsoft Access Table Shortcut //Ok got that working now The light somehow isn't. can you send me the model you are using? maybe that will work ... //I just tried the model in the editor as well and there it works oO something i have to consider when putting this in the .exe? //light and sun: TEntity cam=CreateCamera(); CameraClearColor(cam,Vec4(0,0,1,1)); TLight light1 = CreatePointLight(1000,0); //and here is the rendering loop: UpdateWorld(); //Render the scene SetBuffer(buffer); RenderWorld(); //Render lighting SetBuffer(BackBuffer()); RenderLights(buffer); //Swap the front and back buffer Flip(0);
  14. A simple point light in the middle of my scene and a loaded model of a sphere (i also tried create sphere,same result) returns this: http://img535.imageshack.us/img535/3923/sun.jpg This is for a school project, where the sun in the middle of the scene casts shadows on the planets aroound it. The sun you see in the picture is in Vec3(0,0,15). I need help -.-
  15. Ok heres the next thing: when I do this SetColor(Vec4(0.5,0.5,0.5,1)); DrawRect(0,0,100,100); The texture is a little bit transparent, anyone knows why? P.S. no SetBlend(Alpha) is being used =(
  16. Thanks for those fast answers =) you guys are awesome :D
  17. Why does SetColor(Vec4(150,200,100,255)); return white? =( Dustin
  18. Ok I'll make some of these this weekend and post some pics here.
  19. I just wanna practice modeling a little bit, so i would appreciate if you could give me something to model If the final product looks good to you, I can even upload it Thanks guys for your help P.S. I don't model characters
  20. GetParent(pick.entity) did it =) never thought of that xD Thank you Rick
  21. if (KeyHit(KEY_E)==1){ if((CameraPick(&pick, cam,Vec3(GraphicsWidth()/2,GraphicsHeight()/2,1),50))!= NULL){ SendEntityMessage(pick.entity, "Open"); } }
  22. Nope that does not help =( Thanks anyway P.S. i did not put the whole code in here: 8code] TModel Cube = LoadModel("abstract::oldtree.gmf"); SetEntityKey(Cube,"Health","100"); EntityColor(Cube,Vec4(1,1,1,255)); ScaleEntity(Cube,Vec3(1,5,1)); PositionEntity(Cube,Vec3(x,y-1.25,z)); EntityType(Cube,1); SetEntityCallback(Cube,(byte*)MessageReceiveCallback,ENTITYCALLBACK_MESSAGERECEIVE); [/code]
  23. Hey mates MessageReceiveCallback does not seem to work with an entity Loaded from a file! Anyone experienced that as well? Or maybe found a solution? I would be happy to hear one Cya TEntity Cube = LoadModel("abstract::tree.gmf"); SetEntityCallback(Cube,(byte*)MessageReceiveCallback,ENTITYCALLBACK_MESSAGERECEIVE); And void _stdcall MessageReceiveCallback( TEntity entity, str message, byte* extra ) { char str[256]; sprintf(str, "%d got a message. Message name: \"%s\"", (int)entity, message); MessageBox(0, str, "MessageReceiveCallback called", 0); } It does work correctly if i don't load the file but use CreateCube(0);
  • Create New...