Help with randomized images and advice on project

For questions about using Classic.

Post » Fri Aug 02, 2013 6:55 pm

So I'm working on a linear rogue-like, and for this I need the image in the center of the screen to change to one of 6 images every time the
onward" button is pressed. I'm not quite sure how to roll dice with construct, so I'm assuming I will need to use python for this, but I'm not really sure how to go about doing that.

The next thing is really more advice on how I should go about implementing items, turn based combat, and random events into the game. I want there to be like a 1 in 4 chance that an event will occur, such as a monster appearing, a merchant appearing, a chest appearing, ect. I have the game at a point where you can create a character and their stats will be displayed in the main screen.

https://docs.google.com/file/d/0B0gf0yi2MHX3Rzh6Z1VBOXhNUjg/edit?usp=sharing
B
7
S
2
G
1
Posts: 28
Reputation: 881

Post » Fri Aug 02, 2013 7:06 pm

Use variables, if global value chance 1 set image to 1.png, if global value chance 2 set image to 2.png, etc etc.

To get the random number, do something like 'on object clicked set global value chance random(6)
B
4
S
1
Posts: 14
Reputation: 430

Post » Fri Aug 02, 2013 7:10 pm

PS; here is a .CAP of what i mean|
https://www.dropbox.com/s/59ilug317s6yfod/randomnumbers.cap
B
4
S
1
Posts: 14
Reputation: 430

Post » Mon Aug 05, 2013 5:05 am

https://docs.google.com/file/d/0B0gf0yi2MHX3VmphandwSGxSV00/edit?usp=sharing

So I got that working, but somewhere along the way my character name system got messed up and when you play and type in your name, the global variable doesn't change. This worked previously for some reason, I'm unsure as to why it stopped working.
B
7
S
2
G
1
Posts: 28
Reputation: 881


Return to Help & Support using Construct Classic

Who is online

Users browsing this forum: No registered users and 6 guests