Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import java.awt.*;
- import java.awt.event.*;
- import javax.swing.*;
- import javax.swing.border.*;
- import org.rsbot.script.Script;
- import org.rsbot.script.ScriptManifest;
- @ScriptManifest(authors = "Radioactive", keywords = {"Other"}, name = "iSing", version = 1.0, description = "This will sing songs for you.")
- public class iSing extends Script {
- private final String Song1[] = { "Song: Rick Astley - Never gonna give you up", "We’re no strangers to love,",
- "You know the rules and so do I", "A full commitment’s what I’m thinking of,",
- "You wouldnt get this from any other guy", "I just wanna tell you how I’m feeling,",
- "Gotta make you understand...", "Never gonna give you up,",
- "Never gonna let you down,", "Never gonna run around and desert you",
- "Never gonna make you cry,", "Never gonna say goodbye,",
- "Never gonna tell a lie and hurt you","We’ve known each other for so long",
- "Your heart’s been aching", "But you’re too shy to say it",
- "Inside we both know what’s been going on,", "We know the game and we’re gonna play it",
- "And if you ask me how I’m feeling,", "Don’t tell me you’re too blind to see...",
- "Never gonna give you up,", "Never gonna let you down,",
- "Never gonna run around and desert you", "Never gonna make you cry,",
- "Never gonna say goodbye,", "Never gonna tell a lie and hurt you",
- "Never gonna give you up,", "Never gonna let you down,",
- "Never gonna run around and desert you", "Never gonna make you cry,",
- "Never gonna say goodbye,", "Never gonna tell a lie and hurt you",
- "Never gonna give you up,", "Never gonna let you down,",
- "Never gonna run around and desert you", "Never gonna make you cry,",
- "Never gonna say goodbye,", "Never gonna tell a lie and hurt you",
- "We’ve known each other for so long", "Your heart’s been aching",
- "But you’re too shy to say it", "Inside we both know what’s been going on,",
- "We know the game and we’re gonna play it", "I just wanna tell you how I’m feeling,",
- "Gotta make you understand...", "Never gonna give you up,",
- "Never gonna let you down,", "Never gonna run around and desert you",
- "Never gonna make you cry,", "Never gonna say goodbye,",
- "Never gonna tell a lie and hurt you","Never gonna give you up,",
- "Never gonna let you down,", "Never gonna run around and desert you",
- "Never gonna make you cry,", "Never gonna say goodbye,",
- "Never gonna tell a lie and hurt you" };
- private final String Song2[] = { "Song: Justin Bieber - One time", "Me plus you, I'ma tell you one time",
- "Me plus you, I'ma tell you one time", "Me plus you, I'ma tell you one time", "One time, one time",
- "When I met you girl my heart went knock knock", "Now them butterflies in my stomach won't stop stop",
- "And even though it's a struggle love is all we got", "And we gon' keep keep climbing to the mountain top",
- "Your world is my world", "And my fight is your fight",
- "My breath is your breath", "And your heart",
- "And girl you're my one love, my one heart", "My one life for sure",
- "Let me tell you one time", "I'ma tell you one time",
- "And I'ma be your one guy", "You'll be my number one girl",
- "Always making time for you", "I'ma tell you one time",
- "I'ma tell you one time", "You look so deep, you know that it humbles me",
- "You're by my side, them troubles them not trouble me", "Many have called but the chosen is you",
- "Whatever you want shawty I'll give it to you", "Your world is my world",
- "And my fight is your fight", "My breath is your breath",
- "And your heart", "And girl you're my one love, my one heart",
- "My one life for sure", "Let me tell you one time",
- "I'ma tell you one time", "And I'ma be your one guy",
- "You'll be my number one girl", "Always making time for you",
- "I'ma tell you one time", "I'ma tell you one time",
- "Shawty right there", "She's got everything I need",
- "And I'ma tell her one time", "Give you everything you need down to my last dime",
- "She makes me happy", "I know where I'll be",
- "And girl you're my one love, my one heart", "My one life for sure",
- "Let me tell you one time", "I'ma tell you one time",
- "And I'ma be your one guy", "You'll be my number one girl",
- "Always making time for you", "I'ma tell you one time",
- "I'ma tell you one time", "Me plus you, I'ma tell you one time",
- "Me plus you, I'ma tell you one time", "Me plus you, I'ma tell you one time",
- "One time, one time" };
- Gui gui;
- @Override
- public boolean onStart() {
- gui = new Gui();
- gui.setVisible(true);
- return true;
- }
- @Override
- public int loop() {
- if (gui.startClicked) {
- Song();
- gui.startClicked = false;
- }
- return 3000;
- }
- public void Song() {
- final String[] song;
- switch (gui.ComboBox1.getSelectedIndex()) {
- case 0:
- song = Song1;
- break;
- case 1:
- song = Song2;
- break;
- default:
- return;
- }
- for (final String line : song) {
- keyboard.sendText(line, true);
- sleep(500, 1500);
- }
- }
- @SuppressWarnings("serial")
- public class Gui extends JFrame {
- public Gui() {
- initComponents();
- }
- private boolean startClicked = false;
- private JButton Start;
- private JButton Pause;
- private JButton Switch;
- private JLabel Text;
- private JLabel Color;
- private JLabel Effect;
- private JComboBox ComboBox1;
- private JComboBox ComboBox2;
- private JComboBox ComboBox3;
- private JLabel label3;
- @SuppressWarnings("unused")
- private void initComponents() {
- Start = new JButton();
- Pause = new JButton();
- Switch = new JButton();
- Text = new JLabel();
- Color = new JLabel();
- Effect = new JLabel();
- ComboBox1 = new JComboBox();
- ComboBox2 = new JComboBox();
- ComboBox3 = new JComboBox();
- label3 = new JLabel();
- setResizable(false);
- setTitle("iSing");
- Container contentPane = getContentPane();
- contentPane.setLayout(null);
- Start.setText("Start");
- Start.setBorder(new MatteBorder(1, 1, 1, 1, java.awt.Color.black));
- contentPane.add(Start);
- Start.setBounds(5, 5, 75, 25);
- Start.addActionListener(new ActionListener() {
- public void actionPerformed(ActionEvent e) {
- startClicked = true;
- }
- );
- Pause.setText("Pause");
- Pause.setBorder(new MatteBorder(1, 1, 1, 1, java.awt.Color.black));
- Pause.setEnabled(false);
- contentPane.add(Pause);
- Pause.setBounds(5, 35, 75, 25);
- Switch.setText("Switch World");
- Switch.setBorder(new MatteBorder(1, 1, 1, 1, java.awt.Color.black));
- Switch.setEnabled(false);
- contentPane.add(Switch);
- Switch.setBounds(5, 65, 75, 25);
- Text.setText("Text:");
- Text.setFont(Text.getFont().deriveFont(Text.getFont().getStyle() | Font.ITALIC));
- contentPane.add(Text);
- Text.setBounds(new Rectangle(new Point(85, 10), Text.getPreferredSize()));
- Color.setText("Color:");
- Color.setFont(Color.getFont().deriveFont(Color.getFont().getStyle() | Font.ITALIC));
- contentPane.add(Color);
- Color.setBounds(new Rectangle(new Point(85, 40), Color.getPreferredSize()));
- Effect.setText("Effect:");
- Effect.setFont(Effect.getFont().deriveFont(Effect.getFont().getStyle() | Font.ITALIC));
- contentPane.add(Effect);
- Effect.setBounds(new Rectangle(new Point(85, 70), Effect.getPreferredSize()));
- ComboBox1.setModel(new DefaultComboBoxModel(new String[] {
- "Never Gonna Give You Up",
- "One Time"
- }));
- ComboBox1.setBorder(new MatteBorder(1, 1, 1, 1, java.awt.Color.black));
- contentPane.add(ComboBox1);
- ComboBox1.setBounds(125, 5, 160, 25);
- ComboBox2.setEnabled(false);
- ComboBox2.setModel(new DefaultComboBoxModel(new String[] {
- "Yellow",
- "Red",
- "Green",
- "Purple",
- "Cyan",
- "White",
- "Flash 1",
- "Flash 2",
- "Flash 3",
- "Glow 1",
- "Glow 2",
- "Glow 3",
- "[Random]"
- }));
- ComboBox2.setBorder(new MatteBorder(1, 1, 1, 1, java.awt.Color.black));
- contentPane.add(ComboBox2);
- ComboBox2.setBounds(125, 35, 160, 25);
- ComboBox3.setEnabled(false);
- ComboBox3.setModel(new DefaultComboBoxModel(new String[] {
- "None",
- "Wave",
- "Wave 2",
- "Scroll",
- "Slide",
- "Shake",
- "Scramble",
- "[Random]"
- }
- )
- );
- ComboBox3.setBorder(new MatteBorder(1, 1, 1, 1, java.awt.Color.black));
- contentPane.add(ComboBox3);
- ComboBox3.setBounds(125, 65, 160, 25);
- label3.setText("iSing by: Radioactive");
- contentPane.add(label3);
- label3.setBounds(new Rectangle(new Point(5, 95), label3.getPreferredSize()));
- {
- Dimension preferredSize = new Dimension();
- for(int i = 0; i < contentPane.getComponentCount(); i++) {
- Rectangle bounds = contentPane.getComponent(i).getBounds();
- preferredSize.width = Math.max(bounds.x + bounds.width, preferredSize.width);
- preferredSize.height = Math.max(bounds.y + bounds.height, preferredSize.height);
- }
- Insets insets = contentPane.getInsets();
- preferredSize.width += insets.right;
- preferredSize.height += insets.bottom;
- contentPane.setMinimumSize(preferredSize);
- contentPane.setPreferredSize(preferredSize);
- }
- setSize(295, 140);
- setLocationRelativeTo(getOwner());
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement