Setting up a complex skills system?

Get help using Construct 2

Post » Wed Dec 18, 2013 12:21 am

In my game, "Psi," my player has a basic attack and, by the end, about 10 different skills available. I am wanting to have three power levels for each skill that the player selectively levels up. I am also wanting three selectable attack buttons that the player can assign whichever powers they want to. Do I need to separate all of these things I want to do or can I address all of them at once? What is the best way to handle powers that get leveled up selectively? Thank you!
Image
B
20
S
4
Posts: 382
Reputation: 2,974

Post » Wed Dec 18, 2013 2:01 am

There are many ways you can do this and the best option depends on your game design.

You must tell us first what is your PSI game all about. Is it platformer, top down shooter or what, then we can respond more appropriately.

I will give you a simple example for flying shooter case:

- create a global variable called "weapon" as numbers.

- in event sheet, in your key press event (for example "press Spacebar") , have the following events:
- - if global variable is 1, create instance of object Bullet at player's sprite
- - if global variable is 2, create instance of object Laser at player's sprite.
- - if global variable is 3, create instance of object Bomb at player's sprite.

The above is simple event to handle a ship having multiple weapons but only one can be used at a time.

Should you want to use a different weapon, you might perhaps use an event like this:

- if keyboard key 1 is pressed, set global variable "weapon" to 1.
- if keyboard key 2 is pressed, set global variable "weapon" to 2.
- if keyboard key 3 is pressed, set global variable "weapon" to 3.

Now with this, the player can select weapon with a key press of 1,2, or 3, and fire respective weapon with spacebar.

If you understand all above, proceed. Else please say so that you still need assistance and we could assist you further.

Now, if you understand all above, you probably have a general idea with simple weapon switching mechanic in event sheet right now. This could be done similarly with skills in your game.

To do the remaining thing, such as "unlockable skill", "player using skill in specified button", "mapping skill to specified button", "power levels in skills", etc. ,these could be a little challenging if you never play around with programming before.

On the basic level, if you understand why do we have variables, and how to use them in the events, you could simply use number variables for simple indexing to refer to each skill like I did above.

But before I say anything else, tell me first, what is your game genre and what are your character's behaviors for each skill. Because if we dont have more info, we will not be able to assist you in finer details. As of now, I can only provide you with a rather very general idea of weapon/skill implementation above, which might not be able to answer to what you really wanted.

Also add my name "@keroberos" in your next reply so I can see if you need further assistance.
I got a game that you multiply, breath fire with two heads and brawl foes to oblivion with your clones: http://www.newgrounds.com/portal/view/660664 (use Chrome on Windows for best performance)

My sites:
http://twinblazar.deviantart.com
http://twinblazar.newgrounds.com
https://twitter.com/twinblazar
http://www.pixiv.net/member.php?id=15072448
B
30
S
11
G
11
Posts: 411
Reputation: 8,469

Post » Wed Dec 18, 2013 3:36 pm

Thank you very much, @keroberos. "Psi" is basically a beat 'em up about a woman with psionic (mental) powers in a future world infested with zombies and killer machines. Here is a picture example of the basic layout (I am using test characters right now):



As I said, I want to make touch controls and I'd like to have a virtual joystick and 3 separate attack buttons--one to be used for her basic attack (of which there are 2 options) and the other 2 would be from her store of abilities of which there would be more or less, depending on how far the player has progressed in the game. Some of her skills would be offensive, range attacks and some would be defensive. I would like the player to, at least, be able to swap out skills between levels or maybe even on the fly so I, of course, don't know how to do any of that yet.

Once again, thanks for your help.
Image
B
20
S
4
Posts: 382
Reputation: 2,974

Post » Thu Dec 19, 2013 12:42 am

You want a virtual joystick for a beat'em up game on touch screen? Hmm...perhaps you may wish to watch this first: https://www.youtube.com/watch?v=9eW7Rt18H0M&feature=youtube_gdata_player

Now, before continue making assets for your game, let's go back to the brainstorm phase, and ask yourself the following questions:

