Feedback wanted for my top down shooter

0 favourites
  • 6 posts
From the Asset Store
Make your own spaceship game with this fully customizable set.
  • Hey everybody!

    I'm working on a remix of the old, old, old game Gain Ground.

    I've more or less got the mechanics sorted. You pick a character from the right hand side. Each character has 2 attacks depending on the mouse button pressed.

    Getting all your characters to the exit, or killing all the enemies takes you to the next level.

    If a character is taken out, you can recover their downed state and if you make it to the exit,they will revive for the next map.

    The challenge I'm facing is how to organise all the different characters.

    So far I've set up an array table. This state each characters current state. So far that is working for me.

    However, each character will have different attacks and abilities. So whilst one will fire a long range missile, another will throw a grenade which can hit high up enemies - and so on.

    Is it best to also log this info as an array? So if a character has a 1 for alive, then replace the projectile with that sprite?

    Or is there a better method? (I hope that makes sense!)

    Download file is here

  • I don't really understand why you are using arrays, but if I understood the general gist of your game, you don't need them at all.

    If you have only two skills per character, and each skill can be easily defined by a single function, why not just check which character is the current one through a simple string variable, and then choose the first or second function based on a mouse input?

    Hope it helps, but feel free to further the discussion.

    Cheers.

  • So I have an array keeping track of something like this:

    Player Alive Dead Wounded
    P1 1 0 0
    P2 0 0 1

    I thought then have a column which would be checked and would then generate a specific sprite based on that.

    This then makes characters selectable based on their availability.

    So are you suggesting variables for each character? So P1alive, P1Dead, P1Wounded etc?

    And I don;t really get the 2nd bit - sorry!

    At the moment I've got:

    Mouse ->On left button clicked -> Spawn bullet on layer 0

    But I want to have different weapons, so maybe a flame or a bigger bullet.

    Thanks for your help!

  • So I'm running this which I think/hope is what you meant?

    Is this a cleaner way to arrange everything?

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • You mentioned you were having trouble organizing the different characters state. I'd recommend using JSONs, they are pretty useful and equally practical to use.

    There are some good tutorials out there, but mainly what you need to know is to request the AJAX object to load a JSON file and then put it into a JSON object once it is finished loading.

    Although if the information you're storing is only strings and numbers, you might as well just use variables (globals or instanceds) which are even more simple to use.

    The second thing I mentioned is that you don't really need data storage for defining which skill a character would use if there are only 2 skills. It is easily solvable by, for example, 2 string instance variables with each skill name. This name could also be used to call a function that handles everything the skill does, e.g. shooting bullets.

  • God googling JSONs just broke my head!

    Oooooh I think that Functions will hit the spot tho!

    Thank you so much for the help, it was really appreciated :)

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)