Tribes Quake Announcer

User avatar
S_hift
Posts: 1963
Joined: Fri Dec 23, 2011 1:42 pm

Tribes Quake Announcer

Post by S_hift »

Trying to make a quake announcer. I'm trying to keep it simple so I can copy the block multiple times for different substrings. Right now I just want to get it working for kill sprees. By the way I'd like this to work in a way that if anyone gets a killingspree then I will hear it too. Thats why I want it to be simple.

Simpler means working for both 1.1 and 1.4 clients.

Code: Select all

function onClientMessage(%client, %msg)
   {
    if(%msg == "is on a KILLING SPREE he has 8 kill's in a row!")
        {
        say::public(killingspree);//this is the custom wav i'm trying to play
        }
   }

btw crow, "kill's" shouldn't be possessive they should be plural. Just noticed that typo.
Image <--Click here to subscribe to S_hift's youtube
Click here for full access to all my tribes downloads
User avatar
DaJ4ck3L
Crow{OZ}
Posts: 3375
Joined: Thu Jul 22, 2010 11:51 pm
Contact:

Re: Tribes Quake Announcer

Post by DaJ4ck3L »

it would look something more like this.

Code: Select all

function onClientMessage(%client, %msg)
{
	%me = Client::getName(getManagerId());
	if(String::findSubStr(%msg, %me) != "-1")
	{
		if(String::findSubStr(%msg, "is on a KILLING SPREE") != "-1")
		{
			say(0, "msg goes here ~wsound");
		}
		
		if(String::findSubStr(%msg, "is on an EXTREME KILLING SPREE") != "-1")
		{
			say(0, "msg goes here ~wsound");
		}
	}
}
Image
User avatar
S_hift
Posts: 1963
Joined: Fri Dec 23, 2011 1:42 pm

Re: Tribes Quake Announcer

Post by S_hift »

nice...

Killing Spree: You kill 5 enemies without yourself getting killed
Rampage: You kill 10 enemies
Dominating: You kill 15 enemies
Unstoppable: You kill 20 enemies
Godlike: You kill 25 enemies


I was thinking something more along the lines of

10
20
30
40
50
Image <--Click here to subscribe to S_hift's youtube
Click here for full access to all my tribes downloads
User avatar
S_hift
Posts: 1963
Joined: Fri Dec 23, 2011 1:42 pm

Re: Tribes Quake Announcer

Post by S_hift »

UPDATE

So I just copied an extra block for the Unstoppable KS

Code: Select all

function onClientMessage(%client, %msg)
{
   %me = Client::getName(getManagerId());
   if(String::findSubStr(%msg, %me) != "-1")
   {
      if(String::findSubStr(%msg, "is on a KILLING SPREE") != "-1")
      {
         say(0, "Announcer: KILLING SPREE!!! ~wkillingspree");
      }
      
      if(String::findSubStr(%msg, "is on an EXTREME KILLING SPREE") != "-1")
      {
         say(0, "Announcer: DOMINATING!!! ~wdominating");
      }
	  
      if(String::findSubStr(%msg, "CAN NO ONE STOP") != "-1")
      {
         say(0, "Announcer: UNSTOPPABLE!!! ~wunstoppable");
      }
   }
}
then I'm gonna add headshot sounds to the assassination and fells a shot between the eyes messages. I haven't tested this out, but could I make it bottom print the message instead of publicly say it? like this? would this work, without the typos obv.

if(string::findsubstr(%msg, "can no one stop")!= "-1")
{
printBP(0, "<color red>unstoppable!<colorredend> ~wunstoppable");

or BottomPrint(0, "<color red>unstoppable!<colorredend> ~wunstoppable");
Image <--Click here to subscribe to S_hift's youtube
Click here for full access to all my tribes downloads
User avatar
DaJ4ck3L
Crow{OZ}
Posts: 3375
Joined: Thu Jul 22, 2010 11:51 pm
Contact:

Re: Tribes Quake Announcer

Post by DaJ4ck3L »

it already spams every kill past unstoppable lol. that going to be spam fest.
Image
User avatar
S_hift
Posts: 1963
Joined: Fri Dec 23, 2011 1:42 pm

Re: Tribes Quake Announcer

Post by S_hift »

damn i never though about. i could make it do it after every ten kills then up to 100. how many kills does it take to start unstoppable? and then I'll make it recognize it at every ten kill
Last edited by S_hift on Mon Dec 15, 2014 11:43 am, edited 1 time in total.
Image <--Click here to subscribe to S_hift's youtube
Click here for full access to all my tribes downloads
D4M45T3R
Posts: 69
Joined: Sun May 11, 2014 7:15 am

Re: Tribes Quake Announcer

Post by D4M45T3R »

quake sounds? r u fuken 4real
User avatar
S_hift
Posts: 1963
Joined: Fri Dec 23, 2011 1:42 pm

Re: Tribes Quake Announcer

Post by S_hift »

Code: Select all

function onClientMessage(%client, %msg)
{
   %me = Client::getName(getManagerId());
   if(String::findSubStr(%msg, %me) != "-1")
   {
      if(String::findSubStr(%msg, "is on a KILLING SPREE") != "-1")
      {
         say(0, "Announcer: KILLING SPREE!!! ~wkillingspree");
      }
      
      if(String::findSubStr(%msg, "is on an EXTREME KILLING SPREE") != "-1")
      {
         say(0, "Announcer: DOMINATING!!! ~wdominating");
      }
	  
      if(String::findSubStr(%msg, "35 KILLS IN A ROW") != "-1")
      {
         say(0, "Announcer: UNSTOPPABLE!!! ~wunstoppable");
      }
   }
}

in br annihilation we believe in rewarding the players, not punishing them for running an outdated client.


Edit: I will post the sound files after this is complete and working. I want to add something for headshots and mid air rockets. I know the mod supports headshot damage.

maybe something like this findSubStr %dmg "headshot" I couldnt find anythin my my annihilation mod about headshot damage, but then again its Emeralds version of anni.
Image <--Click here to subscribe to S_hift's youtube
Click here for full access to all my tribes downloads
D4M45T3R
Posts: 69
Joined: Sun May 11, 2014 7:15 am

Re: Tribes Quake Announcer

Post by D4M45T3R »

i hope u realize those aren't quake sounds.
User avatar
DaJ4ck3L
Crow{OZ}
Posts: 3375
Joined: Thu Jul 22, 2010 11:51 pm
Contact:

Re: Tribes Quake Announcer

Post by DaJ4ck3L »

35

and quake pro in for the save!
Image
Post Reply