A simple way to customize buttons?

Just started using Construct 2? Post your questions here

Post » Wed Jul 22, 2015 7:58 pm

It's frustrating beyond belief! Made some progress, was able to insert variables by right-clicking on the events sheet - only global variables but they became "local" when pulled lower into the order of events. Then I can't access them anymore in the System/set value dialogue, so I put them back to the top as "global" until putting in the code for text and buttons. Now they're down at the same place you have them and I hope they'll work. Using the Events Tab or right-clicking, I can't directly create a local variable.
B
3
Posts: 7
Reputation: 189

Post » Thu Jul 23, 2015 5:35 am

local variables are only available in groups or nested under other events.
(see https://www.scirra.com/manual/83/variables )
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

Post » Thu Jul 23, 2015 9:21 am

Thanks, RamPack. The only way I found of creating local variables was dragging global ones down under another event - the program then changed them to local variables. Whether they would be functional, I don't know, the tutorial mentioned in this thread was my Waterloo. Using your simpler method to change css values was effective.

Edit: The project is nearing completion. Sorry I'm not allowed to post URLs yet, test address is singadream.com/constructexport2/index.html which can be copied into your browser. The project can't be accessed from the main website which is dedicated to my music.

I decided to simplify the matter by putting the quiz answers in as text with a blank button or checkbox next to each one.

To sum up, I'm impressed with the ability of the program to import animations I made in Anime Studio (exported as png files) and turn them into sprite sheets that work. The group cropping function is great. The background can thus be exported as a single frame sprite, the moving animation character in the same format with no background - the crop function for the animated object works even if the animation frames are of unequal size (for example, if some frames include text or a foreground object).

Getting the buttons to trigger different animations on the same background is a bit of work, but it can be done even by a neophyte like me. I hope at some point in the development of Construct 2 changing the appearance of buttons will be as easy as formatting text in the properties window. At the moment I'm (mis)using the program as an improved presentation software which can export html 5. By the way, the suggestion to try it came from the Anime Studio "Lost Marble" forum.
B
3
Posts: 7
Reputation: 189

Previous

Return to Beginner's Questions

Who is online

Users browsing this forum: No registered users and 0 guests