Jump to content
  • Advertisement
Sign in to follow this  
  • entries
  • comments
  • views

Quiz category

Sign in to follow this  
Elvis Enmanuel


Quiz category contains 2 question games:

Fun Trivia is a trivial kinda game that allows four players and has 6 question themes (with fancy board animation).

Wheel of points is a wheel of fortune kinda game.


Sign in to follow this  


Recommended Comments

There are no comments to display.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement
  • Advertisement
  • Blog Entries

  • Similar Content

    • By somedev
      Hey guys, I'm pretty new to Direct3D and I try to generate a png image file to disk from a already loaded initialized image from `LPDIRECT3DTEXTURE9` object.
      Basically I'm creating a function that get's an std::string for the file destination path and get the pixels from the existing LPDIRECT3DTEXTURE9 object and save them to disk.
      Any help would be much appreciated!
      Thanks in advance!
      I though I should add a sample code of how I do it with BitMap format to get the idea of what I'm trying to do.
      Note that this code works, but I try to do something similar with PNG format.
      int Width = 128; int Height = 128; LPDIRECT3DTEXTURE9 m_lpTexture; LPDIRECT3DDEVICE9 s_lpD3DDev = NULL; bool SaveToBitmapFile(const std::string & szPath) { LPDIRECT3DSURFACE9 lpSurfSrc = NULL; LPDIRECT3DSURFACE9 lpSurfDst = NULL; m_lpTexture->GetSurfaceLevel(0, &lpSurfSrc); s_lpD3DDev->CreateOffscreenPlainSurface(Width, Height, D3DFMT_A8R8G8B8, D3DPOOL_DEFAULT, &lpSurfDst, NULL); if (D3D_OK != D3DXLoadSurfaceFromSurface(lpSurfDst, NULL, NULL, lpSurfSrc, NULL, NULL, D3DX_FILTER_TRIANGLE, 0)) { lpSurfDst->Release(); lpSurfDst = NULL; lpSurfSrc->Release(); lpSurfSrc = NULL; } CBitMapFile myBmp; myBmp.Create(Width, Height); D3DLOCKED_RECT LR; lpSurfDst->LockRect(&LR, NULL, 0); for (int y = 0; y < Height; y++) { BYTE* pPixelsSrc = ((BYTE*)LR.pBits) + y * LR.Pitch; BYTE* pPixelsDst = (BYTE*)(myBmp.Pixels(0, y)); for (int x = 0; x < Width; x++) { pPixelsDst[0] = pPixelsSrc[0]; pPixelsDst[1] = pPixelsSrc[1]; pPixelsDst[2] = pPixelsSrc[2]; pPixelsSrc += 4; pPixelsDst += 3; } } lpSurfDst->UnlockRect(); lpSurfDst->Release(); lpSurfDst = NULL; lpSurfSrc->Release(); lpSurfSrc = NULL; HANDLE hFile = ::CreateFile(szPath.c_str(), GENERIC_WRITE, 0, NULL, CREATE_ALWAYS, FILE_ATTRIBUTE_NORMAL, NULL); DWORD dwRWC = 0; WriteFile(hFile, &myBmp.m_Header, sizeof(myBmp.m_Header), &dwRWC, NULL); WriteFile(hFile, &myBmp.m_InfoHeader, sizeof(myBmp.m_InfoHeader), &dwRWC, NULL); int iWidth = myBmp.Pitch(); for (int y = myBmp.m_InfoHeader.biHeight - 1; y >= 0; y--) WriteFile(hFile, (BYTE*)myBmp.m_pPixels + y * iWidth, iWidth, &dwRWC, NULL); CloseHandle(hFile); }  
    • By mako737
      Mário Pauko 1 Hello, when i create a project with UE4 and c++ i get this error
      LINK : fatal error LNK1181: cannot open input file 'C:\Users\Admin\Desktop\Môj Život\UE_4.20\Engine\Intermediate\Build\Win64\UE4Editor\Development\Core\UE4Editor-Core.lib' Error executing C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.15.26726\bin\HostX64\x64\link.exe (tool returned code: 1181) UE4Editor-akNejdeMamPici.lib (0:02.31 at +1:27)    Creating library C:\Users\Admin\Documents\Unreal Projects\akNejdeMamPici\Intermediate\Build\Win64\UE4Editor\Development\akNejdeMamPici\UE4Editor-akNejdeMamPici.lib and object C:\Users\Admin\Documents\Unreal Projects\akNejdeMamPici\Intermediate\Build\Win64\UE4Editor\Development\akNejdeMamPici\UE4Editor-akNejdeMamPici.exp ---------------------- Done ----------------------     Rebuild All: 0 succeeded, 1 failed, 0 skipped ERROR: UBT ERROR: Failed to produce item: C:\Users\Admin\Documents\Unreal Projects\akNejdeMamPici\Binaries\Win64\UE4Editor-akNejdeMamPici.dll        (see ../Programs/UnrealBuildTool/Log.txt for full exception trace) Total build time: 118,54 seconds (XGE executor: 0,00 seconds)  
      Pls tell me every step i have to do for this problem 
    • By _Nyu
      I'm trying to make a PBR vulkan renderer and I wanted to implement Spherical harmonics for the irradiance part (and maybe PRT in the future but that's another story).
      the evaluation on the shader side seems okay (it look good if I hardcode the SH directly in the shader) but when I try to generate it from a .hdr map it output only gray scale.
      It's been 3 days I'm trying to debug now I just have no clue why all my colour coefficients are gray.
      Here is the generation code:
      SH2 ProjectOntoSH9(const glm::vec3& dir) { SH2 sh; // Band 0 sh.coef0.x = 0.282095f; // Band 1 sh.coef1.x = 0.488603f * dir.y; sh.coef2.x = 0.488603f * dir.z; sh.coef3.x = 0.488603f * dir.x; // Band 2 sh.coef4.x = 1.092548f * dir.x * dir.y; sh.coef5.x = 1.092548f * dir.y * dir.z; sh.coef6.x = 0.315392f * (3.0f * dir.z * dir.z - 1.0f); sh.coef7.x = 1.092548f * dir.x * dir.z; sh.coef8.x = 0.546274f * (dir.x * dir.x - dir.y * dir.y); return sh; } SH2 ProjectOntoSH9Color(const glm::vec3& dir, const glm::vec3& color) { SH2 sh = ProjectOntoSH9(dir); SH2 shColor; shColor.coef0 = color * sh.coef0.x; shColor.coef1 = color * sh.coef1.x; shColor.coef2 = color * sh.coef2.x; shColor.coef3 = color * sh.coef3.x; shColor.coef4 = color * sh.coef4.x; shColor.coef5 = color * sh.coef5.x; shColor.coef6 = color * sh.coef6.x; shColor.coef7 = color * sh.coef7.x; shColor.coef8 = color * sh.coef8.x; return shColor; } void SHprojectHDRImage(const float* pixels, glm::ivec3 size, SH2& out) { double pixel_area = (2.0f * M_PI / size.x) * (M_PI / size.y); glm::vec3 color; float weightSum = 0.0f; for (unsigned int t = 0; t < size.y; t++) { float theta = M_PI * (t + 0.5f) / size.y; float weight = pixel_area * sin(theta); for (unsigned int p = 0; p < size.x; p++) { float phi = 2.0 * M_PI * (p + 0.5) / size.x; color = glm::make_vec3(&pixels[t * size.x + p]); glm::vec3 dir(sin(phi) * cos(theta), sin(phi) * sin(theta), cos(theta)); out += ProjectOntoSH9Color(dir, color) * weight; weightSum += weight; } } out.print(); out *= (4.0f * M_PI) / weightSum; }  
      outside of the SHProjectHDRImage function that's pretty much the code from MJP that you can check here:
      I'm not doing anything fancy in term of math or code but I that's my first time with those so I feel like I forgot something important.
      basically for every pixel on my equi-rectangular hdr map I generate a direction, get the colour and project it on the SH
      but strangely I endup with a SH looking like this:
      coef0: 1.42326 1.42326 1.42326
      coef1: -0.0727784 -0.0727848 -0.0727895
      coef2: -0.154357 -0.154357 -0.154356
      coef3: 0.0538229 0.0537928 0.0537615
      coef4: -0.0914876 -0.0914385 -0.0913899
      coef5: 0.0482638 0.0482385 0.0482151
      coef6: 0.0531449 0.0531443 0.0531443
      coef7: -0.134459 -0.134402 -0.134345
      coef8: -0.413949 -0.413989 -0.414021
      with the HDR map "Ditch River" from this web page http://www.hdrlabs.com/sibl/archive.html
      but I also get grayscale on the 6 other hdr maps I tried from hdr heaven, it's just different gray.
      If anyone have any clue that would be really welcome.
    • By FonzTech
      Hi! I have a doubt about making a "Room" manager. For "room", I mean a collection of game objects (in detail, I would say "a collection of subclasses of GameObject"), with their own properties (position, rotation, scale and other specific ones).
      For now, I only want to load a "room" from an external file, then instantiate and setup game objects based on its data.
      I thought about making a simple text file, containing a big structure like an array, where each entry, contains the class to be instantiated (along with their properties).
      I'm not very skilled in C++. In Java, I would load classes by their name using reflection (Take the security thing apart, for now), then set their properties (always using reflection), based on the data contained in the above text file.
      Think like a JSON, where you have a structure like this:
      [ { "type": "Player", "general": { "position": "1,2,3", "rotation": "1,2,3", "scale": "1,2,3" } "specific": { "someSubclassField": "myValue", "anotherPlayerField": "myValue2" } }, { "type": "MainMenu", "general": { "position": "0,0,0", "rotation": "0,0,0", "scale": "1,1,1" } "specific": { "isLevelEditorEnabled": true } } ] There is some mechanism I can adopt to avoid setting-up game objects at compile-time?
      I would like to avoid the myriad of if statements.
      Any advice is appreciated. Thanks in advance!
    • By Dimitri Lozovoy
      The mobile editor for Voxyc, a voxel-focused open-source game engine in development, can now edit 3D scenes on Android. Right in the app, you can create voxel chunks and combine them with models and sprites. You can import files right from the menu and then assign textures, move and resize them with a few button presses. All imported objects can be animated with Lua scripts. The resulting scenes can be used in games created with Voxyc, but since the project is open-source, export to other formats and engines can be and are expected to be developed.
      The app is one of the first that allows level creation on the go. You can work wherever inspiration strikes. Any dull moment can now be used productively, which is important for small indie teams that lack resources or work after-hours or on weekends. Using your device's camera to make textures and inserting them right into the scene is also convenient. The app is aimed at people who work on games independently and, perhaps after having already spent hours at their desk job, do not wish to be tied down to a chair and monitor. I find that using the app on a tablet is most convenient.
      Although the engine and the editor have come a long way in the last year, at this time, I am the only developer on the project. The editor and the engine are still missing some essential features, and I am looking for developers with whom I can share code. The codebase is cross-platform C++ and target platforms are Android, iOS, Windows, Mac, OpenVR, GearVR, Daydream and others.
      Voxyc editor for Android on Google Play
      Engine source code on GitHub
      Gamedev project link

      View full story

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!