Shaking screen and Player position.

Get help using Construct 2

Post » Wed Jul 18, 2012 12:02 am

Hello folks,

I wanna confirm if I'm doing something wrong...

I want to shake the screen when shotting, but if you go to the middle of the scenario, it work as instead, but if you shot near the left edge, for example, it don't work.. any idea?

SandBOX: https://dl.dropbox.com/u/47035927/04%20-%20Survive/index.html

CAPX: https://dl.dropbox.com/u/47035927/temp/00-CURRENT.capx

The second thing is about the player (the grey one, not the player sprites).

It's floating over the scenario, and after many tries I decided to leave it as it is, because none of the code set any offset, so, I can't figure out what the hell is happening =(

Edited: Yeah, shaking screen near the edge of a scenario don't will really shake the screen. It feel like a bug or a misunderstand of this functionalityTELLES08082012-07-18 00:35:57
ImageImageImageImageImageImage
B
93
S
19
G
12
Posts: 1,209
Reputation: 18,357

Post » Wed Jul 18, 2012 5:20 am


Global Variable: ShakeVar: 0


Shake by N7Effect, on Flickr

Ex: every 0.01/(Everytick) seconds: Animation playing "Shoot"
Set "ShakeVar" to Random(4,5)

Just change the random numbers to your liking
My way is the best and easiest so far with the easiest customization. Erndog2k2012-07-18 05:26:06
B
27
S
11
G
1
Posts: 246
Reputation: 5,048

Post » Wed Jul 18, 2012 10:49 am

I'd say it's got to do with the fact that you can't scroll outside the layout. And shake just scrolls the screen. You'd have to set 'unbounded scrolling' on to have it shake at the edges of the layout.
B
54
S
28
G
18
Posts: 1,520
Reputation: 25,000


Return to How do I....?

Who is online

Users browsing this forum: No registered users and 15 guests