Jump to content


G-Games

Member Since 07 Nov 2010
Offline Last Active Yesterday, 08:14 PM

Topics I've Started

Going Lan With Gm:S - Possible?

12 May 2013 - 12:30 PM

EDIT: Problem has changed, please look a few posts down for the current issue!

 

Hi there,

 

Game Maker Studio (GM:S) has been updated a while ago to version 1.4 and added awesome networking functions. I quickly got the hang of these (and work pretty darn good to my opinion), but now I'm facing a little challenge.

 

I want to have several devices connected to each other with a server. Now that's not a big problem. The issue occurs whenever I want to implement LAN. Now, LAN is neither much of a problem, though there is a little detail: I want the clients to auto-connect, so they don't need to enter an ip adress! This would save a bunch of time and makes life a lot easier. Especially because you're running LAN, there's no need for entering an ip adress, as you've already connected to that particular network!

 

Long story short: Can I create something that detects the ip required for LAN connection? Note that I'd like to have this cross-platform, so a DLL might not work.

 

Hopefully someone can help me with this problem.

 

Thanks in advance.


Creating A Text Field *Solved*

02 May 2013 - 10:06 AM

Hi there,

 

I've created some text fields over the past few months in which the player is able to type, add enters, spaces, all sorts of characters, etc. Now, I'm onto a new challenge. I want to have a text field that allows color coding of specific words (think of Notepad++).

 

I have no idea how to achieve this though, anyone any ideas on how to create such a text field?

 

Thanks in advance.


The Gml Quiz 2.0

30 April 2013 - 04:43 PM

Hi there,

 

I've seen tons of Game Maker Language quizzes, and they all ask you to choose between three options on some sort of pop-up message. I decided not to do such a thing and create this way different, asking much more of your skill and knowledge about GML. How far can go come without your error checking and colored code?

 

The way this quiz works is simple, you'll be presented a piece of GML code and you have to point out the error or malfunction*, but sometimes, there aren't any errors at all!

 

Download the quiz here: http://www.mediafire...rchey19uyn3l1a0

 

I've tried to add as much variation as possible and tried to make sure that some things aren't too obvious. Please note that the line with error you mark might vary from where I think the error is at, but I've tried to prevent this as much as possible. Though, if you think something is very out of place and should not be there at all, or worse, if there is an error in the code that isn't been asked for: PLEASE let me know. I've ran through tons of tests, but I can also make mistakes.

 

ABd7zYO.png

Sample question

 

*Here are a few samples to point out the difference

 

Sample error:

a; //This is an error inside the GM code editor

 

Sample malfunction:

while(true){} //This hangs your game; Though not an error, I see this as a malfunction and therefor this is an incorrect code.

 

Sometimes, you might not see the malfunction. I've tried to prevent this as much as possible, but if you think it's too far-fetched, please let me know.

 


Inheriting All Variables From Another Object

20 April 2013 - 01:20 PM

Hi there.

 

I have a very complex question today. I'm creating some DLC expansions, and it would be pretty nice if I could just copy all variables from object A into object B. Call it: Inheriting variables.

 

The problem is that I'd like to have it in a single script, not a ton of them. I've tried things like:

 

object_set_parent(objectA, objectB);

object_event_add(objectA, ev_create, 0, "event_inherited();");

with(objectA){event_perform(ev_create, 0);}

object_set_parent(objectA, -1);

 

This sadly doesn't seem to work though. So.. anyone any ideas on how I could do it?

 

Also assume that..:

- ...the object exists in the room.

- ...the object already has a step and draw event that cannot be overwritten.

- ...the parent object also exists in the room.

- ...the parent object has initialized before the child object.

 

Note: I use GM8.0 as GM:S doesn't allow execution of strings anymore. That's why I can edit resources 'on the fly'.


Room_Instance_Add() Is Instant Crash

16 April 2013 - 06:41 PM

Hi,

 

I've decided to go and export some of my games to Android, and I've came across a major issue. I've got world's saved in a file, and I now try to open the file, read the data from it, create a new room and then place the predefined instances inside the room. Then the player will move towards the room and he/she can start to play.

 

Problem is though, that whenever the game comes across "room_instance_add(r, 0, 0, testObj); //<-- Test bit" it instantly crashes and hangs forever. So I decided to try this on Windows and it turns out that it doesn't hang like a usual endless for or while loop. Instead of the screen going white and the game doing nothing, Windows just instantly pops up the message that the game has crashed and is trying to fix it.

 

My entire code is just 'room_instance_add(r, 0, 0, testObj);', so there's nothing else that could cause this problem.

 

Anyone any ideas?