• Hey! Guest! The 39th GMC Jam will take place between November 26th, 12:00 UTC and November 30th, 12:00 UTC. Why not join in! Click here to find out more!

cursor

  1. zendraw

    GMS 2 Position in path relative to mouse position

    how can you make a position in a path to be approximately around the mouse cursor? basicly we have a line which is the path, then we press the mouse somewhere near the path and i want to place the position in the path at a point in the path that is nearest to the mouse cursor.
  2. kureoni

    custom mouse object being overlaped by other objects (except player sprite)

    did a custom mouse for my game but i would like to set it on the first game layer so it would not be overlaped by anything any ideas?
  3. kureoni

    SOLVED does anyone knows how to make a functional topdown 2d movement script?????

    var move_left = keyboard_check(ord( "A")); var move_right = keyboard_check(ord("D")); var move_down = keyboard_check(ord("S")); var move_up = keyboard_check(ord("W")); if (move_left && place_free(x-spd,y)){ x-=spd; } if (move_right && place_free(x+spd,y)){ x+=spd; } if...
  4. giraffeman210

    Drag And Drop Cursor selecting issues

    I have never used a mouse to select something in game I was making before but I thought I would mess around. However I can't get it to work. I'm new to using a mouse for control so I bet it is an easy answer. The way I have it now makes it so the cursor has to be fully covering the object for...
  5. If Programable_Matter

    Windows How to make Program with the ability to highlight the text with the mouse (Cursor)

    I've been making a lot of programs and they have been going well however I cannot make the text that has been drawn "highlightable" like you would be able to in Microsoft Word, Notepad, or other software which deals with characters. Is there are particular code which can enable me to highlight...
  6. G

    Custom Cursor in Drag and Drop

    Hey, I'm developing a sort of five nights at freddy's style game for my girlfriends birthday coming up, and one of the things i wanted to include is a custom mouse cursor while within the game. However, i don't have any coding experience except for other types of games i've made in game maker...
  7. Michael Stearns

    GML Solved - String Width but ignoring line breaks

    Hello! I've got a text box that gradually fills with text, typewriter-style. I wanted to draw a little "cursor" at the end of the string being displayed, but I seem to be having some trouble. The problem is that string_width (and string_width_ext) does not seem to actually return the line...
  8. W

    GMS 2 [SOLVED] Change cursor when hovering over object

    Hi. I'm looking for an easy way to change my cursor, when I hover over an interactable. I have tried with DnD, but I think it could be made easier with a step event and some coding. But I'm not quite sure. Any ideas? Also, this is a sidenote and I don't want to impose, but I'm also looking...
  9. E

    GMS2: Is there a way to hide cursor brush?

    Hello, is it possible to hide the cursor brush im GMS2 sprite editor? I would preffer to draw with the mouse cursor, because the brush keeps blocking the entire pixel im drawing on. Thanks
  10. D

    Fullscreen bug [SOLVED]

    Hello, im newbie in gamemaking and im russian, my english is bad. I make pixel game, main menu have 1920x1080 resolution, other rooms 288x160 (one pixel block is 16x16). In GMS2 i have a bug: i launch my game in fullscreen, cursor is disabled, but when i touch top right corner with invisible...
  11. J

    Question - Code Need help with random cursor

    Hey guys, So I have a sprite with 10 images, all different coloured cursors. Here is my code: if (room != rMenu) and (room != rControls) and (room != rUpdatesAndNotes) and (room != rShop) and (room != rEnding) and (room != rCredits) { cursor_sprite = sCursorGun; } else { cursor_sprite =...
  12. C

    GML Create an object to always be between player and mouse.

    Hello everyone, I've been trying to figure out how to keep an object between the mouse cursor and the player. I've been able to offset the object from the mouse cursor using: x = mouse_x - 10; but that is very static and i would like it to look as if it is rotating around the cursor when its...
  13. BenSunhoof

    GML Changing cursor sprite back to normal when on a specific object?

    Hey there. I have a piece of code that changes the cursor sprite to a custom one and makes it green whenever it hovers over something clickable: var inst; inst = instance_position(mouse_x,mouse_y,all) if inst != noone cursor_sprite = spr_cursor_slct else cursor_sprite = spr_cursor; if...
  14. MartinK12

    GML [SOLVED] Cursor that will select top instance of any object on click, GMS2

    I want a cursor that will always select top instance of any object: button, enemy, tower, etc. and then if this instance is selected I just do stuff with it but I just can't get it to work :( I have obj_cursor and in the mouse_global_left_pressed event I try different codes. The result is id of...
  15. I

    Mac OSX window_set_cursor() - Does Not Work

    I'd like to report that this function ultimately is useless on MacOS. It does nothing at all. window_set_cursor(cr_drag); Does anyone know why or if it is working for them, or even a work around? Specs: MacBook Pro (Retina, 15-inch, Mid 2015) MacOS High Sierra
  16. T

    GML What is the best way to model recoil climb in in my platformer?

    Alright, I'm in the very very early stages of working on a platformer with mouse aim. It uses the standard kind of system where a separate arm object rotates around the player's shoulder with an image angle that follows the cursor. For a handful of design reasons, I really don't want to use an...
  17. I

    Need help keeping cursor inside object.

    Hello! How can I keep cursor inside an object? For example, I have a volume slider and I want to keep cursor inside it until mb_left is released. I'm also going to hide the cursor and change a sprite of the slider. But first i want to figure out how to keep the cursor inside the slider when...
  18. N

    GMS 2 Making cursor the inverted color to the background

    This would be very useful for my game. Every pixel of the curor is the inverted color of the background. There is such a thing in Minecraft. Is this possible in GM?
  19. Y

    Legacy GM mouse following object

    So I looked around and I have seen alot of how do I make my object follow the mouse threads. but my question is: how can I make my mouse follow an object. I need this so I can use a custom cursor object that acts like a mouse but I can't find any functions that let you change the mouse position...
  20. G

    (solved) Code help! please

    I have a question, i want to make a custom cursor and i want to know the best way to make one. the: x = mouse_x y = mouse_y this makes me feel like all "x's" will be be on mouse_x for example; if i'm drawing a sprite at x+3 would that mean 3+ the origin of the sprite or the mouse? (same...
Top