1. H

    GMS 2.3+ String with width 0 - cannot fit into callstack???

    I'm not sure why, but in my Draw GUI event I can no longer draw strings. When the debugger reaches the line of code which should draw a string, I just get the phrase (Here the string is just the word Charm, and oMite is the object which does just about everything in my game) I watched a few...
  2. EvanSki

    SOLVED What data type are strings in Game Maker Studio 2? | Convert const char* to const wchar_t*

    Yes yes, string is string. But let me explain. I want to pass a string from Game Maker to a .dll The .dll wants a LPCWSTR ( Long Pointer to Constant Wide String ) type string just passing gm strings to the dll gives me this Now "This is text" is not, what ever that is. Now i can do string...
  3. ChillAssLofi

    Need Help with a Word Find game I'm making, please.

    Hi, I am trying to make a "word find game". You know where you get a jumble of random letters and you try to find words hidden inside. (I suppose this is actually more like the game Boggle if you're familiar with that.) As you choose the tiles with the letters, the letters should appear on...
  4. Slothagami

    GMS 2 Color coding strings at runtime

    I'm making my own version of code writer, just for fun, and I am want to make the text color coded for the languages I intend to use it for (html, css, javascript, etc...). So the problem is that I need to change part of a strings color based on context, (check if it's in brackets and things)...
  5. EvanSki

    GMS 2 What is best practice for String compares?

    Not sure if this qualifies as advanced programming but the way I see it the normal user wouldn't worry about this. Anyways... I was watching A GDC talk(3:40) and the speaker was talking about how they avoid string to string compares, but didn't go into details So after some research I've come...
  6. Binsk

    Asset - Scripts UBG Strings

    Yoyo Marketplace (coming at some point) Itch.IO Upset Baby Games View the online documentation to explore the available functions. Would you like to expand upon the available string functions included in GameMaker? This extension does just that. The added functionality ranges from small to...
  7. Coded Games

    Designing a translation system with dynamic strings.

    I am attempting to implement localization support into my game but I am running into one challenge. My game is a card game and the description of cards can change depending on how many "Fusion Points" a card has. For example I may have a card like this: Gunshot: Fire 2 bullets. But if I gain 1...
  8. Antikore

    GML Problem converting from string to real for seeds

    I'm trying to make a minecraft-like seed system where you can type some kind of text string and it will be converted to real and afterwards the seed will be set. However, seems I'm doing something wrong with the converter. I didn't follow any tutorials so my code might be completely stupid, I'm...
  9. KyleRansford

    GMS 2 Spell Checking Dialog "strings"

    Is there a way to spell check "strings" that I've written dialogs with? I know (or at least haven't seen it) that GameMaker Studio 2 IDE doesn't have a grammar spell check, but is there away or some kind of program, where I can check for grammer spelling in the code that I've typed? I have a...
  10. EvanSki

    SOLVED How to check if a global variable exists without using a ds_map

    Hi! As the title says I want to figure out if a global variable (global.cats) exists without having to put every global in the entire game into a ds_map and checking against it. for more context. im currently doing it like this //If variable name actually exists if...
  11. A

    GML split equation into numbers and operator

    I want to split an equation into 3 sections. The first number, the second number and the operator itself. Example: Input (string_print) = print 10+15 num1 = 10 num2 = 15 op = "+" eq = string_copy(string_print, 7, string_length(string_print)-6) This is the code I use for getting everything...
  12. Fixer90

    GMS 2 Em Dash in Strings (SOLVED)

    I want to include em dashes in my strings, and not have them return as the default "▯." For example: str = "The quick brown fox — who was very quick indeed — jumped over the lazy dog."; returns as "The quick brown fox ▯ who was very quick indeed ▯ jumped over the lazy dog." I already tried...
  13. FeetUpGaming

    Replace multiple characters in a string

    Hey having trouble figuring how to replace multiple sets of characters in a string at once. I have a file save and load system where the player picks the save file name but to do that i need to make sure they don't do anything silly like putting @,£,$,/,| etc in the file name so how would i go...
  14. T

    GML Squish text after two lines

    Hello I am drawing text into a sprite box of a fixed size, 1200 pixels wide and enough room for 2 lines of text. I am using the following to wrap the text so it is not drawn off the sides of the sprite draw_text_ext(x,y,thisText,-1,1200) where x,y is the centre of the sprite and thisText is the...
  15. PlayerOne

    GMS 2 Advice when it comes to loading text (localization) [SOLVED]

    I plan localizing my game and I have two ideas rolling around in my mind on how to load text. Either load the strings from an .ini file into a ds_grid in a centralized way and have the objects access the strings form that grid or load strings in each object when a room starts (or object spawned)...
  16. EvanSki

    Legacy GM (Solved) Can a variable pick a string at random?

    Basically what I want to do is Have an object call a script (scr_decry) The script holds a variable (decry_phrase) and a list of strings such as "apple", "password","pinepplesarebad" Then the script will make (decry_phrase) = a random string from the list Any help is appreciated, Thanks!
  17. Lord KJWilliams

    Windows do you need quotation marks for using load_csv function, to import strings?

    Ive been reading the online manual , and the load_csv function does not state if your csv file needs to have values that are treated as strings to be enclosed in " " , double quotation marks so that load_csv converts it to a string variable. Does any one know ? Thanks
  18. N

    GMS 2 Writing strings in-game

    In my game, I want to be able to write strings via keyboard input in-game. I tried to do this. In the object that is the textbox, I have 3 events: -Left Pressed event: global.textselect = id; -Step event if (global.textselect != id) || (string_length(global.title) > 14) exit; if...
  19. Gasil

    Checking how many characters a string has?

    Hello, I am using the following snippet: if (time < text_length) { time += velocity; print = string_copy(text, 0, time); } To draw the letters of a string one by one on a text box. However, I'd like to give the option to make the text appear in a single frame by pressing the letter...
  20. Nixxi

    UWP [Resolved] Having trouble creating/initializing global variables

    Hello GameMaker Community. I'm having an issue with creating global variables for sharing information between the players, game objects, and ini reading/writing. Part of the problem is that my game has a max of twenty (20) save slots, each slot has roughly 5,200 individual datapoints (for...