The Gang Garrison 2 Forum
May 22, 2013, 02:48:01 am *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
News: Chat with us on IRC: http://ganggarrison.com/irc.html
Server: irc.esper.net, Channel: #gg2
 
   Home   Help Search Login Register  
Poll
Question: Should the REDD Engine be included with the final release of Gateway?
Yes - 75 (84.3%)
No - 14 (15.7%)
Total Voters: 76

Pages: « 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 »
  Print  
Author Topic: Gateway Classic  (Read 102002 times)
NAGN
Developer
******
Offline Offline

Posts: 16895


Yeah so now I have an idea


« Reply #885 on: January 16, 2010, 08:31:40 pm »

Erm how is that coolcube going to work, and WTF is it for?

This game uses wallmasks, so if Only I knew how to detect angles...
hint: use direction.
direction is an angle
I did use direction.

it failed.

Wait how do I even use direction anyways, I just ripped the available code...
Logged



[im
NAGN
Developer
******
Offline Offline

Posts: 16895


Yeah so now I have an idea


« Reply #886 on: January 16, 2010, 08:32:38 pm »

Here's mine.

Destroy event for object Portile:

move_contact_solid(direction, speed);
a=0;
b=0;
if !place_free(x+6,y) a+=1;
if !place_free(x-6,y) a-=1;
if !place_free(x,y+6) b+=1;
if !place_free(x,y-6) b-=1;
if(active)
{
    portal=instance_create(x,y,Portal);
    portal.color=color;
    portal.direction=point_direction(x,y,x+a,y+b);
    portal.image_angle=portal.direction;
}

Yeah I thought about place_free, hm. I'll try that.
Logged



[im
NAGN
Developer
******
Offline Offline

Posts: 16895


Yeah so now I have an idea


« Reply #887 on: January 16, 2010, 08:39:03 pm »

Hey it works

I'll just tweak it so that it doesn't spin uncontrollably when it hits a corner hehe
Logged



[im
NAGN
Developer
******
Offline Offline

Posts: 16895


Yeah so now I have an idea


« Reply #888 on: January 16, 2010, 08:44:09 pm »



That'll have to go too, but thanks alot wareya
Logged



[im
Phantom Brave
All Hail Classicwell
Designer
*****
Online Online

Posts: 9034


Another one --


WWW
« Reply #889 on: January 16, 2010, 08:46:44 pm »

I know exactly hwo to fix that but it's really complicated and I don't want to delve into the code right now.
Logged

NAGN
Developer
******
Offline Offline

Posts: 16895


Yeah so now I have an idea


« Reply #890 on: January 16, 2010, 08:57:48 pm »

I know exactly hwo to fix that but it's really complicated and I don't want to delve into the code right now.

So pretty much, I'm going to replicate this simple engine:

http://gmc.yoyogames.com/index.php?showtopic=329554

now with this direction, would it be if direction=270 for down or something?
Logged



[im
Dusty
Hero Member
*****
Offline Offline

Posts: 10651


Dust in a box under a table


« Reply #891 on: January 16, 2010, 09:02:24 pm »

I know exactly hwo to fix that but it's really complicated and I don't want to delve into the code right now.

So pretty much, I'm going to replicate this simple engine:

http://gmc.yoyogames.com/index.php?showtopic=329554

now with this direction, would it be if direction=270 for down or something?
0 is right, 90 is down, 180 is left, 270 is up.
but i may be wrong
Logged

NAGN
Developer
******
Offline Offline

Posts: 16895


Yeah so now I have an idea


« Reply #892 on: January 16, 2010, 09:04:12 pm »

I know exactly hwo to fix that but it's really complicated and I don't want to delve into the code right now.

So pretty much, I'm going to replicate this simple engine:

http://gmc.yoyogames.com/index.php?showtopic=329554

now with this direction, would it be if direction=270 for down or something?
0 is right, 90 is down, 180 is left, 270 is up.
but i may be wrong

Oh wait I found a chart

Logged



[im
NAGN
Developer
******
Offline Offline

Posts: 16895


Yeah so now I have an idea


« Reply #893 on: January 16, 2010, 09:08:43 pm »

so yeah

if direction>45 && direction<90

direction==90 or whatever I set the variable to
Logged



[im
aftershockpivot
Hero Member
*****
Offline Offline

Posts: 1914



« Reply #894 on: January 16, 2010, 10:02:51 pm »

Here's mine.

Destroy event for object Portile:

move_contact_solid(direction, speed);
a=0;
b=0;
if !place_free(x+6,y) a+=1;
if !place_free(x-6,y) a-=1;
if !place_free(x,y+6) b+=1;
if !place_free(x,y-6) b-=1;
if(active)
{
    portal=instance_create(x,y,Portal);
    portal.color=color;
    portal.direction=point_direction(x,y,x+a,y+b);
    portal.image_angle=portal.direction;
}

That definately makes alot more sense than my idea.
Logged

♫Sani Sani Disco♫
Onion Knight
******
Offline Offline

Posts: 10503


yo let's suck face and listen to rap music


WWW
« Reply #895 on: January 16, 2010, 10:30:28 pm »

Oh, and rather than use vspeed, just use normal speed and make the player's direction the opposite of the portal's to keep the momentum going.

Just an idea.
Logged

Quote from: mop
Quote from: MR MAGN3TIC
I don't like it.  Nah
Oh, well, you might as well pack up and stop now, because he doesn't like it
Asdf64: "ultros turned me on" - sani 2013
Phantom Brave
All Hail Classicwell
Designer
*****
Online Online

Posts: 9034


Another one --


WWW
« Reply #896 on: January 16, 2010, 10:31:12 pm »

character.direction=portala.direction-portalb.direction
or something
Logged

NAGN
Developer
******
Offline Offline

Posts: 16895


Yeah so now I have an idea


« Reply #897 on: January 16, 2010, 10:47:36 pm »

Oh, and rather than use vspeed, just use normal speed and make the player's direction the opposite of the portal's to keep the momentum going.

Just an idea.

I took that from that portal engine thing

The orientation is still wacky, more reliable but still occasionally doesn't work at certain angles
Logged



[im
Rock
Hero Member
*****
Offline Offline

Posts: 1836


Hello? Again?


« Reply #898 on: January 17, 2010, 06:21:25 am »

Work with the portal's direction to determine which sprite to use.

like,

Quote
if direction="w" or direction="x"{image_index=0}else if direction="y" or direction="z"{image_index=1}

I was going to add 4 special walkmask types.
Logged

New game much? 2D platforming stealth much?
NAGN
Developer
******
Offline Offline

Posts: 16895


Yeah so now I have an idea


« Reply #899 on: January 17, 2010, 10:05:09 am »

Work with the portal's direction to determine which sprite to use.

like,

Quote
if direction="w" or direction="x"{image_index=0}else if direction="y" or direction="z"{image_index=1}

I was going to add 4 special walkmask types.
I  considered that two, but then I was like hell no.

Imma release beta 5 soon, then I'll fix up floor portals and momentum
Logged



[im
Pages: « 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 »
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!
Page created in 0.29 seconds with 20 queries.