Jump to content
  • Advertisement
  • entries
    18
  • comments
    16
  • views
    16245

Getting back to it

Gooey

967 views

I haven't been around alot recently due to my pc deciding not to work and time constraints but I am back! To get back in to it I decided to make a quick game me and my niece used to play with cards. The object of this game is to multiply the cards quickest and the winner gets the cards. Ok so after messing about for a day with it i have got a single player edition playable. Halfway.thumb.png.04500fb8b1fdbaa3f7dfb918af23f25e.png

 

It is not anything pretty by any means but it was a good way to get back into the swing of things. I will add options to it so you can choose the highest card 1-13 and how many decks of them cards. I would like to also make some sort of nice win screen too as at the moment it just takes you back to the Play/Exit screen.



8 Comments


Recommended Comments

Errm hadn't really thought about it didn't realise anyone would like to play it

Share this comment


Link to comment
1 hour ago, Gooey said:

Errm hadn't really thought about it didn't realise anyone would like to play it

I will certainly play it if you make a download for it. :) 

Share this comment


Link to comment

Id be curious to know how you implemented the text, I've been googling around trying to figure out a quick and easy way to get text working.

Share this comment


Link to comment
On 11/13/2018 at 2:55 PM, Gooey said:

didn't realise anyone would like to play it

I'd play it! :D 

Share this comment


Link to comment

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
  • What is your GameDev Story?

    In 2019 we are celebrating 20 years of GameDev.net! Share your GameDev Story with us.

    (You must login to your GameDev.net account.)

  • Blog Entries

  • Similar Content

    • By Tomtheseadog
      Hey guys,
      I'm having a little trouble with my point light. My light is working but the light source moves when I move my camera. I've been trying all week to fix it but at my wits end. Maybe I haven't converted it to the proper space.
      **VERTEX SHADER**
      in vec3 positions;
      in vec2 texCoords;
      in vec3 normals;
      out vec2 pass_texCoords;
      out vec3 mvVertexNormal;
      out vec3 mvVertexPosition;
      uniform mat4 projectionMatrix;
      uniform mat4 modelViewMatrix;
      uniform mat4 normalMatrix;
      void main()
      {
      pass_texCoords = texCoords;
      vec4 mvPos = modelViewMatrix * vec4(positions, 1.0);
      mvVertexNormal = mat3(normalMatrix) * normals;
      mvVertexPosition = vec3(modelViewMatrix * vec4(positions, 1.0));
      gl_Position = projectionMatrix * mvPos;
      }
      **FRAGMENT SHADER**
      in vec2 pass_texCoords;
      in vec3 mvVertexPosition;
      in vec3 mvVertexNormal;
      out vec4 out_colour;
      struct Material
      {
          int hasNormalMap;
          int hasTexture;
          vec3 diffuse;
          vec3 ambient;
          vec3 specular;
          float reflectivity;
      };
      struct PointLight
      {
          vec3 position;
          vec3 colour;
          float intensity;
      };    
      uniform sampler2D our_texture;
      uniform Material material;
      uniform vec3 ambientLight;
      uniform float specularPower;
      uniform PointLight pointLight;
      uniform vec3 viewer_position;
      vec4 calculateLight(PointLight light, Material material, vec3 position, vec3 normal)
      {
      // AMBIENT
      vec3 ambient = ambientLight * light.colour;
      // DIFFUSE
      vec3 norm = normalize(normal);
      vec3 lightDir = normalize(light.position - position);
      float diff = max(dot(norm, lightDir), 0.0);
      vec3 diffuse = diff * light.colour;  
      // SPECULAR
      vec3 viewDir = normalize(viewer_position - position);
      vec3 reflectDir = reflect(-lightDir, norm);
      float spec = pow(max(dot(viewDir, reflectDir), 0.0), 32);
      vec3 specular = specularPower * spec * light.colour;
      vec3 result = (ambient + diffuse + specular);
      return vec4(result, 1.0);
      }
      void main()
      {
      vec4 lightResult = calculateLight(pointLight, material, mvVertexPosition, mvVertexNormal);
      out_colour = texture(our_texture, pass_texCoords) * lightResult;
      }
       
      The light source is coming from the cube in the red circle. Even the first picture the light isnt directly under the cube. If I don't move my camera and have the cube light source move around automatically the the light will stay with it. It's only if I move the camera that I get problems. The second picture i've moved my camera to the left and the light is moving with me and moving away from the cube light source.


    • By iradicator
      I'm adding shadow volume support into my engine (graphics backend written in OpenGL 4.5).

      Depth Pass was working fine and to deal with shadows when the camera placed inside a shadow volume - I've decided to use Carmack's Reverse (Depth Fail).

      I'm getting weird errors and I wanted to make sure I'm working with a good model (I'm using the Stanford Bunny / Dragon) before I continue to debug my algorithm.

      Depth Pass (working fine):


      Depth Fail (artifacts):


      I then positioned the camera inside the bunny and realized that the artifacts are actually triangles that aren't being culled (they facing the camera and the light source so they shouldn't be culled):
      Note: The bunny in this picture is the 2nd bunny behind the one in the previous picture - the camera is inside the first bunny in the picture above!


      I added a simple geom shader to paint front faces in green and back faces in blue. As you can see, This "patch" looks weird as some of the triangles facing the camera and some facing away from it - which might explain the artifact...


      Maybe the model is incorrect? I'm adding here the gltf I'm using (Bunny.gltf).
      Bunny.gltf

      I'm using silhouette extrusion to calculate the shadow volumes. I calculate the silhouette by using adjacency triangle toplogy (I'm calculating it once when loading the model) - and find edges that go around the light facing triangles (I'm using face normals for this calculation - I found it to yield better results then interpolated model normals). Would love to hear your thoughts about this method.

      Thank you for your help!
    • By Uttam Kushwah
      Hello everyone i am trying to make some simpleton game but having trouble with bullet objects behavior.
      in my game scene there is terrain shape for open world(which are nasty for now) and i am shooting some balls to check how terrain is doing. But some balls hit 
      the terrain and some phase through so i don't know what to do or where exactly to dig.
       
      you can see the problem here 
      i know video quality is bad but bare it for now please i still newbie for uploading.
      i guess you will get some clue what i am going through.
      Thanks in advance.
       
    • By pindrought
      I have a few questions regarding using UDP in C++.
       
      Since UDP is connectionless, is there any reason for a UDP server to have more than one socket created? Let's assume you are running two programs on your pc that both use UDP. Program A and program B. What is stopping program A from reading all of the packets that are intended for program B to receive before program B can read them? Is it just the specific port that is originally used when the socket is bound? If this is the case, how can you run multiple instances of a game that uses UDP if they are all set up to use the same designated port? For TCP, if you want to host a server you have to open ports through your router for the port your server will use for listening. Is this not required for UDP since no actual connection exists? If it is not required, why is there an option to forward ports for UDP in router configurations?
    • By Josheir
      This question concerns OpenGL.  I have found some code for checking the y value with a grid to place an object on a mesh (a type of collision detection).  However, I want to check the height over and over again to change the velocity of the ball depending on the height of the changing y value.  How do I repeatedly check every height, or is there a different way?  I'm using C++.
      Thanks,
      Josheir
×

Important Information

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

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!