Pokemon Style Fight

Get help using Construct 2

Post » Sun Apr 29, 2012 1:57 am

Hello my name is Baron first of all I love this program it is awesome it is what I have been looking for, for quite a bit of time. I am an artist that needed and easy way to bring my idea to fruition with little programing.

Also if anyone needs some art done, I have reasonable prices and I am a freelance artist, check out my portfolio - Click Here

Okay enough of that, I am trying to put together a Pokemon style fight scene and I am trying to start up the base part of it where I have a monster on one side and the Hero's pet on the other.

1st problem is that I want to pull in a random monster from a list of monsters -

2nd problem I want the monster to choose from a list of powers and then cast them on the Hero's pet.

I understand that I can call from a .txt file with a list of monsters and have it call from that list. I having trouble understanding how to call that list then telling the program the list. I understand I have to have a .txt file that lists the monsters and then a .txt file with the list of the monster along with it's powers that the names line up exactly. I just don't know how to call it.

Also I would like a little advice if this is a good way or would there be a better way. I am sorry if I have not explained it right, as said before I am an artist first and a programmer LAST haha.

The construct File - Click Save Asbarondzines2012-04-29 13:58:56
B
4
Posts: 12
Reputation: 499

Post » Sun Apr 29, 2012 3:15 am

Look, you posted a link it's wrong because .caproj is NOT proper compressed file.

Try to change it for .capx
B
96
S
25
G
20
Posts: 3,055
Reputation: 22,644

Post » Sun Apr 29, 2012 4:27 am

Im a little confused about the mention of a text file for doing what your trying to do.

What you can do instead is use the random action within C2.

It works like this;

-On condition met
   >Set local number which = 0
    Set floor(random(3))
        Which = 1 - spawn this monster
        Which = 2 - spawn that creature

This might not make sense to you right now.

GenkiGenga2012-04-29 04:28:10
ImageImage
B
74
S
17
G
6
Posts: 1,039
Reputation: 10,605

Post » Sun Apr 29, 2012 2:03 pm

Joannesalfa - Link fix it now contains a capx file.

GenkiGenga - So how do I link what your saying to the monster sprite? And what if I have 50 different sprites to choose from?
B
4
Posts: 12
Reputation: 499

Post » Mon Apr 30, 2012 3:27 pm

Hey guys I would love some help on this.
B
4
Posts: 12
Reputation: 499

Post » Mon Apr 30, 2012 7:48 pm

Here, take a look at this:

http://dl.dropbox.com/u/5143153/BattleDome-CallMonster.capx

I don't think you need a .txt file. Just use array or variables. Or if you really need use a .txt you can ask somebody to make a plugin. You can use PHP with Ajax too, but i think this is too much complicate just for this. I made a simple modification in your capx. Like GenkiGenga said, use random() to call a random number, and then create conditions:

-Var = 1
   > Monster_Spriter set animation to "MonsterName"

Of course, there are lot of variables you'll need to use. Just made this example to help you clarify your mind. I hope this is it what you looking for, sorry if i misunderstood.Zanuff2012-04-30 19:53:54
B
5
G
2
Posts: 16
Reputation: 1,187

Post » Mon Apr 30, 2012 8:15 pm

Zanuff - First of all thank you so much for the set up -

That is Kind of what I was looking for, so if I was using the array I would create variables with the same name as the sprites? and then set it to call a random sprite? am I seeing that right? or would I just continue on with the list you have for every monster I had?

also can I change it to instead of on click, to "on start of layout" so that way it automates it every time the screen starts up?

Baronbarondzines2012-04-30 20:16:07
B
4
Posts: 12
Reputation: 499

Post » Mon Apr 30, 2012 8:35 pm

   I'm glad i could help you!

Before i answer your question, do you know how to use array in Construct 2?

http://www.scirra.com/manual/108/array/page-1

I think for now you should stick with the list. When you are more experienced with C2, then you try to use arrays.
And if you check the .capx, you'll see that i put an action in the "on start of layout" of yours. If you refresh the page you'll see
the monster's sprite changing. I just put the "on clik" for better 'visualisation'.
B
5
G
2
Posts: 16
Reputation: 1,187

Post » Tue May 01, 2012 12:59 am

zanuff - yeah the array thing, I am lost on that

but I am understanding what you have done and working out how to change it up to do random selection, and adding in the variables thank you so much for help, I will post the file once I get a little further on it.

baronbarondzines2012-05-01 01:21:45
B
4
Posts: 12
Reputation: 499

Post » Tue May 01, 2012 2:01 am

For what you want to do, it's easier to use array, but let's stick to your 'guns' right now.
For what i understood, you want to each monster have a pack of abilities right?
Like, a Fire Lizard has the skills:1- Fire Ball, 2- Scratch, 3- Stun.
And an Ice Golem has: 1- Punch, 2- Ice Ball etc..

And, do you want this abilities for the enemies or just for the player?
The way it is now, you can do like that:

http://dl.dropbox.com/u/5143153/BattleDome-CallMonster-01.capx

You have to come with the logic behind the A.I from the enemies. But now you have base to start with.
B
5
G
2
Posts: 16
Reputation: 1,187

Next

Return to How do I....?

Who is online

Users browsing this forum: makkancs and 26 guests