Jump to content
  • 0
Sign in to follow this  
Pandaaa

@main on/off [World Chat]

Question

[ A Simple World Chat ]

@main on (makes the @main (World Chat) work like you can view/see their different conversation in your chat from different maps)

 

example (If @main is on):

@main "Hey Juan, Where are you come to blablalbla"

 

@main off (Makes the @main (World Chat) disabled which you will not see any world chat conversation, just normal.)

 

 

anyone can help make this script, or share if you got same script?

Edited by Pandaaa

Share this post


Link to post
Share on other sites

7 answers to this question

Recommended Posts

  • 0

 

[ A Simple World Chat ]

@main on (makes the @main (World Chat) work like you can view/see their different conversation in your chat from different maps)

 

example (If @main is on):

@main "Hey Juan, Where are you come to blablalbla"

 

@main off (Makes the @main (World Chat) disabled which you will not see any world chat conversation, just normal.)

 

 

anyone can help make this script, or share if you got same script?

How about using channels?

Share this post


Link to post
Share on other sites
  • 0

 

 

[ A Simple World Chat ]

@main on (makes the @main (World Chat) work like you can view/see their different conversation in your chat from different maps)

 

example (If @main is on):

@main "Hey Juan, Where are you come to blablalbla"

 

@main off (Makes the @main (World Chat) disabled which you will not see any world chat conversation, just normal.)

 

 

anyone can help make this script, or share if you got same script?

How about using channels?

can i change that into simple like typing @main <on|off> to see the world chat?

Share this post


Link to post
Share on other sites
  • 0

 

 

 

[ A Simple World Chat ]

@main on (makes the @main (World Chat) work like you can view/see their different conversation in your chat from different maps)

 

example (If @main is on):

@main "Hey Juan, Where are you come to blablalbla"

 

@main off (Makes the @main (World Chat) disabled which you will not see any world chat conversation, just normal.)

 

 

anyone can help make this script, or share if you got same script?

How about using channels?

can i change that into simple like typing @main <on|off> to see the world chat?

 

You can make script that can triggered on/off status.

Yeah Brenth is right  :p_hi:

Share this post


Link to post
Share on other sites
  • 0

 

 

 

 

[ A Simple World Chat ]

@main on (makes the @main (World Chat) work like you can view/see their different conversation in your chat from different maps)

 

example (If @main is on):

@main "Hey Juan, Where are you come to blablalbla"

 

@main off (Makes the @main (World Chat) disabled which you will not see any world chat conversation, just normal.)

 

 

anyone can help make this script, or share if you got same script?

How about using channels?

can i change that into simple like typing @main <on|off> to see the world chat?

 

>You can make script that can triggered on/off status.

Yeah Brenth is right  :p_hi:

 

functions?

Share this post


Link to post
Share on other sites
  • 0

I'm using this to some of my scripts

 

        case 2:
            next;
            mes .npc_name$;
            mes "Turn ^00BB22ON^000000 / ^FF2200OFF^000000 your restock whenever you get login in-game.";
            mes " ";
            mes "Status: "+(RESTOCK_AUTO ? "^00BB22Enabled^000000" : "^FF2200Disabled^000000");
            switch(select("Nothing...","I want to "+(RESTOCK_AUTO ? "^FF2200disable^000000 it" : "" "^00BB22enable^000000 it"))) {
                case 1:
                    close;
                break;

                case 2:
                    if(RESTOCK_AUTO) {
                        set RESTOCK_AUTO,0;
                    } else {
                        set RESTOCK_AUTO,1;
                    }            
                break;
            }
        close;
        break;
 

 

OnPCLoginEvent:
    if (RESTOCK_AUTO)
        atcommand("@restock load");
    end;
 

Feel free to use and change it, just change the restock load to @join main or something.. So they will auto-join when login.  Or you can edit the case 2 and add join/leave command.

Share this post


Link to post
Share on other sites
  • 0

Bump anyone can add this to Hercules?

 

this is what i am looking for..

/*===================================
* Main chat [LuzZza]
* Usage: @main <on|off|message>
*-----------------------------------*/
ACMD_FUNC(main)
{
if( message[0] ) {

	if(strcmpi(message, "on") == 0) {
		if(!sd->state.mainchat) {
			sd->state.mainchat = 1;
			clif_displaymessage(fd, msg_txt(380)); // Main chat has been activated.
		} else {
			clif_displaymessage(fd, msg_txt(381)); // Main chat already activated.
		}
	} else if(strcmpi(message, "off") == 0) {
		if(sd->state.mainchat) {
			sd->state.mainchat = 0;
			clif_displaymessage(fd, msg_txt(382)); // Main chat has been disabled.
		} else {
			clif_displaymessage(fd, msg_txt(383)); // Main chat already disabled.
		}
	} else {
		if(!sd->state.mainchat) {
			sd->state.mainchat = 1;
			clif_displaymessage(fd, msg_txt(380)); // Main chat has been activated.
		}
		if (sd->sc.data[sC_NOCHAT] && sd->sc.data[sC_NOCHAT]->val1&MANNER_NOCHAT) {
			clif_displaymessage(fd, msg_txt(387));
			return -1;
		}

		if ( battle_config.min_chat_delay ) {
			if( DIFF_TICK(sd->cantalk_tick, gettick()) > 0 )
				return 0;
			sd->cantalk_tick = gettick() + battle_config.min_chat_delay;
		}

		// send the message using inter-server system
		intif_main_message( sd, message );
	}

} else {

	if(sd->state.mainchat)
		clif_displaymessage(fd, msg_txt(384)); // Main chat currently enabled. Usage: @main <on|off>, @main <message>.
	else
		clif_displaymessage(fd, msg_txt(385)); // Main chat currently disabled. Usage: @main <on|off>, @main <message>.
}
return 0;
}

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.