1. PulseNS

    Legacy GM Trouble using lengthdir to find point on sprite

    Hi, I'm creating a top down game based in space and have the spacecraft booster effects as a separate sprite. The spacecraft has two booster points and I have saved them into an array boosterX and boosterY. My problem is that I just can't seem to get the boosters to line up properly. They are...
  2. M

    Legacy GM [SOLVED]Shooting from tip/barrel of gun

    hello, I'm doing a top down project, however no matter what I do the bullet keeps coming out of the gun barrel, could anyone help me? I'm learning to use the game maker yet and I do not know some basic things. my sprite = x=128 y= 85 origin = x=40 y=49 gun tip...
  3. M

    GMS 2 Lengthdir_x and lengthdir_y

    Hello YoYos I'm trying to change the direction of this yellow orb to move in the opposite direction for 10 frames. It's a collision problem. Every time i collide with the white square, the yellow orb moves to the right. How can i fix this? I'm submitting my code with this thread. t g
  4. Zack

    A video introduction to lengthdir_x and lengthdir_y (a primer for building a top-down shooter)

    GM Version: GameMaker: Studio 1.4 or GameMaker Studio 2 Target Platform: All Download: https://github.com/zbanack/TSE-lengthdir/archive/master.zip Links: N/A Summary: This is The Step Event's (my) brief presentation on the lengthdir_x and lengthdir_y functions in GameMaker: Studio 1.4 and 2 and...
  5. cdgamedev

    GMS 2 [SOLVED] Issue with lengthdir_y

    Hello, I'm trying to use lengthdir_y but when I enter Speed = 16; direction = 45; vspeed = lengthdir_y(Speed, direction); it returns 0. However, when I enter Speed = 16; direction = 45; vspeed = lengthdir_y(16, 45); it returns -11.31 as expected. Am I missing something or is it broken? This...
  6. M

    Pathfinding and roaming states

    I've been using pathfinding for a while now in my game (top down shooter). The enemies are supposed to have 2 different states whenever they are not engaged, idle and roam. While in idle they stay still and while they are roaming they pick a random direction and move there until an alarm makes...
  7. Shadowblitz16

    Legacy GM (SOLVED) lengthdir_y is not doing anything

    can someone confirm if this is a bug in gms 1.4? basicly I have separated my sine motion and my linear motion into two sections I can confirm that my velocity is 5 and my angular is 0 when I come to line 43 and 44 however it doesn't seem to be doing anything.
  8. E

    [SOLVED] lengthdir_X/Y help

    So in my game I want to draw a triangle that goes through 2 points in my object. The way I define those points may seam long but it's actually quite simple. I have outlined that in the diagrams I have drawn below (If you can read my handwriting). The code for this is also below, I recommend to...
  9. P

    Collision not being detected with collision_line at specific angles using length_dirx/y

    Hello everybody, Without getting into too much detail on what I'm trying to accomplish with the whole game, I'm creating a rail shooter where the player is able to jump from one rail to another. Using a custom-made collision script (that uses collision_line), the player object tells the rail...