macro

  1. Daniel Mallett

    GMS 2.3+ Macros

    Does anybody know why Gamemaker refers to constants as macros? To me, a macro is something that performs a particular of predefined action. A constant is one value that never changes. This isn't stopping me working I'm just curious. It feels as though I have missed something fundamental in...
  2. T

    Legacy GM Wierd Error with Expression Macros

    Hi, I am having this error that I cannot make sense of: I somehow narrowed the error to this line: global.DTBS_NUMBER[3] = DTBS_OTHER_NUM - DTBS_ENEMY_NUM; Or more specifically, the use of macro DTBS_OTHER_NUM. The macro is defined as follows: ... DTBS_OTHER_NUM | (DTBS_ENEMY_NUM+20)...
  3. S

    Anyone stumble into the delete macros and your project is wiped out?

    I've fallen into this trap quite a few times. If I delete a macro or add a macro once, add the same macro (same name) and then delete the extra, the project file won't compile. Then closing and opening GMS 1.4+ will result in the entire project being cleared out. The content is still in the...
  4. HayManMarc

    Using #macro's for layer ID's?

    Hello programmers, I'm wanting to make my room layers easier for me to see and write (in my code) so I was going to use #macro's for this. But I'm not sure which way would be better. Do you? At first, I was going to do it like this, in the Create event of a control object (where I do all my...
  5. jana

    [SOLVED] Macro code error

    I'm following the manual's instructions for creating a macro, and I'm getting an error as I type this code in the script editor: #macro NUMSETS 106 http://www.screencast.com/t/dGJwi4QNPm This link in the manual shows the same syntax I'm using...
  6. G

    GMS 2 [SOLVED] enum v. #macro

    hey all, i was wondering what the differences between enums and macros are when it comes to just using them in lieu of ungrouped numbers, if i do something like this: #macro TSTEP 30 #macro HSTEP 8 #macro VSTEP 12 #macro MSTEP 10 versus enum step { tstep = 30, hstep = 8, vstep = 12...
  7. D

    GML Macro Arrays Question

    Hey everyone, I am working on an item system in a game and have run into a bit of a snag. The jist of it is this, i have created an Enum to hold a Int value for every item within my game: enum ItemIndex{ gun = 0, sword = 1, healthPotion = 10, ect... } Then i held specifice data abount my items...
  8. K3fka

    GMS 2 Macros somehow affecting each other? [Solved]

    Hey, everyone. I'm having a pretty strange issue involving macros. I want to have four macros: tlx, tly, brx, and bry, which would correspond to top-left and bottom-right coordinates of a sprite (given that the origin is centered). I'm finding that for the purpose of collisions, I want to...
  9. T-bond

    Discussion Different macro values of different configuration

    The new macro definition method is super cool, and long wanted. But for now, I can't figure out the way how to change their value depending on the current configuration. In GMS 1.4 for every configuration selected there was a separate Macro editor, so for example I could toggle between the...
  10. N

    Legacy GM Question about Macros

    Say I have an array of attributes holding the stats of a character stats[1] being strength stats[2] being dexterity, and so on. But I have so many stats and interactions to keep track of, it gets confusing and unreadable. Example: if stats[26]<stats[23] { stats[26]+=stats[32]/room_speed...
  11. ZeDuval

    Legacy GM Macro/Constant of Project vs Extension difference bug(?)...

    Hey friends! Whoever would accuse me of being a Macro/Constant-addict, would be right. I love 'em and use 'em very often to "hide" variables with long names for example. A GM-project can have constants, accessible in the ressource tree structure in a menu, which must btw be the worst menu ever...
  12. F

    Legacy GM Issues when using Macro constant

    I have problems when compiling. When I attempt to use a Macro constant in my code, the compiler will throw an assignment exception (and signs where I'm pretty sure that they're not needed). I suspect that the compiler itself is broken. PS: This will happen on any exporting platform.
Top