TinTin++ Mud Client The TinTin++ message board

 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
TinTin++ Mud Client

#return stops processing of subsequent aliases

 
Post new topic   Reply to topic    The TinTin++ message board Forum Index -> Bug Reports
View previous topic :: View next topic  
Author Message
moebius



Joined: 27 Jan 2005
Posts: 96

PostPosted: Sun Nov 30, 2008 11:56 am    Post subject: #return stops processing of subsequent aliases Reply with quote

I find #return useful to quit out of an alias after checking some initial conditions, rather than having the whole body inside multiple levels of braces. But I have found it not only quits the current alias but stops subsequent aliases from working as well:

Code:
#alias aaa {say this is aaa}
#alias bbb {say this is bbb}
#alias ccc {say this is ccc;#return}

> aaa;bbb

You say, 'this is aaa'

>

You say, 'this is bbb'

> ccc;bbb

You say, 'this is ccc'

>


This really limits the usefulness of #return.
_________________
StrangeMUD - strangemud.net:9332
Back to top
View user's profile Send private message
Scandum
Site Admin


Joined: 03 Dec 2004
Posts: 3796

PostPosted: Sun Nov 30, 2008 1:13 pm    Post subject: Reply with quote

Given the way tintin works it's difficult to alter the behavior.

You can nest by omitting the braces of the else part of the if check though:
Code:

#if {a}
{
    do something
}
#if {b}
{
    do something else
}
#if {c}
{
     do nothing
}
{
    do something different
}
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic   Reply to topic    The TinTin++ message board Forum Index -> Bug Reports All times are GMT - 5 Hours
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
Get TinTin++ Mud Client at SourceForge.net. Fast, secure and Free Open Source software downloads Get TinTin++ Mud Client at SourceForge.net. Fast, secure and Free Open Source software downloads
TinTin++ Homepage

Powered by phpBB © 2001, 2002 phpBB Group