Register to post in forums, or Log in to your existing account
 

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » CMUD General Discussion
croww
Newbie


Joined: 02 Jul 2013
Posts: 5

PostPosted: Wed Jul 06, 2016 3:54 pm   

Coloring rooms in cmud mapper `?
 
Is there a way to make a script to color rooms in the cmud map after name in the map.

Like i have alot of rooms named "In the graveyard". Is there a script that goes thro the database and color all those rooms black.
And i have alot of rooms named "In the center of a serene forest meadow" , can i get all those to light green ?

Or do i have to click each rooms in the map and then go to room proterties and change from there ?

The worldmap is huge, and there is a old ascii map that a player did, I am currently running around making a cmud version of it.

http://home.caiway.nl/~lep/zombie/map/
(thats just the outworld, then all the zones are even more rooms)

Any help would be nice
Reply with quote
shalimar
GURU


Joined: 04 Aug 2002
Posts: 3736
Location: Pensacola, FL, USA

PostPosted: Wed Jul 06, 2016 11:38 pm   
 
It is possible to do it by script... however it would likely hang CMUD for a few minutes as it worked.

#CALL %maplocked(0)
#FORALL %numrooms {
#IF (%roomname(%i)="In the graveyard") {#CALL %roomcol(%i, black)}
#IF (%roomname(%i)="In the center of a serene forest meadow") {#CALL %roomcol(%i, lightgreen)}
etc
}
#CALL %maplocked(1)
_________________
Windows 10 Home Premium 64-bit
AMD Phenom II x6 1055T 2.8GHz 16GB
CMUD Pro v3.34
Reply with quote
croww
Newbie


Joined: 02 Jul 2013
Posts: 5

PostPosted: Wed Jul 06, 2016 11:51 pm   
 
So i guess i take lines and save it to a file. what should i name the file ?
And then go to actions run script ?

Anyways it i get it to work, it will be fantastic


Last edited by croww on Wed Jul 06, 2016 11:56 pm; edited 1 time in total
Reply with quote
shalimar
GURU


Joined: 04 Aug 2002
Posts: 3736
Location: Pensacola, FL, USA

PostPosted: Wed Jul 06, 2016 11:54 pm   
 
You can also edit the properties of several rooms at once, but that tends to mess up the very next room you create via the mapper for some reason.
_________________
Windows 10 Home Premium 64-bit
AMD Phenom II x6 1055T 2.8GHz 16GB
CMUD Pro v3.34
Reply with quote
croww
Newbie


Joined: 02 Jul 2013
Posts: 5

PostPosted: Wed Jul 06, 2016 11:58 pm   
 
Yeah i have tried to use the nearby in panels to get as many rooms i can, and then change em all. But it misses so many rooms sometimes
Reply with quote
shalimar
GURU


Joined: 04 Aug 2002
Posts: 3736
Location: Pensacola, FL, USA

PostPosted: Thu Jul 07, 2016 12:30 am   
 
if you put the map into mapping mode, you can draw a box around multiple rooms and select them that way. or shift+click to add individual rooms
_________________
Windows 10 Home Premium 64-bit
AMD Phenom II x6 1055T 2.8GHz 16GB
CMUD Pro v3.34
Reply with quote
croww
Newbie


Joined: 02 Jul 2013
Posts: 5

PostPosted: Thu Jul 07, 2016 12:38 am   
 
aye thanks. So those commands you printed out, what should i call the file. is it just a txt file or do i need to call it something else ?
Reply with quote
shalimar
GURU


Joined: 04 Aug 2002
Posts: 3736
Location: Pensacola, FL, USA

PostPosted: Thu Jul 07, 2016 12:51 am   
 
I would likely make a new #EVENT onMapUpdate {to hold it}
Similar to an #ALIAS, but without the possibility of sending the callword to the game if you disable the setting.
Just '#RAISE onMapUpdate' to execute.
_________________
Windows 10 Home Premium 64-bit
AMD Phenom II x6 1055T 2.8GHz 16GB
CMUD Pro v3.34
Reply with quote
croww
Newbie


Joined: 02 Jul 2013
Posts: 5

PostPosted: Fri Jul 08, 2016 12:37 am   
 
Ok didnt get ur code to work. But this did.

#CALL %maplocked(0)
#VAR Path %mapquery("[Name] LIKE '%Swimming out upon the ocean%'")
#FORALL @Path {#call %roomcol(%i, blue)}
#CALL %maplocked(1)


I just change the "swimming out upon the ocean" to diffrent descriptions.
Thank you for showing the way with maplock and %roomcol%
etc.

Not sure if i am doing it the correct way, but atleast it looks like its working
Laughing
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » CMUD General Discussion All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

© 2009 Zugg Software. Hosted by Wolfpaw.net