Skip to content
  • 0 Unread 0
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
Collapse

Plutonium

  1. Home
  2. BO2 Modding Releases & Resources
  3. [MP] HUD Killstreak Counter

[MP] HUD Killstreak Counter

Scheduled Pinned Locked Moved BO2 Modding Releases & Resources
6 Posts 4 Posters 3.8k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • Resxtundefined Offline
    Resxtundefined Offline
    Resxt
    Plutonium Staff
    wrote on last edited by Resxt
    #1

    A simple killstreak counter that displays the player's current kill streak on top of the screen.

    26b278db-d42e-41fa-95d2-53a623b53815-image.png

    All the credits for this script go to Kalitos.
    I just slightly modified and then compiled his IW5 killstreak counter script for T6 and reposted it.

    Download
    Instructions to load the script

    :::

    Source code

    #include maps\mp\gametypes\_hud_util;
    
    Init()
    {
        level thread OnPlayerConnected();
    }
    
    OnPlayerConnected()
    {
        for(;;)
        {
            level waittill("connected", player);
            
            // Don't thread DisplayPlayerKillstreak() on bots
            if (isDefined(player.pers["isBot"]))
            {
                if (player.pers["isBot"])
                {
                    continue; // skip
                }
            }
    
            player thread DisplayPlayerKillstreak();
        }
    }
    
    
    DisplayPlayerKillstreak()
    {
        self endon ("disconnect");
        level endon("game_ended");
    
        self.killstreak_text = createFontString( "DEFAULT" , 1 );
        self.killstreak_text setPoint( 0, "TOP", 0, -25 );
        self.killstreak_text.label = &"^1KILLSTREAK: ";
    
        while(true)
        {
            if(!IsDefined(self.playerstreak) || self.playerstreak != self.pers["cur_kill_streak"])
            {
                self.playerstreak = self.pers["cur_kill_streak"];
                self.killstreak_text setValue(self.pers["cur_kill_streak"]);
            }
    
            wait 0.01;
        }
    }
    

    :::

    IxColdxIundefined 1 Reply Last reply
    7
    • Resxtundefined Resxt

      A simple killstreak counter that displays the player's current kill streak on top of the screen.

      26b278db-d42e-41fa-95d2-53a623b53815-image.png

      All the credits for this script go to Kalitos.
      I just slightly modified and then compiled his IW5 killstreak counter script for T6 and reposted it.

      Download
      Instructions to load the script

      :::

      Source code

      #include maps\mp\gametypes\_hud_util;
      
      Init()
      {
          level thread OnPlayerConnected();
      }
      
      OnPlayerConnected()
      {
          for(;;)
          {
              level waittill("connected", player);
              
              // Don't thread DisplayPlayerKillstreak() on bots
              if (isDefined(player.pers["isBot"]))
              {
                  if (player.pers["isBot"])
                  {
                      continue; // skip
                  }
              }
      
              player thread DisplayPlayerKillstreak();
          }
      }
      
      
      DisplayPlayerKillstreak()
      {
          self endon ("disconnect");
          level endon("game_ended");
      
          self.killstreak_text = createFontString( "DEFAULT" , 1 );
          self.killstreak_text setPoint( 0, "TOP", 0, -25 );
          self.killstreak_text.label = &"^1KILLSTREAK: ";
      
          while(true)
          {
              if(!IsDefined(self.playerstreak) || self.playerstreak != self.pers["cur_kill_streak"])
              {
                  self.playerstreak = self.pers["cur_kill_streak"];
                  self.killstreak_text setValue(self.pers["cur_kill_streak"]);
              }
      
              wait 0.01;
          }
      }
      

      :::

      IxColdxIundefined Offline
      IxColdxIundefined Offline
      IxColdxI
      Contributor
      wrote on last edited by
      #2

      @lResxt This is nice. Thank you Monke King!

      1 Reply Last reply
      0
      • Levelundefined Offline
        Levelundefined Offline
        Level
        Contributor
        wrote on last edited by
        #3

        Sorry for necro'ing but does anyone got this still

        Resxtundefined 1 Reply Last reply
        0
        • Levelundefined Level

          Sorry for necro'ing but does anyone got this still

          Resxtundefined Offline
          Resxtundefined Offline
          Resxt
          Plutonium Staff
          wrote on last edited by
          #4

          @Embolden sorry I forgot to update my post link after deleting my Google account.
          The topic and the download link are updated

          1 Reply Last reply
          1
          • FutureRaveundefined Offline
            FutureRaveundefined Offline
            FutureRave
            VIP
            wrote on last edited by
            #5

            I think the & is overkill since KILLSTREAK is not a localized string.

            1 Reply Last reply
            0
            • FutureRaveundefined Offline
              FutureRaveundefined Offline
              FutureRave
              VIP
              wrote on last edited by
              #6

              Nevermind, apparently the game goes schizo without &

              1 Reply Last reply
              0

              Hello! It looks like you're interested in this conversation, but you don't have an account yet.

              Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

              With your input, this post could be even better 💗

              Register Login
              Reply
              • Reply as topic
              Log in to reply
              • Oldest to Newest
              • Newest to Oldest
              • Most Votes


              • Login

              • Don't have an account? Register

              • Login or register to search.
              • First post
                Last post
              0
              • Unread 0
              • Recent
              • Tags
              • Popular
              • Users
              • Groups