Nugs0153 Posted March 13, 2014 Group: Members Topic Count: 9 Topics Per Day: 0.00 Content Count: 23 Reputation: 0 Joined: 02/25/14 Last Seen: April 12, 2014 Share Posted March 13, 2014 I've seen NPCs on servers in the past where people can enable at commands when they login. I'd like players to be able to turn commands off some commands if they wish. Anyone know where I can find it? Quote Link to comment Share on other sites More sharing options...
Capuche Posted March 13, 2014 Group: Developer Topic Count: 10 Topics Per Day: 0.00 Content Count: 2407 Reputation: 616 Joined: 07/05/12 Last Seen: March 20 Share Posted March 13, 2014 prontera,150,160,5 script auto cmd 87,{ mes "you can enable yours commands on login"; next; while(1) { for ( .@i = 0; .@i < .size_cmd; .@i++ ) .@menu$ = .@menu$ + "[ " + ( auto_cmd & pow( 2,.@i ) ? "^00ff00ON" : "^ff0000OFF" ) + " ^000000] @" + .cmd_display_name$[.@i] + ":"; .@s = select( .@menu$ ) -1; auto_cmd = auto_cmd ^ pow( 2,.@s ); mes "ok what's next?"; .@menu$ = ""; next; } OnPCLoginEvent: if ( auto_cmd == 0 ) end; for ( .@i = 0; .@i < .size_cmd; .@i++ ) { if ( auto_cmd & pow( 2,.@i ) ) atcommand "@" + .cmd_display_name$[.@i]; } end; OnInit: setarray .cmd_display_name$[0], "autoloot", "commands"; .size_cmd = getarraysize( .cmd_display_name$ ); } or http://rathena.org/board/topic/92360-utility-onpclogin-gm-settings/?p=243632 http://rathena.org/board/topic/76131-login-commands/?p=166229 1 Quote Link to comment Share on other sites More sharing options...
Question
Nugs0153
I've seen NPCs on servers in the past where people can enable at commands when they login. I'd like players to be able to turn commands off some commands if they wish. Anyone know where I can find it?
Link to comment
Share on other sites
1 answer to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.