Jump to content


Eldin64

Member Since 21 Aug 2011
Offline Last Active May 16 2013 09:36 PM

Topics I've Started

Double Camera Porblem

16 May 2013 - 05:05 AM

Hey GMC,

 

I was making 2 cameras for 2 different players, and the cameras work great and all, but now I'm facing the timeless resolution problem, the pixels are messy in full screen.

 

When I'm in window mode it's a ll okay, but the moment it's in full screen things get on pixel wider or thinner, and that leads to everything looking messy.

 

How do I fix this? And for both cameras, not just one? Do I write one thing that fixes both? Or do they need to be handled separately .

 

In case you need them, here are the settings for both views:

 

View 0:

 

Visible when room starts (checked)

 

View in room:
X: 0  Y:240  W:800  H:240

 

Port on screen:

X:0  Y:10  W:800  H:240

 

object following : player1

 

Hbor: 180  Vbor: 40

 

View 1:

 

Visible when room starts (checked)

 

View in room:
X: 0  Y:240  W:800  H:240

 

Port on screen:

X:0  Y:260  W:800  H:240

 

object following : player2

 

Hbor: 180  Vbor: 140

 

 

Thanks for your time guys, if you need more details about something specific, tell me and I'll gladly provide you with it!

 

Eldin


Getting Rid Of That Blurry Screen In Gm Studio

13 April 2013 - 09:00 PM

Hey GMC,

 

I've made a build of the core mechanics I wanted to implement in a 2D game, and I was wondering hos do I get rid of the blurry pixel art?

 

Basically, everything doesn't look sharp like pixel art should, and I already ticked the tearing option in the settings (although I doubt that is related). Is there an option somewhere to make the resolution a good one? Not really a fan of such blurry pixel art.

 

Thanks guys!


X360 Code Equivalent For Vk_Right, Left, Up, Down

13 April 2013 - 04:41 PM

Hey GMC,

 

Was trying to write some code in GM Studio, and while I have a list of all the X360 controls in the help menu, there is something unexplained here.

 

I'm trying to make 2 game mechanics, here are their details:

 

The first is a simple 2D platformer, I was wondering what are the equivalent codes for the X360 controller left analog stick for ( if keyboard_check_pressed(vk_left)) also (vk_right), (vk_up), and (vk_down).

 

Basically, I just want to move the left analog stick left, and have the character move left.

Also, what code would I have to write to make it sensitive? Like move the analog stick a tiny bit to the left and have it move slower than when going left all the way.

 

 

The second mechanic, is basically a Mother 3 like movement. Characters move in 8 directions, and animate in said directions. Is it gonna include a code that is basically gonna be divded by 45? Or is there also the not-so-flexible possibility of writing something like "if (keyboard_check_pressed(vk_up)) and (keyboard_check_pressed(vk_left))?

 

Thanks for your time guys, if you'd like to see my original code for the keyboard, I'll gladly post it (assuming it's easy to make an X360 version of said code).


Explanation For This Collision Code

13 April 2013 - 01:28 AM

Hey GMC!

 

Just opened the demos in GM Studio, and was hoping for an explanation for some of the code, some of it is really not understandable to me.

 

Here's the code:

 

 
var xx,yy,c1,c2;







// Apply gravity (and jumping)

y = y+grav;

grav+=0.4;

if( grav>=10 ) grav=10;



// If falling, check UNDER the player

if( grav<0 )

{

    if( dir=1){

        sprite_index = jump_right;

    }else{

        sprite_index = jump_left;

    }

    c2 = -1;                               // What does c2 do right here?

    c1 = GetCollision(x,y);        // GetCollision is another script

    if( (x&$1f)>0 ) {                  // What is (x&$if) exactly???

        c2=GetCollision(x+32,y);

    }

    if( c1>=0 || c2>=0 )

    {

        grav=0;

        y = (y&$ffffffe0)+32;     // And what is (y&$ffffffe0)???

    }

}

else{

    // Otherwise, check above player

    if( jump )

    {

        if( dir=1){

            sprite_index = fall_right;

        }else{

            sprite_index = fall_left;

        }    

    }else{

        grav=0;

        jump=true;

    }

    c2 = -1;

    c1 = GetCollision(x,y+32);

    if( (x&$1f)>0 ) {

        c2=GetCollision(x+32,y+32);

    }

    if( c1>=0 || c2>=0 )

    {

        y = (y&$ffffffe0);    // Is that the exact same as the one above

        jump=0;

        

        if( dir=1){

            sprite_index = walk_right;

        }else{

            sprite_index = walk_left;

        }           

    }

}    









// If moving left, check LEFT collision

if( keyboard_check(vk_left) )

{

    dir=-1;

    if(!jump){

        sprite_index = walk_left;

    }

    x=x-xspeed;

    c2=-1;

    c1 = GetCollision(x,y);

    if( (y&$1f)>0 ) c2=GetCollision(x,y+32);   // I can tell this (y&$1f) has the same meaning as (x&$1f), but for the y couterpart, what do they do exactly?

    if(  c1>=0 ) || ( c2>=0 )

    {

        x = (x&$ffffffe0)+32;  // This is probably the same as the (y&$ffffffe0), but what do they do? What are they?

    }    

}else if( keyboard_check(vk_right) )

{

    // Otherwise, check collision to the right

    dir=1;

    if(!jump){

        sprite_index = walk_right;

    }

    x=x+xspeed;

    c2 = -1;

    c1 = GetCollision(x+32,y);

    if( (y&$1f)>0 ) c2=GetCollision(x+32,y+32);

    if(  c1>=0 ) || ( c2>=0 )

    {

        x = (x&$ffffffe0);

    }    

} else {

    // If standing still, don't animate

    image_index =0;

}
 

 

Thanks for your time guys, I hate writing code when I don't understand what it does, even if I am just copying it.


Gm Studio On Steam Keeps Crashing

12 April 2013 - 02:07 AM

Hey GMC!

 

I'm probably not the first to complain about this moronic issue, but GMS on Steam keeps crashing every time I open the background, or anything else for that matter.

 

I deleted GM Studio from Steam and then redownloaded it again, but to no avail.

 

I checked yoyo games and the site says that if you buy from yoyogames.com, you can get a Steam key, but if you buy it from Steam, you can't get a license key to use GM Studio without Steam.

 

That is absolute bull in my opinion, now I bought software worth $300 and it doesn't work.

 

How do I fix this problem? What is the next step here? I need to be able to use GM Studio, and the Steam version is absolutely horrendous, it's practically unplayable.

 

Is there a way I can let yoyo games provide me with a license key so I can use GM Studio, and justify the money paid on this program?

 

Thanks for your time guys, appreciate it!