• Announcements

    • khawk

      Download the Game Design and Indie Game Marketing Freebook   07/19/17

      GameDev.net and CRC Press have teamed up to bring a free ebook of content curated from top titles published by CRC Press. The freebook, Practices of Game Design & Indie Game Marketing, includes chapters from The Art of Game Design: A Book of Lenses, A Practical Guide to Indie Game Marketing, and An Architectural Approach to Level Design. The GameDev.net FreeBook is relevant to game designers, developers, and those interested in learning more about the challenges in game development. We know game development can be a tough discipline and business, so we picked several chapters from CRC Press titles that we thought would be of interest to you, the GameDev.net audience, in your journey to design, develop, and market your next game. The free ebook is available through CRC Press by clicking here. The Curated Books The Art of Game Design: A Book of Lenses, Second Edition, by Jesse Schell Presents 100+ sets of questions, or different lenses, for viewing a game’s design, encompassing diverse fields such as psychology, architecture, music, film, software engineering, theme park design, mathematics, anthropology, and more. Written by one of the world's top game designers, this book describes the deepest and most fundamental principles of game design, demonstrating how tactics used in board, card, and athletic games also work in video games. It provides practical instruction on creating world-class games that will be played again and again. View it here. A Practical Guide to Indie Game Marketing, by Joel Dreskin Marketing is an essential but too frequently overlooked or minimized component of the release plan for indie games. A Practical Guide to Indie Game Marketing provides you with the tools needed to build visibility and sell your indie games. With special focus on those developers with small budgets and limited staff and resources, this book is packed with tangible recommendations and techniques that you can put to use immediately. As a seasoned professional of the indie game arena, author Joel Dreskin gives you insight into practical, real-world experiences of marketing numerous successful games and also provides stories of the failures. View it here. An Architectural Approach to Level Design This is one of the first books to integrate architectural and spatial design theory with the field of level design. The book presents architectural techniques and theories for level designers to use in their own work. It connects architecture and level design in different ways that address the practical elements of how designers construct space and the experiential elements of how and why humans interact with this space. Throughout the text, readers learn skills for spatial layout, evoking emotion through gamespaces, and creating better levels through architectural theory. View it here. Learn more and download the ebook by clicking here. Did you know? GameDev.net and CRC Press also recently teamed up to bring GDNet+ Members up to a 20% discount on all CRC Press books. Learn more about this and other benefits here.

ryan mccabe

Members
  • Content count

    79
  • Joined

  • Last visited

Community Reputation

161 Neutral

