Archive for the 'Gamedev' CategoryPage 3 of 3

Web Dev and Update

This is just a fairly brief update. I’ve finished the huge assignment… that’s out of the way. I’ve started working on a website for the developer of a quite cool game, will post when I’ve finished.

Also I have a long running shopping system to work on, I really want to get it out of the way.

Hopefully I can squeeze some time into voodoo this break… I’ve done everything (for now) that’s required for uni.

Update on delegates:

The delegates themselves can subclass other delegates but states can only have a delegate as a parent, and so can only be one class deep. I think this is the way it’s going to stay, but I can’t help wondering if states need to be passed down the hierarchy. If you subclass ’switch’ and created a new switch that requires two calls to toggle to change states, you will probably want to reason about what state a generic ’switch’ is in wether or not it’s a ‘double switch’ or a normal one. The current way to do this is to have a method that returns a boolean or something similar depending on what state it’s in. States could become mandatory to implement as you go down the classes - every switch needs an on and off state. But then this gets annoying, because you might not want to have to implement the states.

The way I’m going to program with this language is to have shallow class hierarchies so it shouldn’t be too much of a problem.

I think that a ‘delegate’ is the entrance point, you never really deal directly with the states. A delegate is a class that can have different functionality.

For when I start work on the parser / compiler… would it be an error to create a container (variable) that can only hold one specific state? I’m having trouble figuring out a situation where that would be good. So for the moment… no, only delegate containers.

Keyboad Input

tap R

  • clip weapons
  • if there is a fuller clip in inventory, remove the current clip and swap with the fullest.
  • individual bullet weapons
  • load one bullet into the weapon.

double tap R

  • clip weapons
  • a faster reload, if there is a fuller clip in inventory, drop the current clip on the ground and reload with the other clip.
  • individual bullet weapons
  • perform a different reload animation, perhaps longer but cooler looking.

hold R

  • clip weapons
  • remove the current clip and swap with the fullest clip in inventory, then start filling it up with individual bullets, if run out start taking bullets from the smallest clip
  • continue holding R
    • 3 sec delay
    • start filling up the next fullest clip with bullets, then the next etc.
    • 3 sec delay
    • start taking bullets of the same type out of other weapon clips and filling the current weapon clips.
  • individual bullet weapons
  • continue filling the weapon with bullets until finished

hold a directional key

  • move in that direction continue to aim forwards.

hold a directional key when movement in that direction is blocked by an object

  • use the object as cover, pressing a direction along the object as well will move in that direction while keeping cover. If you get to a corner you will peek out first before moving around. If you are pressing against an obstacle, you will lean on it with your back. If it’s a low wall that you can peak over, press the forwards key to press against the wall and position to shoot over it, crouch will hide out of the way.
  • ie, forward + crouch = out of sight
    let go of crouch = canshoot
    let go of forward and crouch = stand
    let go of forward = normal crouch stance

double tap forwards

  • start sprinting in that direction, left and right can be used to strafe a bit, but backwards cannot be used. As long as a movement key is held down (not including the backwards key) you will continue sprinting

hold a direction then tap space

  • perform a small jump or leap in that direction

hold a direction then hold space

  • power up for a big jump or dive
  • release space
    • do a large jump in the direction running

hold a direction then double tap space

  • perform a dive in that direction

hold a direction then crouch

  • perform a roll (male) or cartwheel (female) … I’m a stereotypical sexist

hold a direction then double tap space then hold crouch

  • perform a dive then a roll when hit the ground to get back up on your feet

standing still and tap space

  • jump on the spot - it there is a ledge above try to grab it

standing still and hold space

  • power up for a big jump or dive
  • release space
    • if a direction is held, do a large dive in that direction, otherwise do a large jump on the spot. Same roll option as for the normal dive

standing still and hold crouch

  • go into crouch stance
  • relase crouch
    • stand

double tap crouch

  • go into floor mode - all movement is with the whole body on the ground shuffling etc.

from ground hold crouch

  • go into crouch
  • release
    • go to stand

from ground tap crouch

  • stand

from ground press space

  • stand

direction keys while on ground

  • depending on orientation, shuffle forward, backwards or roll to the sides shuffling forwards can rotate the body a little.

holding action while a single item is available

  • move to and pick up the object

executing a roll or a dive while holding action

  • attempt to pick up a nearby weapon at certain orientations during the dive and roll

holding action when a door or moveable device is available

  • grap the device with one hand, moving the view in a certain directions will interact with the device
  • lever = up down, door = left right etc.
  • in some situations you will also have to move release lets the device go

holding action when a ledge is nearby or available

  • attempt to grab the ledge
  • release action drops from the ledge
  • up is pull yourself up onto the ledge
  • down is drop
  • left and right move in that direction along the ledge
  • view is partially restricted

holding action when a ladder is nearby or available

  • attempt to grab the ladder
  • release action drops from the ladder
  • up is climb the ladder
  • down is decend
  • left and right move in that direction while still holding the ladder
  • view is partially restricted
  • one handed weapons only, even then climbing is slower
  • weapons are put away by default, unless they are being used, or have been shot in the last few seconds

A little note

Before I continue much more, I have to mention an awesome site that I visit a lot. Gamedev.net is great. The tutorials and articles are mixed, some of them are great others not so - but the great thing that this site has is it’s forum. It’s a great place to bounce ideas around, find out what other like minded game developers are doing and generally have fun.

I’m not heavily active on the forum, but I have started a few threads and had some good discussions. There are a lot of impressive people that are regulars and have a lot of knowledge.