Jump to content
  • 0

GM and Player annoucement


Question

Posted (edited)
//Created by Aeromas
//Ver 1.0
//Compatible with:
//eAthena
//GM Login && Admin login announcement, when new player joins, they're announced PLAYER has joined your RO, and then they get 2 level ups, you can modify it with getitem, or set Zeny, X;
-    script    gmloginannounce    -1,{

OnPcLoginEvent:

    if(getgmlevel() >=99) {
        if(#LoginAnnounce$ == "On")
        {
            announce "Administrator "+strcharinfo(0)+" has signed in.",bc_all,0x00ff66;
            end;
        }
    }
    else if(getgmlevel() < 99 && getgmlevel() >= 60)
    {
        if(#LoginAnnounce$ == "On")
        {
            announce "GM "+strcharinfo(0)+" has signed in.",bc_all,0x00FF66;
            end;
        }
    }
    end;
}

-    scriptjoinyourro    -1,{

OnPcLoginEvent:

    if(#New_Player == 1) end;

    if(BaseLevel==1 && JobLevel == 1)
    {
        announce "Please welcome "+strcharinfo(0)+"  to our server!",bc_all,0x00ff66;
        announce " And for joining our server, we're going to level you up 2 times!",bc_self,0x00ff66;
        atcommand "!baselevel 2";
        set #New_Player,1;
        end;
    }
    end;
}


 

 

 

can someone edit it for rathena use ? 

the leveling also now working.

besides that,, can someone add offline function for offline GM level 60 above with red color and

add new function online player with green color and offline player with red color.

 

Edited by mrlongshen

12 answers to this question

Recommended Posts

Posted

I don't understand your request, can you be more specific ?

 

ok. its like this.

 

1.When admin login, and all gm level 40 above login, there will an auto annoucement to all map that tell the gm +strcharinfo(0are online. The color will be GReen when broadcast it. When the gm are online. It will annouce +strcharinfo(0) has offline. The color will be red.

 

2.In the same script. I want to request, each new player coming, novice. An auto annoucement will be made, the annoucement is, Welcome to +strcharinfo(0). Thanks to join xxxRO and straightly to to our main town by type @go 0. To all player, lets welcome our new friend here.

Posted

Like that ? Test it

-	script	ann_login	-1,{

OnPCLogoutEvent:
	callsub L_ann, 0xff0000, "out";
OnPCLoginEvent:
	callsub L_ann, 0x00ff00, "in";
L_ann:
	if( getgmlevel() >= 99 )
		announce "Administrator "+ strcharinfo(0) +" log "+ getarg(1) +".",bc_all, getarg(0);
	else if( getgmlevel() < 99 && getgmlevel() >= 10 )
		announce "GM "+ strcharinfo(0) +" log "+ getarg(1) +".",bc_all, getarg(0);

	else if( #New_Player != 1 && BaseLevel == 1 && JobLevel == 1 ) {
		announce "Please welcome "+ strcharinfo(0) +"  to our server!",bc_all,0x00ff66;
		announce " And for joining our server, we're going to level you up 2 times!",bc_self,0x00ff66;
		atcommand "!baselevel 2";
		set #New_Player, 1;
	}
	end;
}
  • Upvote 1
Posted

Like that ? Test it

-	script	ann_login	-1,{

OnPCLogoutEvent:
	callsub L_ann, 0xff0000, "out";
OnPCLoginEvent:
	callsub L_ann, 0x00ff00, "in";
L_ann:
	if( getgmlevel() >= 99 )
		announce "Administrator "+ strcharinfo(0) +" log "+ getarg(1) +".",bc_all, getarg(0);
	else if( getgmlevel() < 99 && getgmlevel() >= 10 )
		announce "GM "+ strcharinfo(0) +" log "+ getarg(1) +".",bc_all, getarg(0);

	else if( #New_Player != 1 && BaseLevel == 1 && JobLevel == 1 ) {
		announce "Please welcome "+ strcharinfo(0) +"  to our server!",bc_all,0x00ff66;
		announce " And for joining our server, we're going to level you up 2 times!",bc_self,0x00ff66;
		atcommand "!baselevel 2";
		set #New_Player, 1;
	}
	end;
}

 

 

YES BRO. like this. hehe~

thx alot. btw. can u add a gm know who online.

its like this.

 

when a normal player login

An online popup will show to all on gm online.

its appear on chatbox. this is not broadcast to global. it just appear on online gm only.

e.g

mrlongshen has online.

mrlongshen has offline.

Posted
-	script	ann_login	-1,{

OnPCLogoutEvent:
	callsub L_ann, 0xff0000, "out";
OnPCLoginEvent:
	if( getgmlevel() > 10 ) {
		while ( .@i < .size_gm && getcharid(3) != .gm_acc[.@i] ) .@i++;
		if( .@i == .size_gm ) {
			.gm_acc[.@i] = getcharid(3);
			.size_gm++;
		}
	}
	callsub L_ann, 0x00ff00, "in";
L_ann:
	if( getgmlevel() >= 99 )
		announce "Administrator "+ strcharinfo(0) +" log "+ getarg(1) +".",bc_all, getarg(0);
	else if( getgmlevel() < 99 && getgmlevel() >= 10 )
		announce "GM "+ strcharinfo(0) +" log "+ getarg(1) +".",bc_all, getarg(0);

	else if( #New_Player != 1 && BaseLevel == 1 && JobLevel == 1 ) {
		announce "Please welcome "+ strcharinfo(0) +"  to our server!",bc_all,0x00ff66;
		announce " And for joining our server, we're going to level you up 2 times!",bc_self,0x00ff66;
		atcommand "!baselevel 2";
		set #New_Player, 1;
	}
	else {
		for( .@i = 0; .@i < .size_gm; .@i++ )
			if( isloggedin( .gm_acc[.@i] ) )
				message rid2name( .gm_acc[.@i] ), "Player "+ strcharinfo(0) +" log "+ getarg(1) +".";
	}
	end;
}

 

 

EDIT : fix a mistake

  • Upvote 1
  • Love 1

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.   Paste as plain text instead

  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.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...