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

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » zMUD General Discussion
nematocyst
Newbie


Joined: 24 Dec 2003
Posts: 5
Location: USA

PostPosted: Fri Apr 02, 2004 9:29 pm   

getting current room's vnum?
 
How can I get the current room's vnum? My map was upgraded from 6.22, and %roomnum() is not returning the vnum, and %roomid() doesn't return anything.

I worked around this by issuing:
#NOOP %maplocked(0)
#LOOP %numrooms {#NOOP %roomnote(%i,%i)}
#NOOP %maplocked(1)

and then just using %number(%roomnote()).

But when I add new rooms, this means I have to update the database again, so I'd rather just be able to access the vnum directly.
Reply with quote
Vijilante
SubAdmin


Joined: 18 Nov 2001
Posts: 5182

PostPosted: Sat Apr 03, 2004 12:01 am   
 
Try using %roomvnum. The %roomnum function is tied to the state of %roomkey. I believe %roomvnum isn't. Also your vnum's may not be set as you expect.
Reply with quote
nexela
Wizard


Joined: 15 Jan 2002
Posts: 1644
Location: USA

PostPosted: Sat Apr 03, 2004 11:02 am   
 
%roomnum returns vnum regeardles of %roommode
%roomkey returns %roomkey of %roomnum regardles of %roommode
%roomvnum returns %roomnum in %roommode(0) and %roomkey in %roommode(1)
%mapvnum is the same as %roomvnum
Reply with quote
Vijilante
SubAdmin


Joined: 18 Nov 2001
Posts: 5182

PostPosted: Sat Apr 03, 2004 3:11 pm   
 
Grr, I was really off yesterday. Thanks for the corrections, Nexela.
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » zMUD 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