About ryan mccabe

  • Rank
    Member
  1. Unity

    I'm looking to make a mission based rts. It'll revolve around taking down an established regional power starting with a coup on board a main carrier. Fidelity wise Im aiming for star conflict / eve online levels. In terms of gameplay and scope there will be a fairly standard world map with total war style base development, there will also be battle maps for real time combat. the battle maps will involve a fairly standard rts setup, very homeworld-esque with a stretch goal of allowing the player to pilot 'elite' ships. Units will have special powers (a magic system essentially). Describing the scale is difficult but if you've played star conflict, then thats about the scale. Mind you I'm not looking to finish, only have the visuals and basic logic done, a tech demo.    Unity feels perfect when developing since there doesn't seem to be any preset game in mind within the engine. Aside from the render limitation when using free what really got me poking around was the particle engine. I spent a week or so building a  prefab/script that spawns particles and allows me to dynamically adjust settings to make various kinds of weapons fire. Works well, could use some optimization but it allows for huge variety in the kinds of effects weapons effects quickly and easily. Then I duplicated it a few times and watched the framerate plummet. I can work around it by using a single emitter or maybe baking out the different effects (somehow). Other, better, solutions (gl class or line drawing) required full access, so I started looking around again.    Ignoring cost for engines (although that was a good analysis, kburkhart84) I can use unity and be limited in graphics which is my focus, or hack at UDK and take an extended development period. Anyway I'll probably ramble if I continue. Thanks again for any discussion or advice. 
  2. Hi, I'm hoping one of you has some experience to share. Im trying to get a demo going for a space game. I started writing an engine on my own, which was slow and painful but worth the experience. Moving past that I got into unity only to find that to get good performance and visuals you'll need to buy the pro version, which is where I'm leaning. cryEngine 3 peaked my interest but the indie licensing comes with some serious horror stories up to having an admin delete a small studios account. Also CE3 and UDK are both fps focused and thus need some serious hacking to get to work with a space game. My focus is the visuals, its where Ill spend most of my time, making me wonder if the pain of UDK for a space game might be worth it over unity. Also I'm not at all impressed with unity's visual capabilities vs performance and complexity.    I know there are a lot of engines to pick from but given what I've stated does anyone have recommendations, maybe something I've overlooked?    
  3. I think your right. Ive seen GetMessage / PeekMessage in a while loop is that what I should do? Ive tried assigning peek to a boolean and running until false but doing that blocked everything and I ended up with a black screen [code] void SystemClass::Run() { MSG msg; bool done, result; // Initialize the message structure. ZeroMemory(&msg, sizeof(MSG)); // Loop until there is a quit message from the window or the user. done = false; while(!done) { // Handle the windows messages. if(PeekMessage(&msg, NULL, 0, 0, PM_REMOVE)) { TranslateMessage(&msg); DispatchMessage(&msg); } // If windows signals to end the application then exit out. if(msg.message == WM_QUIT) { done = true; } else { result = Frame(); if(!result) { done = true; } } } return; } [/code] frame starts the frame processing and rendering.
  4. I had my input system written but it was a strange mix of windows messages and polling with getasync() ect. The real problem though was that when trying to use the mouse and the keyboard the entire engine stuttered. I'm no too sure what I did there but it pushed me to try to wrap raw input and depend only on that. Its resolved the stuttering but now I'm getting mouse lag like Ive never seen. Everything keeps moving fine but a second of mouse movement is turning into a minute of movement and being locked out of further input. So if i move the mouse and hit esc to quit I have to wait for the extremely slowed input lag to finish. The whole thing is rather frustrating I'm almost ready to say die and hook in directinput, but then again that may be more hours of debugging. What I really want to do is sidestep the message queue and go with nothing but getasync() for movement controls, will that cause problems down the line? Raw Input is recommended but its the most complicated, for movement controls is it really the best choice? Anyone have a link / name for some demo code and / or wrappers for raw input (c++)? Lastly, if anyone has a minute could you take a look at the input code's latest incarnation and let me know if a message queue lagging issue pops? Any comments on the code are more than welcome too. [code] switch(umsg) { case WM_CREATE: { RAWINPUTDEVICE Rid[2]; Rid[0].usUsagePage = 0x01; Rid[0].usUsage = 0x02; Rid[0].dwFlags = 0; // adds HID mouse Rid[0].hwndTarget = 0; Rid[1].usUsagePage = 0x01; Rid[1].usUsage = 0x06; Rid[1].dwFlags = 0; // adds HID keyboard Rid[1].hwndTarget = 0; if (RegisterRawInputDevices(Rid, 2, sizeof(Rid[0])) == FALSE) { strPrinter("input registration failed"); } } case WM_INPUT: { UINT dwSize; // Determine how big the buffer should be GetRawInputData((HRAWINPUT)lParam, RID_INPUT, NULL, &dwSize, sizeof(RAWINPUTHEADER)); BYTE* lpb; lpb = new BYTE[dwSize]; if (lpb == NULL) { strPrinter("lpb not initialized"); return 0; } if (GetRawInputData((HRAWINPUT)lParam, RID_INPUT, lpb, &dwSize, sizeof(RAWINPUTHEADER)) != dwSize ) strPrinter("GetRawInputData does not return correct size !"); GetRawInputData((HRAWINPUT)lParam, RID_INPUT,(LPVOID)lpb, &dwSize, sizeof(RAWINPUTHEADER)); RAWINPUT* raw = (RAWINPUT*)lpb; switch (raw->header.dwType) { case RIM_TYPEMOUSE: { // read the mouse data long mx = raw->data.mouse.lLastX; long my = raw->data.mouse.lLastY; m_Input->mouseMove(mx, my); delete[] lpb; return 0; } case RIM_TYPEKEYBOARD: { // read the keyboard data m_Input->KeyUp(raw->data.keyboard.VKey); delete[] lpb; return 0; } } delete[] lpb; return 0; } [/code] Thanks guys n gals.
  5. My bad, there was a check to not print 0 in printFloat... sorry for the bother.
  6. I have some really simple code that does not do what it should. The function gets an x and a y value, updates if there is a change, or sets a value to 0 if no change has occurred. The problem is that the value isn't being set to 0. [code] bool CameraClass::Update(float x, float y) { // right mouse button for camera rotation if(GetAsyncKeyState(0x02)) { if(m_rotationX != x) m_rotationX = x; else { //here is the problem. m_rotation is not being changed. The same happens with the y value. m_rotationX = 0.0f; printFloat(m_rotationX); printFloat(x); } if(m_rotationY != y) m_rotationY = y; else m_rotationY = 0.0f; } if(!GetAsyncKeyState(0x02)) { m_rotationX = 0; m_rotationY = 0; } return true; } [/code] printFloat is only called if m_rotationX is set to 0 first, but in the print out the values always print the matching pair. So if m_rotationX is 100 and x is 100 i get (100, 100) printed. What should happen is I get (0, 100) since the pair matched and m_rotationX was set to 0. Its boggling my mind a bit. I don't see how setting a value in such a straight forward way could fail. Any advice? Edit: camera behavior also confirms the print.
  7. Ive been mulling this over for a while. Im at a point where the number of objects in my demo engine is growing painful manage. Rather than write out object something = new classT for each and every new object, is it possible to write a file parser / script interface that will generate objects and delete them? for example: if level1 run (level1script) run(script) //get create the objects build(entities) initialize(entities) build(entities) //get pointers to objects for all entities "name from file" = new entity initialize(entities) //initialize entities from file for all entities setAttributes(entity) setAttributes(entity) //read and return the attributes to initialize with entity(findInFile(entity)) What I cant figure out is how to write code so that it will make objects based on whats written in a file. Can i just copy strings from a file and use some clever sprintf useage to get it to be a name, or do i set a vector to hold all the created objects of a given type and have the script manage whats where? Sorry if this is all very confusing, Im just confused about it myself, but i cant imagine that every simgle object must be hard coded into c++. If its standard to do so please tell me though ryan
  8. Started with box.net yesterday too soon to tell how its going. Skydrive sounds like it may be a better alternative. Ive tried dropbox, but i didn't like the way the actual file upload from the synced folder works, seemed like there was no accounting for how long it was going to be between dropping on one device an getting it on the other. Anyway thanks for the feedback
  9. Between using a pc, tablet, and smartphone, Ive realized online storage makes a lot of sense. But the options are really confusing. Game models, source code, books, and research articles are something i use on 2 of 3 devices each, at least. So Im wondering what you guys use?
  10. Hey guys. Im hoping someone can shed some light on making the code more manageable. Its for a direct3d framework. The framework itself functions well enough, but it needs some serious tweaking. Right now each model is loaded in the main graphics class that does rendering calls. Functions inside the class are specific to each model. load: [code] // Create the model object. m_Model = new ModelClass; if(!m_Model) { return false; } // Initialize the model object. result = m_Model->Initialize(m_D3D->GetDevice(), "../Engine/Assets/SphereMesh.txt", L"../Engine/Assets/earthlights.dds"); if(!result) { MessageBox(hwnd, L"Could not initialize the model object.", L"Error", MB_OK); return false; } [/code] function method: [code] m_BeaconModel->Render(m_D3D->GetDeviceContext()); m_testTexture->Render(m_D3D->GetDeviceContext(), m_BeaconModel->GetIndexCount(), worldMatrix, viewMatrix, projectionMatrix, m_BeaconModel->GetTexture(), m_Light->GetDirection(), color); ...... if(m_Frustum->CheckSphere(x,y,z, 2.0f)) { D3DXMatrixTranslation(&transMatrix, x, y, z); worldMatrix = transMatrix; m_BeaconModel->Render(m_D3D->GetDeviceContext()); m_testTexture->Render(m_D3D->GetDeviceContext(), m_BeaconModel->GetIndexCount(), worldMatrix, viewMatrix, projectionMatrix, m_BeaconModel->GetTexture(), m_Light->GetDirection(), color); } [/code] As you can see its very hard coded. If I want to use another model with the function above I have to alter the function and not the call. I know this isn't right. Do I use something like this->render( ... ) inside functions to make them work upon whatever i call them with as opposed to what Ive hard-coded? Also right now the model loading bothers me. Hard coding in all the models and textures seems wrong if not impossible for anything with a significant number of meshes and textures. Is it possible to write a function or a manager class that will load and unload as needed given a lookup table or some such? I dont necessarily need exact methods, but Im a little aimless in how to write my code in a more manageable way so any direction is very helpful right now. Thanks all.
  11. it could, or you could use the method you posted as the bounding box esq check, then move to the finer grain pixel check.
  12. You could do a bounding box check first to see which sprites may have collided, then check only those sprites.
  13. directx 10 [url="http://www.rastertek.com/dx10tut29.html"]water tutorial[/url]
  14. Thank you for the code, unfortunately the problem was much more subtle. I switched from WM_MOUSEMOVE in the message loop to GetCursorPos() inside the mouse update call and the random movements are gone. On the bright side WM only checks for esc in the code now and all other key presses checked directly when they are needed, and after screwing with camera code for over a week I bet I could now write one in my sleep lol.
  15. Hey again. Wondering if someone can help find the bug in this code. Its just a camera class that takes input and transforms the view matrix. The camera follows the mouse and moves with key presses. Everything works great until I move the camera while rotating, then the camera just starts doing its own thing, slipping into an accelerated turns and ignoring input. The longer I keep rotating and moving the worse the effect gets until it just ludicrously spins out of control, even for a time after all input is stopped. [code] void CameraClass::Render() { D3DXVECTOR3 vRotAxis, vDirection; float yaw, pitch, roll; int rotationFactor = 8; D3DXMATRIX pitchMatrix, yawMatrix, rotationMatrix, movementMatrix; //==================== // Rotational movement //==================== // Set the yaw (Y axis), pitch (X axis), and roll (Z axis) rotations in radians. yaw = m_rotationX * 0.0174532925f; pitch = m_rotationY * 0.0174532925f; roll = m_rotationZ * 0.0174532925f; // Create direction (forward) D3DXVec3Normalize(&vDirection, &(m_vLookAtPt - m_vEyePt)); //strafe vector D3DXVec3Cross(&vRotAxis,&vDirection,&m_vUp); D3DXVec3Normalize(&vRotAxis, &vRotAxis); //create rotation matrices D3DXMatrixRotationAxis(&pitchMatrix, &vRotAxis, -(pitch / rotationFactor)); //rotate around x D3DXMatrixRotationAxis(&yawMatrix, &m_vUp, (yaw / rotationFactor)); //rotate around y //rotate direction D3DXVec3TransformCoord(&vDirection, &vDirection, &(pitchMatrix * yawMatrix)); //rotate up vector D3DXVec3TransformCoord(&m_vUp, &m_vUp, &(pitchMatrix * yawMatrix)); // Translate the rotated camera position to the location of the viewer. m_vLookAtPt = vDirection + m_vEyePt; //===================== // Directional movement //===================== if (moveForward) { m_vEyePt += vDirection * m_fSpeed; m_vLookAtPt += vDirection * m_fSpeed; } if (moveBackward) { m_vEyePt -= vDirection * m_fSpeed; m_vLookAtPt -= vDirection * m_fSpeed; } if (moveLeft) { D3DXVec3Cross(&vDirection,&vDirection,&m_vUp); //create strafe vector D3DXVec3Normalize(&vDirection,&vDirection); m_vEyePt += vDirection * m_fSpeed; m_vLookAtPt += vDirection * m_fSpeed; } if (moveRight) { D3DXVec3Cross(&vDirection,&vDirection,&m_vUp); //create strafe vector D3DXVec3Normalize(&vDirection,&vDirection); m_vEyePt -= vDirection * m_fSpeed; m_vLookAtPt -= vDirection * m_fSpeed; } // Get the movement matrix D3DXMatrixLookAtLH(&m_viewMatrix, &m_vEyePt, &m_vLookAtPt, &m_vUp); return; } [/code] Rotating is ok on its own and so is moving. Even short bursts of both work ok too. I figure since its a standard camera class it'll either check out or not. P.s. sorry for the inconsistent naming conventions, I hacked in a lot of different camera models before getting here. . . probably should clean it up a bit.