Jump to content
  • Advertisement

moose517

Member
  • Content Count

    109
  • Joined

  • Last visited

Community Reputation

226 Neutral

About moose517

  • Rank
    Member
  1. I really wish it was standardized and had to be placed in one spot. Nothing is more annoying to me than having to search many folders for save games when I do a system wipe. I wanna be able to copy one folder and grab all my game saves etc to move
  2. moose517

    Game dev team sharing code

    Its called version control. Something like git or svn will do you wonders
  3. Why not use tortoise svn in that case. Free and space is limited to your hard drive capacity.
  4. that looks great, keep up the work!
  5. If your devices have gigabit ethernet they should auto-switch, thus eliminating the need for a crossover cable.     partially correct, auto-mdix isn't part of the gig standard however like 99% of gig devices do support it, not a guarantee though.
  6. moose517

    Level File Type/Format<

    i specifiy the width and height of each block for a reason ;)  I don't plan on having a grid like layout, i want to be able to create larger and smaller blocks and not have a specific grid of any sort with placement of them.
  7. moose517

    Level File Type/Format<

    Thanks for the advice guys!  I decided to go with format like samoth said, which is what i was leaning towards in the first place.  Now i just need to get tinyXML added to my project so i can actually load the XML file.
  8. So i've successfully created one game in the past and now i'm in the process of writing a breakout clone and one thing i want to do is actually have levels that are loaded from disk.  One thing i keep going back and forth on is how to store to the disk, or rather what file type.  Right now i'm considering XML and finding a XML parser(i don't even know how to use 3rd party libraries other than like DX XD).  I considered XML because i know its quite flexible, then it dawned on me i have no idea how to layout a good XML file.  Right now all thats going to be stored is the name of the level, and the blocks, with each block having an x,y, width, height, and texture file name.  Problem is i'm not sure how to store that in a way that makes sense.  Right now i have it like this <level>     <name>Level 1</name>     <blocks>         <block>             <x>0</x>             <y>0</x>             <width>20</width>             <height>10</height>             <texture>block.png</texture>         </block>     </blocks> </level> each level will have its own XML file that gets loaded at the start of a level of course.  But the problem i ran into is having more than one block of course.  should i instead be doing like block1, block2, etc instead of just block?  Thats whats confusing me.  I'm sure as i go there might be more stuff stored, but for now thats all i have.   I would really appreciate some responses and hope this is the right sub section.
  9. moose517

    Stumped on why DX creation fails

    LOL so i feel like a real retard, i sent the code to a buddy to see if he could find my problem while i was gone on vacation, i screwed up my message proc switch statements, i didn't have the break statement in there LOL?? so it was causing it to always fall through to destroy window, hence it not being able to create the device because it had already released the window handle.
  10. moose517

    Stumped on why DX creation fails

    Double checked the control panel both regular and 64 bit version, both sliders set to max debugging, debug version, mem leak stuff checked. In my project i link to dxerr.lib and d3dx9d.lib for debug versions and still not a darn thing displayed.
  11. moose517

    Stumped on why DX creation fails

    i have actually been creating it with no multisampling, my config file tells it to use 0 aka none. As for the unknown i did originally have the X8R8G8B8 or R5G6B5 based on either 16 or 32 bit, forgot to change that back actually. @tempBuckeye, i reformatted and forgot to change that back to max afterwards, i have since done that but still nothing.
  12. moose517

    Stumped on why DX creation fails

    oops apparantly i cut off the last bit of the creation, will edit the OP LOL. the debug runtime doesn't provide any errors or warnings at all either.
  13. I started working on a project months ago and had stopped for some reason LOL, decided to "dust" off the code and continue where i was, only problem is i can't get some basic directx window creation to work, always fails to create the device, here is my code to create the window first of all bool Moose_API::createWindow() { static TCHAR szAppName[] = TEXT("API"); WNDCLASSEX wndclass; wndclass.cbSize = sizeof(WNDCLASSEX); wndclass.style = CS_HREDRAW | CS_VREDRAW; wndclass.cbClsExtra = 0; wndclass.cbWndExtra = 0; wndclass.hInstance = m_hInstance; wndclass.hIcon = LoadIcon(NULL, IDI_APPLICATION); wndclass.hCursor = LoadCursor(NULL, IDC_ARROW); wndclass.hbrBackground = (HBRUSH) GetStockObject(WHITE_BRUSH); wndclass.lpszMenuName = NULL; wndclass.lpszClassName = szAppName; wndclass.hIconSm = LoadIcon(NULL, IDI_APPLICATION); wndclass.lpfnWndProc = WndProc; // register class, if failed log and exit program if (!RegisterClassEx(&wndclass)) { logError("error log.txt", "Unable to Register Window Class"); PostQuitMessage(0); } m_hwnd = CreateWindowEx(WS_EX_OVERLAPPEDWINDOW, szAppName, TEXT("API"), WS_OVERLAPPEDWINDOW, m_positionX, m_positionY, m_sizeX, m_sizeY, NULL, NULL, m_hInstance, NULL); if (m_hwnd == NULL) { // couldn't create the window, log error and exit logError("error log.txt", "Unable to Create window"); PostQuitMessage(0); } ShowWindow(m_hwnd, m_nCmdShow); UpdateWindow(m_hwnd); return true; } m_sizeX, m_sizeY, m_hInstance, m_hwnd, and m_nCmdShow are members of the class and the initial values are passed to them upon program startup from a config file. Then here is my code to create a directx 9 interface m_d3dObject = Direct3DCreate9(D3D_SDK_VERSION); if (!m_d3dObject) { logError("error log.txt", "Direct3DCreate9 failed."); PostQuitMessage(0); } else logError("error log.txt", "Direct3DCreate9 passed."); D3DDISPLAYMODE mode; m_d3dObject->GetAdapterDisplayMode(D3DADAPTER_DEFAULT, &mode); hr = m_d3dObject->CheckDeviceType(D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, mode.Format, mode.Format, true); // check for windowed mode if (hr != S_OK) { logError("error log.txt", "CheckDeviceType: windowed failed."); PostQuitMessage(0); } else logError("error log.txt", "CheckDeviceType: windowed passed."); if (m_bits == 16) { hr = m_d3dObject->CheckDeviceType(D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, D3DFMT_R5G6B5, D3DFMT_R5G6B5, false); // fullscreen 16 bit if (hr != S_OK) { logError("error log.txt", "CheckDeviceType: 16 bit fullscreen failed."); PostQuitMessage(0); } else logError("error log.txt", "CheckDeviceType: 16 bit fullscreen passed."); } else if (m_bits == 32) { hr = m_d3dObject->CheckDeviceType(D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, D3DFMT_X8R8G8B8, D3DFMT_X8R8G8B8, false); // fullscreen 32 bit if (hr != S_OK) { logError("error log.txt", "CheckDeviceType: 32 bit fullscreen failed."); PostQuitMessage(0); } else logError("error log.txt", "CheckDeviceType: 32 bit fullscreen passed."); } D3DCAPS9 caps; m_d3dObject->GetDeviceCaps(D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, &caps);; DWORD devBehaviorFlags = 0; if (caps.DevCaps & D3DDEVCAPS_HWTRANSFORMANDLIGHT) { // set hardware vertex processing in behavior flags devBehaviorFlags |= D3DCREATE_HARDWARE_VERTEXPROCESSING; logError("error log.txt", "Hardware Vertex Processing supported."); } else { // set software vertex processing in behavior flags devBehaviorFlags |= D3DCREATE_SOFTWARE_VERTEXPROCESSING; logError("error log.txt", "Hardware Vertex Processing not supported."); } if (caps.DevCaps & D3DDEVCAPS_PUREDEVICE && devBehaviorFlags & D3DCREATE_HARDWARE_VERTEXPROCESSING) { // set pure device processing in behavior flags devBehaviorFlags |= D3DCREATE_PUREDEVICE; logError("error log.txt", "Pure device supported."); } D3DPRESENT_PARAMETERS d3dpp; d3dpp.BackBufferWidth = m_sizeX; // back buffer width in pixels d3dpp.BackBufferHeight = m_sizeY; // back buffer height in pixels d3dpp.BackBufferFormat = D3DFMT_UNKNOWN; // back buffer format d3dpp.BackBufferCount = 1; // number of back buffers DWORD quality = 0; // quality for MSAA switch(m_multiSamples) { case 2: { if (CheckDeviceMultiSampleType(m_bits, m_fullScreen, D3DMULTISAMPLE_2_SAMPLES)) { d3dpp.MultiSampleType = D3DMULTISAMPLE_2_SAMPLES; d3dpp.MultiSampleQuality = 0; logError("error log.txt", "CheckDeviceMultiSampleType 2 samples passed."); } else logError("error log.txt", "CheckDeviceMultiSampleType 2 samples failed."); break; } case 3: { if (CheckDeviceMultiSampleType(m_bits, m_fullScreen, D3DMULTISAMPLE_3_SAMPLES)) { d3dpp.MultiSampleType = D3DMULTISAMPLE_3_SAMPLES; d3dpp.MultiSampleQuality = 0; logError("error log.txt", "CheckDeviceMultiSampleType 3 samples passed."); } else logError("error log.txt", "CheckDeviceMultiSampleType 3 samples failed."); break; } case 4: { if (CheckDeviceMultiSampleType(m_bits, m_fullScreen, D3DMULTISAMPLE_4_SAMPLES)) { d3dpp.MultiSampleType = D3DMULTISAMPLE_4_SAMPLES; d3dpp.MultiSampleQuality = 0; logError("error log.txt", "CheckDeviceMultiSampleType 4 samples passed."); } else logError("error log.txt", "CheckDeviceMultiSampleType 4 samples failed."); break; } case 5: { d3dpp.MultiSampleType = D3DMULTISAMPLE_5_SAMPLES; break; } case 6: { d3dpp.MultiSampleType = D3DMULTISAMPLE_6_SAMPLES; break; } case 7: { d3dpp.MultiSampleType = D3DMULTISAMPLE_7_SAMPLES; break; } case 8: { d3dpp.MultiSampleType = D3DMULTISAMPLE_8_SAMPLES; break; } case 9: { d3dpp.MultiSampleType = D3DMULTISAMPLE_9_SAMPLES; break; } case 10: { d3dpp.MultiSampleType = D3DMULTISAMPLE_10_SAMPLES; break; } case 11: { d3dpp.MultiSampleType = D3DMULTISAMPLE_11_SAMPLES; break; } case 12: { d3dpp.MultiSampleType = D3DMULTISAMPLE_12_SAMPLES; break; } case 13: { d3dpp.MultiSampleType = D3DMULTISAMPLE_13_SAMPLES; break; } case 14: { d3dpp.MultiSampleType = D3DMULTISAMPLE_14_SAMPLES; break; } case 15: { d3dpp.MultiSampleType = D3DMULTISAMPLE_15_SAMPLES; break; } case 16: { d3dpp.MultiSampleType = D3DMULTISAMPLE_16_SAMPLES; break; } default: { d3dpp.MultiSampleType = D3DMULTISAMPLE_NONE; d3dpp.MultiSampleQuality = 0; logError("error log.txt", "CheckDeviceMultiSampleType: 0 samples being used."); break; } } d3dpp.SwapEffect = D3DSWAPEFFECT_DISCARD; d3dpp.hDeviceWindow = m_hwnd; if (m_fullScreen) { d3dpp.Windowed = false; } else { d3dpp.Windowed = true; } d3dpp.EnableAutoDepthStencil = true; d3dpp.AutoDepthStencilFormat = D3DFMT_D24S8; d3dpp.Flags = 0; d3dpp.FullScreen_RefreshRateInHz = D3DPRESENT_RATE_DEFAULT; if (m_vsync == 0) { d3dpp.PresentationInterval = D3DPRESENT_INTERVAL_IMMEDIATE; } else { d3dpp.PresentationInterval = D3DPRESENT_INTERVAL_DEFAULT; } hr = m_d3dObject->CreateDevice(D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, m_hwnd, devBehaviorFlags, &d3dpp, &m_gd3dDevice); if (hr != S_OK) { logError("error log.txt", "Failed to create DX9 interface."); PostQuitMessage(0); } else { logError("error log.txt", "Created DX9 interface."); return true; } some of that stuff can be ignored, i'm trying to make it as flexible as possible when reading from the config file, want to learn this things from more or less the beginning vs waiting till i have many games i've made and try and figure out how to adjust my code to account for different resolutions etc. I've checked my code with another sample program that compiles and runes fine but for the world of me cannot figure out why mine won't even if i comment out eveything and paste in from the other example adjusting variables to match.
  14. moose517

    TrackMania Wii Teaser Trailer

    that will be fun, played the crap outta the PC version but it fell off pretty quick :( loved all the servers setup with some pretty extreme but fun tracks.
  15. i'm probably a bit over redundant considering i'm still lower level programmer. i have project stored on my DEV pc, on my file server( on there is duplicated across 2 drives) and then also on an external drive to the server. also have another server running SVN that has it, and as last resort i use norton online backup and put there.
  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!