get a button to rotate?

Get help using Construct 2

Post » Sun Dec 30, 2012 5:54 am

I've implemented a "Troll button" into the title menu of my game and I want it to spin slowly. I gave it the rotate behavior, but all it does is go in some large orbit and I can't figure out how to make it spin on it's center point.
B
6
Posts: 90
Reputation: 690

Post » Sun Dec 30, 2012 8:55 am

Is the "center point" the actual origin? Is the image you're using actually centered (i.e. even or no transparency around the object)?
B
26
S
5
G
1
Posts: 62
Reputation: 2,335

Post » Sun Dec 30, 2012 5:09 pm

You see, I can't edit it to replace it's image. That's a problem in itself, but basically I cant right click it and edit the image to move the origin point.
B
6
Posts: 90
Reputation: 690

Post » Sun Dec 30, 2012 5:14 pm

oh yeah , it's a button , is it ? You need to make it a sprite ... If you want to implement a troll farm !
B
35
S
16
G
16
Posts: 2,222
Reputation: 16,589

Post » Sun Dec 30, 2012 6:00 pm

[QUOTE=Whiteclaws] oh yeah , it's a button , is it ? You need to make it a sprite ... If you want to implement a troll farm ![/QUOTE] How can I make it a sprite and make it click-able at the same time? Yes, if you double click the layout and click on the "button" thing is what I'm using.
B
6
Posts: 90
Reputation: 690

Post » Sun Dec 30, 2012 6:04 pm

If you add the mouse object to your project, you can use the condition "On object clicked" to make the sprite object act like a button.
B
27
S
8
G
8
Posts: 903
Reputation: 8,452

Post » Sun Dec 30, 2012 6:07 pm

[QUOTE=Nimtrix] If you add the mouse object to your project, you can use the condition "On object clicked" to make the sprite object act like a button.[/QUOTE] That's neat; but can I implement the sprite without having to re-write all my code?

EDIT; Could I copy the button image to the sprite so that it looks like all the other buttons on the page?WAFFLE OF WAR2012-12-30 18:08:56
B
6
Posts: 90
Reputation: 690

Post » Sun Dec 30, 2012 6:18 pm

Sure you can, but if you want it to act like a regular button you'll need 3 frames. The normal one plus one for hovering over and one for clicking the button.

Though I would just make my own button sprites since, in my opinion, the regular buttons don't really look good in games.

And yeah, you'll probably have to change some conditions. But replacing some button events with mouse events doesn't take too long if you just copy/paste the conditions.Nimtrix2012-12-30 18:18:49
B
27
S
8
G
8
Posts: 903
Reputation: 8,452

Post » Sun Dec 30, 2012 6:19 pm

[QUOTE=Nimtrix] Sure you can, but if you want it to act like a regular button you'll need 3 frames. The normal one plus one for hovering over and one for clicking the button.

Though I would just make my own button sprites since, in my opinion, the regular buttons don't really look good in games.

And yeah, you'll probably have to change some conditions. But replacing some button events with mouse events doesn't take too long if you just copy/paste the conditions.[/QUOTE] Sounds like I have some work to do. Thanks, though.
B
6
Posts: 90
Reputation: 690

Post » Sun Dec 30, 2012 6:33 pm

capx is always helpfull
B
49
S
19
G
9
Posts: 431
Reputation: 10,001

Next

Return to How do I....?

Who is online

Users browsing this forum: DemantDigitalArt, Lancifer and 28 guests