Jump to content

Search the Community

Showing results for tags 'killstreak'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • RuneLocus
    • News & Announcements
    • Information Booth
    • Website Support
    • Introductions
    • Chat
    • Forum Games
  • RuneScape Development
    • RSPS General
    • RuneScape Private Server (RS2)
    • RuneScape Private Server (503+)
    • RuneScape Private Server (EoC 742+)
  • Other
    • Digital Art
    • Gaming
    • Webdevelopment
    • Computers
  • Marketplace
    • RuneScape Market
    • RSPS Market
    • Others Market
    • Freelance Middleman Services
  • Super Secret Club's Topics

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Found 2 results

  1. Before you continue reading this; this is a VERY simple killstreak system, not 100% sure if I would call it a system even, but it might help out someone. First "tutorial" don't hate! :) I will not explain something, since I don't really think it's needed here... Difficulty: 1/10 Copy and Paste First open up [B]PLAYER.JAVA[/B] src>com>game>player Search for this [QUOTE]private int killCount[/QUOTE] and you should find something like this: [QUOTE]private int killCount, deathCount; private ChargesManager charges;[/QUOTE] under int killCount add this: [QUOTE]private int killStreak;[/QUOTE] Now still in [B]PLAYER.JAVA[/B] find [QUOTE]public int getKillCount() { return killCount; }[/QUOTE] under that add: [QUOTE]public int getKillStreak() { return killStreak; }[/QUOTE] Now find [QUOTE]public int setKillCount(int killCount) { return this.killCount = killCount; }[/QUOTE] Under that add: [QUOTE]public int setKillStreak(int killStreak) { return this.killStreak = killStreak; }[/QUOTE] Now, find this: [QUOTE]public void increaseKillCount(Player killed) {[/QUOTE] Under [QUOTE]killcount++[/QUOTE] add [QUOTE]killStreak++;[/QUOTE] and under [QUOTE]killed.deathCount++;[/QUOTE] add [QUOTE]killed.setKillStreak(0);[/QUOTE] Okey, so now if you want, you can add something like this: [QUOTE]if (killStreak == 10) World.sendWorldMessage("<col=fff800>"+ getDisplayName() +" is on a 10 killstreak, pretty decent i guess...", false);[/QUOTE] Which basically sends a "world" message to everyone online that one player is on a 10 killstreak! And in player commands you can add [QUOTE]if (cmd[0].equals("checkks")) { player.getPackets().sendGameMessage("You are on a "+ player.getKillStreak() +" killstreak"); return true; }[/QUOTE] if you want to :)
  2. [CENTER]Alright, so I felt like contributing to the community by releasing a simple KillStreak system Keyword "Simple" So if ya rage that this isn't what you expected then you may leave this thread now. If Not Then Lets Proceed. Requirements To Add This: Copy And Pasting Skills A Brain Ok So Lets Start In: Client.java (This is rather optional. This Adds The Killstreak Text In Your Quest Tab. So Find: Your Quest Tab Info Should Start At: 29155 If Not Find It: And within those add: [CODE] getPA().sendFrame126("KillStreak:"+Streak+" ", 29168); [/CODE] Ok Now In Player.java Find Where Your Public Ints Are: EX: [CODE] public int leechSpecialDelay; public int curseDefence = 0; public int curseAttack = 0;[/CODE] And Add: [CODE] public int Streak; [/code] Ok so this right here handles when a player dies it adds +1 Streak To Your Quest Tab and resets when you die. In PlayerAssistant: Find: [CODE] if (Server.playerHandler.players[c.killerId].connectedFrom.equals(Server.playerHandler.players[c.playerKilled].connectedFrom)) {[/CODE] Or it more simple terms find where your kill messages are handled and add: [CODE] o.Streak += 1; [/CODE] Now Find: [CODE] c.sendMessage("Oh dear you are dead!"); [/code] And Under It Add: [CODE] c.Streak = 0; [/CODE] Ok now time for saving: In PlayerSave.java Find: [CODE] } else if (token.equals("Altar")) { p.altarPrayed = Integer.parseInt(token2);[/CODE] Under that ^ Add [CODE] } else if(token.equals("Streak")) { p.Streak = Integer.parseInt(token2);[/CODE] Still In PlayerSave.java Find: [CODE] characterfile.write("isDonator = ", 0, 12); characterfile.write(Integer.toString(p.isDonator), 0, Integer.toString(p.isDonator).length());[/CODE] Under That ^ Add: [CODE] characterfile.write("Streak = ", 0, 16); characterfile.write(Integer.toString(p.Streak), 0, Integer.toString(p.Streak).length());[/CODE] Now For Rewards. Go To Commands.java Add This Command: [CODE] if (playerCommand.startsWith("redeem")) { if (c.inWild()) return; for (int j = 0; j < c.playerEquipment.length; j++) { //5+ = Reward if (c.cStreak > 4) { c.sendMessage("Congratulations You Have Redeemed Your Kill Streak Reward."); //Reward Item c.getItems().addItem(995, 10000); return; } } try { //Under 5 = No Reward int cStreak = 0; c.sendMessage("Your Kill Streak Isn't High Enough For Reward."); } catch (Exception e){} }[/CODE] Remember this was a simple made system if you want to improve it go ahead. If you feel that I deserve a thanks hit that button :)[/CENTER]
×