Author Topic: "Base Under Attack"Sound?  (Read 6747 times)

Shifty

  • Posts: 75
  • Turrets: +0/-0
"Base Under Attack"Sound?
« on: July 21, 2010, 08:33:56 am »
You know how when aliens attack human rc you get that cp message or what ever it is "Base under attack!"? Would it be possible to, through a client side mod, add sound to this like on aliens? Like...what are the files governing this and all?

Demolution

  • Posts: 1198
  • Turrets: +157/-64
Re: "Base Under Attack"Sound?
« Reply #1 on: July 21, 2010, 11:16:15 am »
There is a sound like that already. It's "The Overmind is under attack!"
>.> Play more.

Clan [AC] - For all your air conditioning needs please visit: http://s1.zetaboards.com/AC_NoS/index/
my brain > your brain.
and i am VERY stupid.

Plague Bringer

  • Posts: 3815
  • Turrets: +147/-187
Re: "Base Under Attack"Sound?
« Reply #2 on: July 21, 2010, 01:36:06 pm »
Quote
You know how when aliens attack human rc you get that cp message or what ever it is "Base under attack!"? Would it be possible to, through a client side mod, add sound to this like the sound that's played on aliens? Like...what are the files governing this and all?
no clue/good idea/there's probably a reason devs decided to do it this way
U R A Q T

gimhael

  • Posts: 546
  • Turrets: +70/-16
Re: "Base Under Attack"Sound?
« Reply #3 on: July 21, 2010, 02:42:03 pm »
When a human building in range of the DC is hit, the game qvm creates an event of type EV_DCC_ATTACK. In the cgame qvm, in file cg_envent.c this event is handled:

Code: [Select]
   case EV_DCC_ATTACK:
      if( cg.predictedPlayerState.stats[ STAT_TEAM ] == TEAM_HUMANS )
      {
        //trap_S_StartLocalSound( cgs.media.humanDCCAttack, CHAN_ANNOUNCER );
        CG_CenterPrint( "Our base is under attack!", 200, GIANTCHAR_WIDTH * 4 );
      }
      break;

So apparently the devs intended to play a sound here, but the sound was commented out later (due to a lack of a sound file ?). So you just have to remove the comment markers and register an appropriate sound (modify cg_local.h and cg_main.h).

Shifty

  • Posts: 75
  • Turrets: +0/-0
Re: "Base Under Attack"Sound?
« Reply #4 on: July 21, 2010, 09:23:45 pm »
There is a sound like that already. It's "The Overmind is under attack!"
>.> Play more.
:facepalm: I said..FOR THE HUMAN RC....LIKE on ALIENS..I already know there is one for aliens...I just want to replicate that on humans.

Thanks gimhael...so I assume this would mean I would need to write a custom qvm to get this to work?

F50

  • Posts: 740
  • Turrets: +16/-26
Re: "Base Under Attack"Sound?
« Reply #5 on: July 22, 2010, 03:36:26 am »
Yes, although with the commented code and such it should be incredibly trivial once you have a sound file.
"Any sufficiently advanced stupidity is indistinguishable from malice." -- Grey's Law


SlackerLinux

  • Spam Killer
  • *
  • Posts: 555
  • Turrets: +41/-62
Re: "Base Under Attack"Sound?
« Reply #6 on: July 22, 2010, 03:43:07 am »
the humans also get a message if their spawn nodes are attacked aliens get it for their overmind but dont get the warning for eggs the rc currently doesnt give any warnings(unless if this has changed in 1.2)

the aliens really need the rc to give no warning its hard enough to get it down w/out the attack being broadcast out. they dont have range like the humans do they have to actually get on it
Slackware64 13.1
SlackersQVM/

Shifty

  • Posts: 75
  • Turrets: +0/-0
Re: "Base Under Attack"Sound?
« Reply #7 on: July 24, 2010, 12:49:48 pm »
So theoretically, you could make things a whole lot easier for you (and cheat) by adding code to give warnings for arms, meds, rc, nodes, eggs, om, and anything important?

David

  • Spam Killer
  • *
  • Posts: 3543
  • Turrets: +249/-273
Re: "Base Under Attack"Sound?
« Reply #8 on: July 24, 2010, 01:20:31 pm »
It's a cgame change, so the server would have to OK it or you'd have to cheat, same as with aimbots etc etc.
Any maps not in the MG repo?  Email me or come to irc.freenode.net/#mg.
--
My words are mine and mine alone.  I can't speak for anyone else, and there is no one who can speak for me.  If I ever make a post that gives the opinions or positions of other users or groups, then they will be clearly labeled as such.
I'm disappointed that people's past actions have forced me to state what should be obvious.
I am not a dev.  Nothing I say counts for anything.

UniqPhoeniX

  • Spam Killer
  • *
  • Posts: 1376
  • Turrets: +66/-32
Re: "Base Under Attack"Sound?
« Reply #9 on: July 25, 2010, 06:54:21 am »
But basically the client already receives information from server about base status, more then the "Base is under attack"? If yes, fail.

gimhael

  • Posts: 546
  • Turrets: +70/-16
Re: "Base Under Attack"Sound?
« Reply #10 on: July 25, 2010, 07:53:57 am »
No.