metaldc4life
Members-
Posts
86 -
Joined
-
Last visited
Content Type
Blogs
Forums
Store
Gallery
Videos
Everything posted by metaldc4life
-
attempt to index global 'App' (a nil value)??
metaldc4life replied to metaldc4life's topic in Programming
so far, I think your method may have worked but I get an error of this: refractionbuffer:SetColorTexture(tex) is it maybe because I didn't apply any texture or anything? -
attempt to index global 'App' (a nil value)??
metaldc4life replied to metaldc4life's topic in Programming
ahhh... I know what you mean I will try that and see.. -
attempt to index global 'App' (a nil value)??
metaldc4life replied to metaldc4life's topic in Programming
where would I place what you suggested? yes I do have a c++ project with it.. =) -
Hi, I am trying out this water in my game: http://www.leadwerks.com/werkspace/files/file/355-ocean-refractive-depth-shader-le25/ but I get this error for some reason? attempt to index global 'App' (a nil value) on this line: refractionbuffer = Buffer:Create(App.context:GetWidth(),App.context:GetHeight(),1,1); can someone please help me? Thank You!
-
almost got my program up and running just need one more thing..
metaldc4life replied to metaldc4life's topic in Programming
You rock! thank you for all your help!!!! I just need to do some tweaking and i'll get started on the rest... Thank You Again! -
almost got my program up and running just need one more thing..
metaldc4life replied to metaldc4life's topic in Programming
well i'm actually using visual studio to do all of this so.. i'll try in leadwerks though. -
almost got my program up and running just need one more thing..
metaldc4life replied to metaldc4life's topic in Programming
so I like divide 2 by my screen size or something like that? I appreciate all your help! -
almost got my program up and running just need one more thing..
metaldc4life replied to metaldc4life's topic in Programming
no I have a laptop i'm using, this is the script that might have to be changed but i'm not sure: //Move the mouse to the center of the screen window->SetMousePosition(context->GetWidth() / 2, context->GetHeight() / 2); -
almost got my program up and running just need one more thing..
metaldc4life replied to metaldc4life's topic in Programming
i just noticed what i put didn't make much sense lol sorry the main problem is i need help finding out what function to place so the mouse won't lock in the bottom right of the screen when the program is launched... -
almost got my program up and running just need one more thing..
metaldc4life replied to metaldc4life's topic in Programming
what I meant to put is that when I run the program it locks the mouse and I can't unlock it unless I ctrl+alt+Delete to end the program that way and I don't know how to take that function out or where to take it out from.. thank you for that useful link too! -
Hi, I got my program (my game up and running for the first time in visual studio) but the mouse locks into the bottom right of the screen.. I am certain I have to modify this part of the script but I need help with what to place there.. //Move the mouse to the center of the screen window->SetMousePosition(context->GetWidth() / 2, context->GetHeight() / 2); Thanks!
-
can't seem to run my map with my c++ script or in game..
metaldc4life replied to metaldc4life's topic in Programming
got it! thanks! -
can't seem to run my map with my c++ script or in game..
metaldc4life replied to metaldc4life's topic in Programming
the weird part is that it says this in leadwerks: Lua sandboxing disabled. even when it is enabled it still says this and vice-versa.. -
can't seem to run my map with my c++ script or in game..
metaldc4life replied to metaldc4life's topic in Programming
oh ok I fixed that part.. but how do I get it running with the remaining script? -
can't seem to run my map with my c++ script or in game..
metaldc4life replied to metaldc4life's topic in Programming
what do you mean? sorry i'm new at this just started yesterday on c++.. -
can't seem to run my map with my c++ script or in game..
metaldc4life replied to metaldc4life's topic in Programming
still won't bring it up in leadwerks.. is there any other method because I even built both too in visual studio -
can't seem to run my map with my c++ script or in game..
metaldc4life replied to metaldc4life's topic in Programming
what should I place as the comment? it also says sandbox is disabled even though it is enabled.. -
I tried running my game but it just closes the window in leadwerks when I hit run or debug.. i'm new to c++ but enjoy it quite a bit and would like to know how to get this working in game and in Microsoft visual studio... Thanks! here is my script I am using: #include "App.h" using namespace Leadwerks; App::App() : window(NULL), context(NULL), world(NULL), camera(NULL) {} App::~App() { delete world; delete window; } bool App::Start() { window = Window::Create("leadworks!!!", 1024, 1024, 1024, Leadwerks::Window::Titlebar); /*if (!Steamworks::Initialize()) { System::Print("Error: Failed to initialize Steam."); return false; }*/ //Create a window window = Leadwerks::Window::Create("hi?"); //Create a context context = Context::Create(window); //Create a world world = World::Create(); //Create a camera camera = Camera::Create(); camera->Move(0, 2, -5); //Hide the mouse cursor window->HideMouse(); std::string mapname = System::GetProperty("map", "Maps/JungleDave.map"); Map::Load("maps/JungleDave.map"); //Move the mouse to the center of the screen window->SetMousePosition(context->GetWidth() / 2, context->GetHeight() / 2); return true; } bool App::Loop() { //Close the window to end the program if (window->Closed()) return true; //Press escape to end freelook mode if (window->KeyHit(Key::Escape)); return true; }
-
why is the camera not on the player when using c++????
metaldc4life replied to metaldc4life's topic in Programming
oh ok! thank you I will give it a shot.. thanks again! =) -
Hi, I was just wondering why the camera is not on the player controller when I try to move around because I can hear him walkin jumping and the like but it's like a mile away from him? Anyone know why!? i'm using c++ now with Microsoft visual studio express.. Thanks.. oh and here's the code: #include "App.h" using namespace Leadwerks; App::App() : window(NULL), context(NULL), world(NULL), camera(NULL) {} App::~App() { delete world; delete window; } bool App::Start() { window = Window::Create("hello world", 800, 600, Leadwerks::Window::Titlebar); //Initialize Steamworks (optional) /*if (!Steamworks::Initialize()) { System::Print("Error: Failed to initialize Steam."); return false; }*/ //Create a window window = Leadwerks::Window::Create(""); //Create a context context = Context::Create(window); //Create a world world = World::Create(); //Create a camera camera = Camera::Create(); camera->Move(0,2,-5); //Hide the mouse cursor window->HideMouse(); std::string mapname = System::GetProperty("map","Maps/start.map"); Map::Load(mapname); //Move the mouse to the center of the screen window->SetMousePosition(context->GetWidth()/2,context->GetHeight()/2); return true; } bool App::Loop() { //Close the window to end the program if (window->Closed()) return false; //Press escape to end freelook mode if (window->KeyHit(Key::Escape)); }
-
worked like a charm thank you Rick!
-
oh ok, how do I compile it though? Thanks for the help! =)
-
Hi, i'm now using the c++ version of leadworks and I just started it and added like one thing and I hit the run button and it says failed to launch exe? Please help me on this someone.. thanks in advance!
-
how do i go about getting leradwerks 2.0 instead of 3.2??
metaldc4life replied to metaldc4life's topic in General Discussion
thanks =) -
Hi, I was needing to know how to adjust the x and y axis on the mouse while using this water prefab: http://www.leadwerks.com/werkspace/files/file/468-water-prefab-for-leadwerks-31-steam-ed/ I followed everything but when I move the camera to the player it works ok but I cannot look up nor down so I am assuming there needs to be an adjustment on the mouse axis I guess?? Thanks In Advanced!