I needed help with command,variable and use.

For questions about using Classic.

Post » Thu Jul 24, 2014 2:46 pm


1. When the text "money" in 50, then the value of the tower is available.
When the text "money" in 0, then the value of the tower is unavailable.
I think so when the value is 1 and with the object enable for build tower and again in reverse when is 0 disable tower not build but how this have make ? I needed when text " money" in 50 = value 1 then button enable and can build.

2. If I have enough money and want to buy a tower, then when i click
> object is glued to the mouse and when i click and there it will sit where i want.

Because me miss command ("when" is tower blue so text set defeat") etc.. How this replace ?

I need:
1. Object in move mouse and next when clicked then build tower
2. Value of "money " from 50 up is value variable 1 and from 49 down is value variable 0
3. When have "every ticks 400" but i want only 10 spawn objects

Could you please help me. Thanks.
Posts: 6
Reputation: 185

Post » Fri Jul 25, 2014 2:50 pm


1. Use opacity. When you have more money set the opacity to 100, otherwise set it to 50.
When a player wants to buy the tower, check if the opacity is 100 otherwise they can't buy it.

2. Make a variable called 'purchased'. After you click a tower. While purchased = 0, Use MouseX and MouseY to change the positions of your tower and disable the turret behavior so it cannot shoot before placement. When someone clicks, set purchased to 1 so it no longer moves and allow turret behavior.

3. Add a variable called enemycount which set it to 10. Do every 400 ticks, spawn enemy and decrease enemycount by 1. Use compare if enemycount >0. When It drops to 0, enemies no longer spawn.
Posts: 46
Reputation: 1,144

Return to Help & Support using Construct Classic

Who is online

Users browsing this forum: No registered users and 4 guests