Thread: [PI] Command Control Interface [PI]

Page 5 of 5 FirstFirst ... 345
Results 41 to 47 of 47
  1. #41  
    Registered Member
    Join Date
    Aug 2012
    Posts
    73
    Thanks given
    10
    Thanks received
    0
    Rep Power
    0
    Please re upload the sprites.
    Reply With Quote  
     

  2. #42  
    Registered Member
    Join Date
    Nov 2013
    Posts
    68
    Thanks given
    176
    Thanks received
    3
    Rep Power
    20
    Quote Originally Posted by dudefish12 View Post
    Please re upload the sprites.
    I doubt anyone still has these since its old but hey someone might so i'll bump it for you
    Reply With Quote  
     

  3. #43  
    MOB
    MOB is offline
    Project Drop-Zone Owner & The BLOOD Gang Always Banging RED


    Join Date
    May 2013
    Age
    25
    Posts
    3,001
    Thanks given
    5
    Thanks received
    937
    Rep Power
    183
    Would like these sprites as well
    [Only registered and activated users can see links. ]
    Reply With Quote  
     

  4. #44  
    Donator

    Anthony's Avatar
    Join Date
    Dec 2007
    Age
    26
    Posts
    1,345
    Thanks given
    198
    Thanks received
    129
    Rep Power
    355
    Nice release, might use the basic concept of it and re-create it.. I'm not too sure why people are saying "Don't delete it" just copy it paste it to a text document for later viewing if you want it.
    Reply With Quote  
     

  5. #45  
    Registered Member
    Join Date
    Nov 2015
    Posts
    173
    Thanks given
    6
    Thanks received
    2
    Rep Power
    11
    Are there any sprites?
    Reply With Quote  
     

  6. #46  
    Registered Member
    Join Date
    Aug 2015
    Posts
    12
    Thanks given
    0
    Thanks received
    0
    Rep Power
    11
    Any hope of re upload?
    Reply With Quote  
     

  7. #47  
    Registered Member
    Join Date
    Dec 2015
    Posts
    6
    Thanks given
    0
    Thanks received
    0
    Rep Power
    0
    Quote Originally Posted by nMik View Post
    I'm making this a snippet because I really don't feel the need to explain how things work besides the JOptionPane and thats it.

    Base: Project Insanity
    Difficulty: 3.5/10 - need a brain
    Credits:
    93% Myself
    5% Sanity - ideas
    1% I'm a Jerk (help on idea when working with Zepsity)
    1% Jagex for the sprites

    How JOptionPane works: It opens a interface , [Only registered and activated users can see links. ]


    Step 1, Download the sprites [Only registered and activated users can see links. ];Extract the folder into your sprites folder (Client side you derps)

    Step 2, RSInterface.java, client sided.

    Code:
    staffControls(rsFonts);
    and

    Code:
    public static void staffControls(RSFont[] TDA) {
                RSInterface tab = addTabInterface(37000);
                RSInterface scroll = addTabInterface(37002, 2);
                addSprite(37001, 0, "staffControl/backdrop");
                //information box and title 
                addText(37080, "Enter Title", 0xFF981F, false, true, 52, TDA, 2); //Title
                addText(37081, "Information, enter here", 0xFF981F, false, true, 52, TDA, 2); //Information
                addText(37082, "Information, enter here", 0xFF981F, false, true, 52, TDA, 2); //Information
                addText(37083, "Information, enter here", 0xFF981F, false, true, 52, TDA, 2); //Information
                tab.totalChildren(6);
                //Interface
                tab.child(0, 37001, 0, 0);
                tab.child(1, 37002, -147, 80);
                tab.child(2, 37080, 23, 20);
                tab.child(3, 37081, 243, 157);
                tab.child(4, 37082, 243, 187);
                tab.child(5, 37083, 243, 217);
                //information box and title start
                
                //information box and title end
                scroll.width = 312;//312
                scroll.height = 248;//248
                scroll.scrollMax = 785;//735
            
                //buttons themself, in order
                addButton(37011, 0, "staffControl/mod", 116, 26, "Lock Account", 1);
                addButton(37012, 0, "staffControl/mod", 116, 26, "Kick Player", 1);
                addButton(37013, 0, "staffControl/mod", 116, 26, "Mute Player", 1);
                addButton(37014, 0, "staffControl/mod", 116, 26, "Jail Player", 1);
                addButton(37015, 0, "staffControl/mod", 116, 26, "IpMute Player", 1);
                addButton(37016, 0, "staffControl/mod", 116, 26, "Un-Mute Player", 1);
                addButton(37017, 0, "staffControl/mod", 116, 26, "Un-Jail Player", 1);
                addButton(37018, 0, "staffControl/mod", 116, 26, "Check Bank", 1);
                addButton(37019, 0, "staffControl/mod", 116, 26, "Check Inventory", 1);
                addButton(37020, 0, "staffControl/admin", 116, 26, "Announcement", 1);
                addButton(37021, 0, "staffControl/admin", 116, 26, "Ban Player", 1);
                addButton(37022, 0, "staffControl/admin", 116, 26, "Ip-Ban Player", 1);
                addButton(37023, 0, "staffControl/admin", 116, 26, "Teleport to", 1);
                addButton(37024, 0, "staffControl/admin", 116, 26, "Teleport to me", 1);
                addButton(37025, 0, "staffControl/admin", 116, 26, "Un-Ban Player", 1);
                addButton(37026, 0, "staffControl/admin", 116, 26, "Un-IpBan Player", 1);
                addButton(37027, 0, "staffControl/admin", 116, 26, "Un-IpMute Player", 1);
                addButton(37028, 0, "staffControl/admin", 116, 26, "Coming Soon!", 1);
                addButton(37029, 0, "staffControl/admin", 116, 26, "Coming Soon!", 1);
                addButton(37030, 0, "staffControl/admin", 116, 26, "Coming Soon!", 1);
                
                //buttons text, in order
                addText(37050, "Lock", 0xFF981F, false, true, 52, TDA, 2);
                addText(37051, "Kick", 0xFF981F, false, true, 52, TDA, 2);
                addText(37052, "Mute", 0xFF981F, false, true, 52, TDA, 2);
                addText(37053, "Jail", 0xFF981F, false, true, 52, TDA, 2);
                addText(37054, "Ip-Mute", 0xFF981F, false, true, 52, TDA, 2);
                addText(37055, "Un-Mute", 0xFF981F, false, true, 52, TDA, 2);
                addText(37056, "Un-Jail", 0xFF981F, false, true, 52, TDA, 2);
                addText(37057, "Check Bank", 0xFF981F, false, true, 52, TDA, 2);
                addText(37058, "Check Inv", 0xFF981F, false, true, 52, TDA, 2);
                addText(37059, "Announce", 0xFF981F, false, true, 52, TDA, 2);
                addText(37060, "Ban", 0xFF981F, false, true, 52, TDA, 2);
                addText(37061, "Ip-Ban", 0xFF981F, false, true, 52, TDA, 2);
                addText(37062, "Teleport To", 0xFF981F, false, true, 52, TDA, 2);
                addText(37063, "Tele To Me", 0xFF981F, false, true, 52, TDA, 2);
                addText(37064, "Un-Ban", 0xFF981F, false, true, 52, TDA, 2);
                addText(37065, "Un-IpBan", 0xFF981F, false, true, 52, TDA, 2);
                addText(37066, "Un-IpMute", 0xFF981F, false, true, 52, TDA, 2);
                
                scroll.totalChildren(37); 
                //buttons and text start
                scroll.child(0, 37011, 177, 8);
                scroll.child(1, 37012, 177, 47);
                scroll.child(2, 37013, 177, 85);
                scroll.child(3, 37014, 177, 123);
                scroll.child(4, 37015, 177, 161);
                scroll.child(5, 37016, 177, 199);
                scroll.child(6, 37017, 177, 237);
                scroll.child(7, 37018, 177, 275);
                scroll.child(8, 37019, 177, 313);
                scroll.child(9, 37020, 177, 351);
                scroll.child(10, 37021, 177, 389);
                scroll.child(11, 37022, 177, 427);
                scroll.child(12, 37023, 177, 465);
                scroll.child(13, 37024, 177, 503);
                scroll.child(14, 37025, 177, 541);
                scroll.child(15, 37026, 177, 579);
                scroll.child(16, 37027, 177, 617);
                scroll.child(17, 37028, 177, 655);
                scroll.child(18, 37029, 177, 693);
                scroll.child(19, 37030, 177, 731);
                scroll.child(20, 37050, 203, 15);
                scroll.child(21, 37051, 203, 54);
                scroll.child(22, 37052, 203, 92);
                scroll.child(23, 37053, 203, 130);
                scroll.child(24, 37054, 203, 168);
                scroll.child(25, 37055, 203, 207);
                scroll.child(26, 37056, 203, 245);
                scroll.child(27, 37057, 203, 282);
                scroll.child(28, 37058, 203, 321);
                scroll.child(29, 37059, 203, 359);
                scroll.child(30, 37060, 203, 397);
                scroll.child(31, 37061, 203, 435);
                scroll.child(32, 37062, 203, 473);
                scroll.child(33, 37063, 203, 511);
                scroll.child(34, 37064, 203, 550);
                scroll.child(35, 37065, 203, 588);
                scroll.child(36, 37066, 203, 625);
                //buttons and text end
            }

    Step 3, Open up your source folder to "\Source\src\server\model\players"

    Step 4, Create a new .java file called CommandControl.java and put this in it
    Code:
    
    package server.model.players;
    
    import java.util.Arrays;
    import server.core.config.*;
    import server.Server;
    import server.model.players.packets.Commands;
    import server.model.players.*;
    import server.util.Misc;
    import server.net.Connection;
    import javax.swing.*;
    
    /**
      * Made By: Artesia/Nathan
      * 5/14/2012
     **/
    
    public class CommandControl {
    
        public CommandControl(Client c) {
            this.c = c;
        }
    
        private Client c;
        
        public long clickDelay = 0;
    
        public boolean clickButtons(int id) {
            if(System.currentTimeMillis() - clickDelay < 1000) {
                return false;
            }
            clickDelay = System.currentTimeMillis();
            //This is a warning/information message letting you know that you have opened the interface
            if (id == #####)
            {
                JOptionPane.showMessageDialog(null,
                "You have opened up the staff control panel.\n " + "Clicking a commmand will open up a dialouge\n " + "box for you to enter the name of a victom", 
                "Control Information", JOptionPane.INFORMATION_MESSAGE);
                c.getPA().showInterface(37000);
            }
                    //Command start
            if (id == 144148) 
            {
                c.getPA().closeAllWindows();
                if(c.playerRights > 0)
                {
                    String kick = " ";
                    kick = JOptionPane.showInputDialog(null, "Enter the name of the player \n" + "that you wish to kick.", "Kick Player", JOptionPane.WARNING_MESSAGE);
                        try {    
                        for(int i = 0; i < Config.MAX_PLAYERS; i++) {
                            if(Server.playerHandler.players[i] != null) {
                                if(Server.playerHandler.players[i].playerName.equalsIgnoreCase(kick)) {
                                    Server.playerHandler.players[i].disconnected = true;
                                } 
                            }
                        }
                    } catch(Exception e) {
                        c.sendMessage("Incorrect name or invalid player.");
                    }    
                }
                return true;
            }
        }
    }
    Step 5, In client.java add this
    Code:
    public CommandControl commandControl = new CommandControl(this);
    Step 6, In clickingbuttons.java add this
    Code:
    if(c.commandControl.clickButtons(actionButtonId))
                    return;
    Congratulations you have just added this interface:
    Link is down
    Reply With Quote  
     

Page 5 of 5 FirstFirst ... 345

Thread Information
Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)


User Tag List

Similar Threads

  1. Control panel: How do i add a command to it?
    By Runebay™ in forum Help
    Replies: 0
    Last Post: 10-14-2009, 06:26 AM
  2. new pest control interface
    By Poxer in forum Show-off
    Replies: 7
    Last Post: 04-18-2009, 10:33 PM
  3. New Pest Control Interface
    By Scu11 in forum Show-off
    Replies: 12
    Last Post: 03-26-2009, 07:58 PM
Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •