SUGGESTION: Room Locations

Started by redspark, Wed 07/10/2009 17:37:37

Previous topic - Next topic

redspark

I have a suggestion for AGS's Room Editor.  I was thinking of implementing it as Extender functions but it would be so much better as part of the Room Editor.

Basically, it is a way of tagging a specific point within a room and giving it a name.  Then instead of teleporting a character to a specific Room and coordinates, you can just give the name of the location that you want the character to move to.  Each Room would have a list of x,y coordinates and a name.

So a teleport would go from:

player.ChangeRoom(11, 400, 337);

to:

player.ChangeRoom(11, "EntryWay");


This gives two benefits:  Your code is more readable than just numbers and if you have to change the location, you just have to edit the one Location Point with the Room Editor and all references in your game are updated.  No fuss or mess. :)

I hope you like the idea.  Thanks.

James

SSH

Code: ags

#define ENTRYWAY 400,337

12

Joseph DiPerla

Yeah thats one of the great features of C++/C# is that you can use #define. Although in his defense, someone not so great at programming might not know that.
Joseph DiPerla--- http://www.adventurestockpile.com
Play my Star Wars MMORPG: http://sw-bfs.com
See my Fiverr page for translation and other services: https://www.fiverr.com/josephdiperla
Google Plus Adventure Community: https://plus.google.com/communities/116504865864458899575

redspark

Thanks.  I hadn't thought of a #define.  However, it still would be nice to be able to do it through the Room editor and not have to wade through a lot of code to find the one you are looking for.  One of my rooms alone has about 20 different locations in it for entry points, walking destinations and so on  It would be a little cleaner to handle it in the Room Editor.  Unless I'm missing something else. ;)

I had thought of using Hotspots but I didn't want to waste them.

Khris


redspark

#5
I only read the first bit of that post and didn't realize that it was expanded from the original concept to the same things as I was posting.  Sorry for the extra thread then.

tzachs

No worries, you phrased it better...

SMF spam blocked by CleanTalk