Jump to content
  • Advertisement

Calsmurf2904

Member
  • Content Count

    29
  • Joined

  • Last visited

Community Reputation

122 Neutral

About Calsmurf2904

  • Rank
    Member
  1. Title: Block Shift (Android) Target: Android (maybe iOS in the future) Hello all, A friend and I have been working on a project in the past two weeks, and we would like to invite everyone on GameDev.net to be a part of our beta test! The game is called Block Shift. It is a 2d puzzle game, in which you "shift" blocks from the side of the screen to their designated place which can be seen on the minimap. It is going to be a free game, with in-game advertising. We are aware that the game has a couple of bugs (such as odd animations), we felt these bugs weren't serious enough to remedy straight away. Rest assured, we will fix these before the release on the Android Marketplace. This is going to be our first release, and we are very excited. What we would like from you: Feedback and criticism! We would like to know what you think of the game. Also, any weird crashes or bug reports are appreciated. If the game doesn't work on your phone, please let us know! The game is currently lacking sound, and we are still looking for a sound artist. (Anyone ? ) Download Link (to be opened on any device with Android (game is currently optimized for 800x480 resolution)): http://www.doublebluffstudios.com/Blockshift/Blockshift.apk The game currently also contains OpenFeint integration with achievements and high scores. The team-website is still a work in progress. We're learning on the go. Thanks Calvin and Kevin Double Bluff Studios Known Bugs: It doesn't save map progress yet. For some reason it appears to have rendering bugs only on the Samsung Galaxy S, the S2 doesn't have this problem. Screenshots: http://www.doubleblu...ift/screen1.png http://www.doubleblu...ift/screen2.png http://www.doubleblu...ift/screen3.png http://www.doubleblu...ift/screen4.png http://www.doubleblu...ift/screen5.png http://www.doubleblu...ift/screen6.png
  2. Calsmurf2904

    Some issues

    anyone?
  3. Calsmurf2904

    Some issues

    ok...finally got it running by disabling VBO and using Vertex Arrays instead. However there still isn't anything drawn to the screen. This is my initialisation code : Quote: PXMesh* mMesh = mRoot->createMesh("ProjectXTestMesh.PX"); mMesh->getVertexBuffer()->addVertex(PXVector4(0.0f,1.0f,0.0f,PXColor(100,100,100,1))); mMesh->getVertexBuffer()->addVertex(PXVector4(-1.0f,-1.0f,0.0f,PXColor(100,100,100,1))); mMesh->getVertexBuffer()->addVertex(PXVector4(1.0f,-1.0f,0.0f,PXColor(100,100,100,1))); and then the code to draw it : Quote: glEnableClientState(GL_VERTEX_ARRAY); glEnableClientState(GL_COLOR_ARRAY); VVertexBuffer::iterator mIt = mBuffers.begin(); int Vertexes = 0; for(mIt = mBuffers.begin();mIt != mBuffers.end();++mIt) { glVertexPointer(3,GL_FLOAT,sizeof(PXVertex),&(*mIt)->getVertexArray()); glColorPointer(3,GL_FLOAT,sizeof(PXVertex),&(*mIt)->getVertexArray().at(0).r); Vertexes += (*mIt)->getTotalVertexes(); }; glDrawArrays(GL_TRIANGLES,0,Vertexes); glDisableClientState(GL_VERTEX_ARRAY); glDisableClientState(GL_COLOR_ARRAY);
  4. Calsmurf2904

    Some issues

    Okay fixed the issues...I can now succesfully compile it :) However there is a new access violation. The access violation this time is in this code : totalBuffers++; mBuffers.resize(totalBuffers); mBuffers.push_back(mVertexBuffer); GLuint BufferIds2[1] = {0}; glGenBuffers(1,BufferIds2); //VertexBuffer <-------- There BufferIds[totalBuffersId+1] = BufferIds2[0]; glGenBuffers(1,BufferIds2); //ColorBuffer BufferIds[totalBuffersId+2] = BufferIds2[0]; totalBuffersId++; totalBuffersId++; This code is to add the vertex buffer to the vector. I thought then I need to generate the VBO's here. So when I try to generate them it gives me : Quote: Access violation reading location 0x00000000
  5. Calsmurf2904

    Some issues

    still getting it :( This is my current code : VVertexBuffer::iterator mIt = mBuffers.begin(); for(mIt = mBuffers.begin();mIt != mBuffers.end();++mIt) { glBegin(GL_TRIANGLES); VVertex::iterator mIt2 = (*mIt)->getBeginIterator(); for(mIt2 = (*mIt)->getBeginIterator();mIt2 != (*mIt)->getEndIterator();++mIt2) { float x,y,z,r,g,b,a; PXVertex* mVertex = *mIt2; x = mVertex->getX(); y = mVertex->getY(); z = mVertex->getZ(); r = mVertex->getColor().getR(); g = mVertex->getColor().getG(); b = mVertex->getColor().getB(); a = mVertex->getColor().getA(); glColor4f(r,g,b,a); glVertex3f(x,y,z); }; glEnd(); }; I am starting to think that the error is in the addVertex code. Edit: Okay....I am looking into some other more optimized methods for rendering. I am thinking about using VBO's to draw the vertexes. However would it be possible to copy the vector as a array to the vbo ? Here: http://www.ozone3d.net/tutorials/opengl_vbo_p2.php they use a simple array of static GLFloat's. Would it be use instead of a array of GLFloat's a vector ? Edit2: Created a test code : int vertexes = 0; VVertexBuffer::iterator mIt = mBuffers.begin(); for(mIt = mBuffers.begin();mIt != mBuffers.end();++mIt) { glBindBuffer(GL_ARRAY_BUFFER,(*mIt)->VBOVertexId); glBufferData(GL_ARRAY_BUFFER,(*mIt)->getTotalVertexes()*sizeof((*mIt)->getVertexArray()),(*mIt)->getVertexArray(),GL_DYNAMIC_DRAW); glVertexPointer(3,GL_FLOAT,sizeof(PXVertex),0); glBindBuffer(GL_ARRAY_BUFFER,(*mIt)->VBOColorId); glBufferData(GL_ARRAY_BUFFER,(*mIt)->getTotalVertexes()*sizeof((*mIt)->createColorArray()),(*mIt)->createColorArray(),GL_DYNAMIC_DRAW); glColorPointer(4,GL_FLOAT,sizeof(PXColor),0); vertexes += (*mIt)->getTotalVertexes(); }; glEnableClientState(GL_VERTEX_ARRAY); glEnableClientState(GL_COLOR_ARRAY); glDrawArrays(GL_TRIANGLES,0,vertexes); glDisableClientState(GL_COLOR_ARRAY); glDisableClientState(GL_VERTEX_ARRAY); Here are the problems with this code : It keeps complaining that GL_ARRAY_BUFFER and GL_DYNAMIC_DRAW is undefined. It also keeps saying that glBindBuffer and glBufferData doesn't exist. What am I doing wrong ? I am using Visual C++ 2008 sp1 on Windows (Kinda obvious). Edit3: Okay....added glew 1.5.1 and the errors are now gone (well....new errors appeared lol). Trying to fix them now....will post here later with the result. [Edited by - Calsmurf2904 on November 21, 2008 11:28:25 AM]
  6. Calsmurf2904

    OpenGL Some issues

    Hello, Its a long time since my last post here. I am creating a Game in the Ogre engine and when I am on the pc that is too slow to program with Ogre then I am learning OpenGL. This is my issue : I have two classes called PXVertex and PXVertexBuffer. PXVertexBuffer has a std::Vector that contains PXVertex objects. The main problem is that when I am trying to draw the buffer is keeps giving me Access Violation at 0x00000000. This is my current Code : Adding vertex to buffer void PXVertexBuffer::addVertex(PXVector mVec) { if((mVertexes.size() + 1) > mVertexes.capacity()) { totalVertexes++; mVertexes.resize(totalVertexes); } mVertexes.push_back(new PXVertex(mVec.getX(),mVec.getY(),mVec.getZ(),mVec.getColor())); }; Retrieving vertex from buffer PXVertex* PXVertexBuffer::getVertex(int id) { return mVertexes.at(id); }; Drawing Vertexes bool _Update() { glClear(GL_COLOR_BUFFER_BIT|GL_DEPTH_BUFFER_BIT); glLoadIdentity(); glTranslatef(-1.5f,0.0f,-6.0f); int i = 1; int i2 = 1; VVertexBuffer::iterator mIt = mBuffers.begin(); while(mIt != mBuffers.end()) { glBegin(GL_TRIANGLES); VVertex::iterator mIt2 = mBuffers.at(i)->getBeginIterator(); i2 = 0; for(mIt2 = mBuffers.at(i)->getBeginIterator();mIt2 != mBuffers.at(i)->getEndIterator();++mIt2) { float x,y,z; PXVertex* mVertex = *mIt2; x = mVertex->getX(); y = mVertex->getY(); z = mVertex->getZ(); glVertex3f(x,y,z); mIt2++; i2++; }; glEnd(); mIt++; i++; }; if(!_UpdateRenderWindows()) return false; return true; }; The buffers are placed in a vector of PXVertexBuffer objects. The vector variable is named mBuffers. The problem is in mVertex->getX()/Y/Z; One more thing : How can I color the vertex ? I thought glColor4f(r,g,b,a); but I am not sure.
  7. Calsmurf2904

    Game Engine VS OpenGL or DirectX

    ok...i decided to try crystalspace again... Currently building...if any error occur i will post here.
  8. Calsmurf2904

    Game Engine VS OpenGL or DirectX

    Quote:Original post by jpetrie Read this. Especially if your C++ isn't that great, trying to roll your own codebase -- even to the scale of Irrlicht -- won't turn out well. You'll likely end up with something less useful. Why doesn't Irrlicht fit your needs? Why can't you extend it? The source is available, for example. And if you can't comprehend that code then you either don't have a suitable enough understanding of how Irrlicht works to really be making the "it doesn't fit my needs" assertion (most likely) or you certainly don't possess the requisite experience to rebuild something on its level (so again, rolling your own thing is probably right out). What are you needs for framework code? I got irrlicht to work and i understand how it works etc. CrystalSpace has everything i need except that i couldn't get it to work and it has very weird tutorials. I would like something like CEL (Crystalspace Entity Layer) in a engine. Maybe someone could point me to some good tutorials about Crystalspace with CEL.
  9. Hello, I am using the irrlicht engine now for about 2 months but it doesn't fit any of my needs and I want to be able to extend it. So i was thinking of creating my own engine for my game that fits my needs in OpenGL or DirectX (and Ode or Newton). But what would be better ? Another engine (I also tried CrystalSpace but i couldn't set it up on VC++ 2008) or Creating my own engine ? (Please keep in mind that my programming skills in C++ aren't that great) If I choose to create my own engine what would be better : OpenGL or DirectX ? I think opengl would be better because its cross platform. Please give me your opinion about this ! Thanks in advance, Calsmurf2904
  10. Calsmurf2904

    2D games?

    I started with the basic console tutorials on http://www.cplusplus.com/ and then I followed the irrlicht tutorials for GUI Programming (Still learning that)...i am currently also looking into the Winsock tutorial from this site.You can get alot of free tutorials arround here.
  11. Calsmurf2904

    startThread : Identifier not found (winsock)

    ok...thanks for your help !! I will ask questions later if i have them but for now my questions are all answered ! Thank You !
  12. Calsmurf2904

    startThread : Identifier not found (winsock)

    so : ..... Removed code before this line ..... }else if(msg == 0){ PlayerDisconnected(PlayerId); }else if(msg == SOCKET_ERROR && WSAGetLastError() != WSAEWOULDBLOCK) { PlayerDisconnected(PlayerId); } would do it ?
  13. Calsmurf2904

    startThread : Identifier not found (winsock)

    Figured it out : ULONG nonblock = 1; ioctlsocket(SERVER_SOCKET,FIONBIO,&nonblock); It works great now...Next question ^^ : (I have lots of questions lol ^^) How can i know if the player disconnected ? I use the response from recv to check if it is the value 0 or SOCKET_ERROR but it is always this value if nothing is recieved so this doesn't work for it.
  14. Calsmurf2904

    startThread : Identifier not found (winsock)

    mmm....so i need to make it unblocking ? i couldn't find anything to do this....does anyone knows how ? In the winsock tutorials this isn't explained very well...only Blocking and Async non-blocking are explained.
  15. Calsmurf2904

    startThread : Identifier not found (winsock)

    New question ^^ Why does the program wait at the accept function until someone connects ?
  • 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!