Critical chance rolls?

Get help using Construct 2

Post » Sun Jan 19, 2014 7:42 pm

What's the easiest way to implement a critical chance roll? I want to have a global variable for the player that can be upgraded as the game progresses.
Image
B
20
S
4
Posts: 382
Reputation: 2,984

Post » Sun Jan 19, 2014 9:04 pm

Give your player an instance variable (called CriticalChance ?) and give it a value (1 ?) then you can put something like ..

if player hits then damage = 10
if random(100)<chriticalchance then damage=damage *2
take damage from baddies hitpoints

?

as player puts experience into critical chance (player goes up a level)

make (variable) CriticalChance =CriticalChance+1 (or 5 or 10)

?
August 2015 - I misplaced a lot of links - I will try to find backups and repost. If You find a post that interests please reply to post with @rampackwobble and I will get a nudge!

If you find my posts useful please consider donating something to a local charity or to the http://www.mndassociation.org/
B
64
S
34
G
47
Posts: 1,194
Reputation: 30,892


Return to How do I....?

Who is online

Users browsing this forum: Christmas, dop2000 and 50 guests