IWBTG Stlye Scrolling

Post your own tutorials, guides and demos.

Post » Tue Jul 01, 2008 7:05 pm

The all mighty kayin has posted!
B
2
G
4
Posts: 34
Reputation: 1,118

Post » Tue Jul 01, 2008 7:11 pm

Yay Kayin (the guy who probably can tell us EXACTLY how IWBTG scrolls) finally came to correct us in our wrong ways....whats Modulos though?
"Construct 4 lets YOU make advanced games! (maybe)" Construct Classic - Examples Kit
B
86
S
28
G
13
Posts: 2,092
Reputation: 15,009

Post » Tue Jul 01, 2008 8:20 pm

The modulus is the remainder after integer division. For instance, 17 % 5 ("seventeen modulo five") is 2 -- five goes into seventeen three times, with two left over.
B
2
S
1
G
4
Posts: 60
Reputation: 1,320

Post » Tue Jul 01, 2008 11:18 pm

[quote="Jayjay":34f9i2ch]Yay Kayin (the guy who probably can tell us EXACTLY how IWBTG scrolls) finally came to correct us in our wrong ways....whats Modulos though?[/quote:34f9i2ch]

It was exactly the same way I did it. Only difference is, Construct doesn't have a built in modulos function, so the math for that has to be done manually (which isn't much more at all). I really don't think theres another sensical way to do it.

For those who don't know, Modulos is generally really useful for stuff like rounding numbers -- sort of how the player position in this example is rounded to the nearest screen center. Learn and love it!
B
12
S
4
G
4
Posts: 238
Reputation: 2,426

Post » Tue Jul 01, 2008 11:30 pm

[quote="kayin":18iwrdgm]Only difference is, Construct doesn't have a built in modulos function[/quote:18iwrdgm]
It does - the % operator. Znirk's example is a valid expression.
Scirra Founder
B
359
S
214
G
72
Posts: 22,949
Reputation: 178,574

Post » Wed Jul 02, 2008 2:44 am

I just realized I am entirely a retard.
B
12
S
4
G
4
Posts: 238
Reputation: 2,426

Post » Fri Jul 18, 2008 9:50 pm

[quote="kayin":21o9fwqh]I just realized I am entirely a retard.[/quote:21o9fwqh]
You are The Guy!
B
4
S
2
G
4
Posts: 719
Reputation: 2,938

Previous

Return to Your tutorials & example files

Who is online

Users browsing this forum: No registered users and 0 guests