1. What could be better ways to have player play beat em up game on touch screen? I'm not saying it's not possible but you better think about controls scheme and how overall experience should be. Beat em up games are heavily tied with arcade stick back in the days so imagine tapping non-stop when you punch enemies? Would that give you the same sensation with arcade buttons? You are literally ramming buttons when you are beating the crap out of your enemies. But on touch screen, without physical feedback like physical buttons, ...it won't feel right.

2. Can you use something other than touch screen? Or alternatively, could you have some type of gameplay that is more suitable for touch screen?

Please consider these two big pictures before proceeding further or you will be in a world of hurt.keroberos2013-12-19 01:31:46
I got a game that you multiply, breath fire with two heads and brawl foes to oblivion with your clones: http://www.newgrounds.com/portal/view/660664 (use Chrome on Windows for best performance)

My sites:
http://twinblazar.deviantart.com
http://twinblazar.newgrounds.com
https://twitter.com/twinblazar
http://www.pixiv.net/member.php?id=15072448
B
30
S
11
G
11
Posts: 411
Reputation: 8,469

Post » Thu Dec 19, 2013 3:17 am

Hello guys!
What a lovely question :D Was not going to make a complete example,
but decided that it might be interesting to do:)
At first I thought I know exactly how to implement a simple skill system.
Then I've tried to prototype it.. Well, turned out that it was a real challenge. Finally got it running :D
Not the most ellegant solution, overcomplicated I guess,
and I have no time to comment or fix it now, but..here it is. DEMO here.
Guess it's a kind of a generic skill/technology system.
Might be hard to understand, so feel free to ask any questions,
I'll answer as soon as possible. Also I'll try to polish it later and comment the capx.
But till then.. Have fun reverse-engineering:P
I hope it helps your game,PSI, your screenshots look great:)

P.S. think I'll make a little tutorial if I manage to simplify the code)
Sincerely,
GeorgeJJList2013-12-19 03:23:35
B
18
S
5
G
1
Posts: 74
Reputation: 2,672

Post » Thu Dec 19, 2013 4:03 am

@keroberos, technically, it's a ranged beat 'em up. It really just shares the same layout as a beat 'em up, with false 3d perspective. I play beat 'em ups on my tablets all of the time and enjoy them so I know it can be implemented properly.
Image
B
20
S
4
Posts: 382
Reputation: 2,974

Post » Thu Dec 19, 2013 4:05 am

@JJList. Hey George, thanks for sharing! That looks like exactly what I'm looking for. How much coding did you have to do to get to this point? I will study this and try to wrap my newbie brain around it. More questions forthcoming, I'm sure!
PSI2013-12-19 04:18:03
Image
B
20
S
4
Posts: 382
Reputation: 2,974

Post » Thu Dec 19, 2013 10:55 am

@PSI name me one of the beat em up games you enjoyed on tablet please.
I got a game that you multiply, breath fire with two heads and brawl foes to oblivion with your clones: http://www.newgrounds.com/portal/view/660664 (use Chrome on Windows for best performance)

My sites:
http://twinblazar.deviantart.com
http://twinblazar.newgrounds.com
https://twitter.com/twinblazar
http://www.pixiv.net/member.php?id=15072448
B
30
S
11
G
11
Posts: 411
Reputation: 8,469

Post » Thu Dec 19, 2013 11:25 am

@jjlist your demo doesnt run on my smartphone's stock browser and chrome. Mind fix it for PSI? Thanks. I'll let you take it from here.
I got a game that you multiply, breath fire with two heads and brawl foes to oblivion with your clones: http://www.newgrounds.com/portal/view/660664 (use Chrome on Windows for best performance)

My sites:
http://twinblazar.deviantart.com
http://twinblazar.newgrounds.com
https://twitter.com/twinblazar
http://www.pixiv.net/member.php?id=15072448
B
30
S
11
G
11
Posts: 411
Reputation: 8,469

Post » Thu Dec 19, 2013 2:53 pm

@keroberos Oh yeah, it's not intended to run on mobile devices :) It is an idea of how to implement a skill system, not a complete solution on PSI's needs;)
B
18
S
5
G
1
Posts: 74
Reputation: 2,672

Next

Return to How do I....?

Who is online

Users browsing this forum: No registered users and 25 guests