Button vs Sprite vs ... ?

Discussion and feedback on Construct 2

Post » Mon Sep 21, 2015 6:21 am

Hello

What is the better way?
Use C2 buttons (maybe with adjusting CSS) or use own Sprites as buttons?
I know, with Sprites it is easier to adjust their look and feel.
But is there also another reason to use button or sprites? Maybe the different kinds of devices and browsers?

If you use Sprites. Do you create them yourself (how, with which tool) or do you download them (where)?

Thanks for your hints.


PS: Sorry for my english, isn't my mothertounge.
B
13
S
4
Posts: 23
Reputation: 991

Post » Thu Sep 24, 2015 12:59 pm

Hello

I try to ask in other words.

When you use Buttons and when you use Sprites as buttons?
Is there a reason to use buttons anymore?

Thanks
B
13
S
4
Posts: 23
Reputation: 991

Post » Thu Sep 24, 2015 1:38 pm

Buttons come with already set actions to function as a button. Sprite you would have to do it yourself. Some people make the button invisible and place it over the sprite to have access to the button features.
B
23
S
4
G
2
Posts: 364
Reputation: 2,392

Post » Thu Sep 24, 2015 4:34 pm

Button is a DOM object, and you can't be guaranteed the appearance between browser's. Some browsers may have different CSS objectives for their visual look.

Sprite as a Button is traditional game programming and will always be the same among all browsers.

If your doing the UI for a game. Use Sprite. If your doing an APP use DOM/Button. You should use DOM objects sparingly in a game if you do. If your doing some kind of web game where canvas is segregated from game play. then you could do a UI borders and embed them in a div.

Also DOM is another layer. So every DOM object requires a DOM/DIV layer rendered in between canvas renderings. On Some browsers this can slow your games performance.
B
90
S
18
G
9
Posts: 2,455
Reputation: 15,013

Post » Thu Sep 24, 2015 5:15 pm

I prefer Sprites, css style I found was inconsistent, especially if your making the buttons global.
Try http://dabuttonfactory.com/ , its free.
Bushy Ball\Boatman Bill\Sticky Web\Snake

Image ImageImageImage

During the gold rush it was a good time to be in the pick and shovel business
B
44
S
12
Posts: 241
Reputation: 5,070

Post » Thu Sep 24, 2015 6:02 pm

@sizcoz Nice share.
B
23
S
4
G
2
Posts: 364
Reputation: 2,392

Post » Thu Sep 24, 2015 7:37 pm

Thanks for your replies.
It will helps me.
B
13
S
4
Posts: 23
Reputation: 991


Return to Construct 2 General

Who is online

Users browsing this forum: rovacado and 3 guests