Results 1 to 4 of 4

Thread: Ap changer/ Name changer/ Checker GS2.

  1. #1

    Ap changer/ Name changer/ Checker GS2.

    Hey I just finished my script last night what it does is it changes your ap, name and guild for some reason was not working so yeah everything is explained in the code.
    PHP Code:
    /*Made by Noof.(Noofboy12 era-go)
    I reccomend to veiw this in a NPC weapon so its more appealing to read.
    What was the purpose of this?
    It's a perfect start to any server that does not have the basic commands this is good for quick name changing and ap chaning, also showname is not 
    always that unique its more mainstream, and with mine it actually tells you your name in your chat, this is done on client side so only you will see it :) ,
    I will be adding more and updating this as I go,
    When you add this to your server make sure to keep this and give me creidt, also use the command "/help" To learn about all the commads,

    Thank you, and Calin I hope you like this man, bye
    */

    function onActionServerside(temp.commandtemp.variable) {
    if(
    temp.command == "updateAp") {
    player.chat "" ;
    player.ap temp.variable;
    }

    if(
    temp.command == "updateName") {
    player.nick temp.variable;
    player.chat ""
     }
    }

    //#CLIENTSIDE
    function onCreated() {
      
    playerChats();
     }

    function 
    onPlayerChats() {
     if(
    player.chat.starts("/ap")) {
      
    temp.ap player.chat.substring(3).trim();
      
    triggerserver("gui"this.name"updateAp"temp.ap);
      }
     else if(
    player.chat.starts("/nick")) {
      
    temp.newname player.chat.substring(5).trim();
      
    triggerserver("gui"this.name"updateName"temp.newname);
      }
     else if(
    player.chat.starts("/gang")) {
      
    temp.gang player.chat.substring(5).trim();
       
    player.guild temp.gang;
      }
      
    /* Start of Q&A -Noof. */
     
    if(player.chat == "/myap") {
      
    player.chat player.ap;
    } else if(
    player.chat == "/mynick") {
      
    player.chat player.nick;
    }
      
    temp.GUI false;
     if(
    player.chat == "/help") {
      
    temp.GUI true;
     if(
    temp.GUI) {
      new 
    GuiWindowCtrl("mywindowcontrol") { 
      
    profile "GuiBlueWindowProfile"
      
    10
      
    253;  
      
    width 400
      
    height 234
      
    text "Commands";
      new 
    GuiTextCtrl("Test_Text") {
      
    profile GuiBlueTextProfile;
      
    10;
      
    30;
      
    height 20;
      
    text "Here you will find everything you need to use my commands!";

    new 
    GuiMLTextCtrl("Test_MultiLineText") {
      
    profile GuiBlueMLTextProfile;
      
    10;
      
    60;
      
    width 400;
      
    height 60;
      
    text "<font size=12><i>Set Ap = '/ap #'<br>Set Name = '/nick ex: Noof.'<br>Check your ap = '/myap'<br>Check your name = '/mynick'<br>Calin this is for you sir<br>So what if I dont want people to see my type in my ap and name?<br> Do not worry I got that coverd it will remove your char right after you click enter
      </i></font>"
    ;
          }
        }
      }  
     }

    Tell me what you think, bye
    Noof was here.

  2. #2
    aaaaaaaaaaaaaaaaaaaaaaaaa Grief Hero's Avatar
    Join Date
    Jun 2013
    Location
    n/a
    Posts
    1,327
    Could have done this in a lot simpler way, but good job


    I saw. I conquered. I came.


  3. #3
    Veteran eski's Avatar
    Join Date
    Aug 2014
    Location
    Arizona
    Posts
    247
    Uhhh!

  4. #4
    Hey everyone I've been working my butt of for this, speacle thanks to Grief, Dan for helping with questions along the way! Tell me how I did.
    PHP Code:
    /*Made by Noof.(Noofboy12 era-go)
    How does it work, and what can it do?
      This is perfect for that just started off server with no scripers. What does it include?
      It includes ap changing for staff Name changing for both staff and players, a GUI that contains information,
      about if the player is staff, there Ap, Name, Graal ID, Ani, Dir, Body, Head, and shield. Also includes an image that changes with you're dir and,
      ani.
      Installation and use!
      1. Create new weapon and add to server,
      2. Go to line 14 and 141, add your staff's graal ID in there,
      3. That's it!
      Tips and Help!
      1. Type "/help" shows you commands
      2. Click E for your inventory
      3. Enjoy
      -Noof
    */
    //add your staff members below use "" and , to seperate
    this.isStaff = {
        
    "Graal1784670"
    };

    function 
    onActionServerside(temp.commandtemp.variable) {
        if (
    temp.command == "updateAp" && player.account in this.isStaff) {
            
    player.chat "My new ap is"
            
    SPC temp.variable;
            
    player.ap temp.variable;
        }

        if (
    temp.command == "updateName") {
            
    player.nick temp.variable;
            
    player.chat "I changed my name, call me "@
            
    temp.variable;
        }
    }

    //#CLIENTSIDE

    function onCreated() {
        
    playerChats();
    }

    function 
    onPlayerChats() {
        if (
    player.chat.starts("/ap")) {
            
    temp.ap player.chat.substring(3).trim();
            
    triggerserver("gui"this.name"updateAp"temp.ap);
        } else if (
    player.chat.starts("/nick")) {
            
    temp.newname player.chat.substring(5).trim();
            
    triggerserver("gui"this.name"updateName"temp.newname);
        } else if (
    player.chat.starts("/gang")) {
            
    temp.gang player.chat.substring(5).trim();
            
    player.guild temp.variable;
        }
        
    /* Start of Q&A -Noof. */
        
    if (player.chat == "/myap") {
            
    player.chat player.ap;
        } else if (
    player.chat == "/mynick") {
            
    player.chat player.nick;
        }
        
    temp.GUI false;
        if (
    player.chat == "/help") {
            
    temp.GUI true;
            if (
    temp.GUI) {
                
    mywindowcontrol2.destroy();
                new 
    GuiWindowCtrl("mywindowcontrol2") {
                    
    profile "GuiBlueWindowProfile";
                    
    10;
                    
    253;
                    
    width 400;
                    
    height 234;
                    
    text "Commands";
                    new 
    GuiTextCtrl("Test_Text") {
                        
    profile GuiBlueTextProfile;
                        
    10;
                        
    30;
                        
    height 20;
                        
    text "Here you will find everything you need to use my commands!";
                    }
                    new 
    GuiMLTextCtrl("Test_MultiLineText") {
                        
    profile GuiBlueMLTextProfile;
                        
    10;
                        
    60;
                        
    width 400;
                        
    height 60;
                        
    text "<font size=12><i>Set Ap = '/ap #'<br>Set Name = '/nick ex: Noof.'<br>Check your ap = '/myap'<br>Check your name = '/mynick'<br>Calin this is for you sir<br>So what if I dont want people to see my type in my ap and name?<br> Do not worry I got that coverd it will remove your char right after you click enter
      </i></font>"
    ;
                    }

                }

            }
        }
    }

    function 
    onupdate() {
        function 
    onKeyPressed(codekey) {
            if (
    key == "e" || leftmousebutton) {
                
    mywindowcontrol.destroy();
                new 
    GuiWindowCtrl("mywindowcontrol") {
                    
    profile "GuiBlueWindowProfile";
                    
    opacity .90;
                    
    300;
                    
    220;
                    
    width 300;
                    
    height 234;
                    
    canmaxamise false;
                    
    text = @findplayer(player).nick;
                    new 
    GuiTextCtrl("Test_Text3") {
                        
    profile GuiBlueTextProfile;
                        
    10;
                        
    30;
                        
    height 30;
                        
    Test_Text3.text "Nickname: "@
                        
    player.nick;
                    }
                    
    Test_Text.destroy();
                    new 
    GuiTextCtrl("Test_Text") {
                        
    profile GuiBlueTextProfile;
                        
    10;
                        
    45;
                        
    height 45;
                        
    Test_Text.text "AP: "@
                        
    findplayer(player).ap;
                        
    update();
                    }
                    
    Test_Text2.destroy();
                    new 
    GuiTextCtrl("Test_Text2") {
                        
    profile GuiBlueTextProfile;
                        
    10;
                        
    60;
                        
    height 45;
                        
    Test_Text2.text "Graal ID: "@
                        
    player.account;
                    }
                    new 
    GuiTextCtrl("Test_Text4") {
                        
    profile GuiBlueTextProfile;
                        
    10;
                        
    75;
                        
    height 45;
                        
    Test_Text4.text "Weapon Equiped: "@
                        
    "DNE";
                    }
                    new 
    GuiTextCtrl("Test_Text5") {
                        
    profile GuiBlueTextProfile;
                        
    10;
                        
    90;
                        
    height 45;
                        
    this.isStaff2 = {
                            
    "Graal1784670"
                        
    };
                        if (
    player.account in this.isStaff2) {
                            
    text "Is Staff: "
                            
    SPC "True";
                        } else {
                            
    text "Is Staff: "
                            
    SPC "False";
                        }
                    }
                    new 
    GuiTextCtrl("Test_Text6") {
                        
    profile GuiBlueTextProfile;
                        
    10;
                        
    105;
                        
    height 45;
                        
    Test_Text6.text "Direction: "@
                        
    player.dir;

                    }
                    
    Test_ShowImg.destroy();
                    new 
    GuiShowImgCtrl("Test_ShowImg") {
                        
    220;
                        
    50;
                        
    width 80;
                        
    height 100;
                        
    ani player.ani;
                        
    dir player.dir;
                    }

                    new 
    GuiTextCtrl("Test_Text7") {
                        
    profile GuiBlueTextProfile;
                        
    10;
                        
    120;
                        
    height 45;
                        
    Test_Text7.text "Head: "@
                        
    player.head;
                    }
                    new 
    GuiTextCtrl("Test_Text8") {
                        
    profile GuiBlueTextProfile;
                        
    10;
                        
    135;
                        
    height 45;
                        
    Test_Text8.text "Body: "@
                        
    player.body;
                    }
                    new 
    GuiTextCtrl("Test_Text9") {
                        
    profile GuiBlueTextProfile;
                        
    10;
                        
    150;
                        
    height 45;
                        
    Test_Text9.text "Shield: "@
                        
    player.shield;
                    }
                }
            }
        }
    }



    Noof was here.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •