Community made patches and improvements

Developer discussion of experimental fixes, changes, and improvements.

Moderators: Nexuiz Moderators, Moderators

Postby MirceaKitsune » Mon Jan 05, 2009 10:30 am

I made my first code patch in the server code today and implemented something I wanted to see in for some time; A system for auto taunts when a player scores a kill. This patch implements auto-taunting if the user has voice volume turned on, and each time someone scores a frag against someone else they also speak a taunt for everyone to hear. As I said in this topic, I believe the game has gotten to a point where auto-taunts would be very welcome for the atmosphere.

Initially I wanted to make a separate cvar switch so anyone could manually turn taunts on or off from their client with a checkbox in the Audio menu, but the implementation of this is in the server code which means such a cvar would act as a server setting, not a client one so a switch cannot seem be implemented client-side. Taunts can be individually turned off by muting Voice in Audio settings instead, which works perfectly well and does what it should so I believe this should not be a problem for anyone who doesn't want to hear them for now.

Patch can be found HERE as file or HERE as text. This is my first C code patch for the game which took me quite a try to make so please correct any messy code I might have used. I tested this locally and it works just as it should in both DM and team games (haven't tested it in multiplayer between players but that should be ok as well). Hope the patch is good and can get in, I'm sure many would love taunts a lot as well :)

[EDIT] Updated the patch and added a cvar for it even if server side. The cvar works as a probability factor since playing a taunt each time someone frags is annoying. This switch both avoids annoyance with excessive taunts and offers a way to turn auto taunting off if someone wants to disable them on the server. Once again, this is better as a client setting if someone figures a way to make this client and not server based someday. For the current number of taunt voices per player, I set it 0.65 (65% probability of taunting per frag) but this should probably be increased a bit when there will be many taunt voices.

[EDIT2] Made the feature client-side which means auto taunting can now be individually enabled or disabled by anyone, including the probability factor. The code is still server-side but taunts are now sent and played only to those who have the cl_autotaunt cvar above 0 and no one else, so now this is exactly as it should be now. Re-download from the same links in this post.
MirceaKitsune
Keyboard killer
 
Posts: 593
Joined: Thu Aug 14, 2008 6:48 am
Location: Romania - Bucharest

Postby MirceaKitsune » Wed Jan 07, 2009 1:44 am

Made two more patches today which I posted as separate files. The first one implements a switch for the beep indicator that is heard when hitting someone. What this patch does is simply cvar the hit beeps so they can be disabled from the Audio menu for those who don't want to hear them when they hit other players. Still enabled by default of course. PATCH FILE and PATCH TEXT here.

The second patch is a set of misc changes, most of them more menu cleaning and arranging... take what you believe is right. FILE and TEXT patch. Changes in it include:

- A tiny change to the auto-taunt system I forgot... made a float local just to be on the safe side.

- Changed the checkbox for auto-taunts in Audio and put a description on the slider and arranged it better.

- Added 9 choices to map voting in the Create menu rather then 7. The new map voting screen allows 9 vote choices on 3 lines so I thought it would be best suited as that.

- Moved Network Speed and Client UDP Port from Player Setup to the Misc menu. I thought that such network options don't belong in Player Setup as that menu is about configuring your character, weapons, HUD, etc. and Misc would be the most suited place for it. Also relieves the Player Setup menu a bit.

- Changed the maximum value for Decals Time in Effects to 15 from 20. 20 was indeed a bit too much even for fast computers and also made maps too messy at times, but 15 seems the most reasonable max. setting.

- Removed the Coronas checkbox from the Effects menu. I don't think there's any use for it at this point as no one would have much of a reason to turn coronas off these days and none of the official maps use them either way so it didn't have a good purpose. If someone really needs to disable them they can set the cvar manually.
MirceaKitsune
Keyboard killer
 
Posts: 593
Joined: Thu Aug 14, 2008 6:48 am
Location: Romania - Bucharest

Postby Alien » Wed Jan 07, 2009 8:27 am

Coronas(-ae) are used by explosions and light sources.

Image
Alien
Forum addon
 
Posts: 1212
Joined: Tue Apr 22, 2008 7:12 am

Postby MirceaKitsune » Wed Jan 07, 2009 10:50 am

Sorry then, wasn't sure if they were used for that as well. I thought there wouldn't be much of a reason for anyone to disable them from the menus as they don't block the view much nor cause any performance issues.

Anyway I seen Div made the taunt system act directionally in the latest version. If I may ask for that I would like to undo that change because directional taunts are against the purpose of what I made them to be. The taunts are made to act similar to UT's, through the "radio station" and for everyone in the map to hear no matter how far they are. When someone would taunt in the radio they wouldn't check how close or far other players are and taunt globally instead. So if there's no strong reason for that please make them non-directional again... in case there's too many voices they can have their frequency decreased from the Audio menu, this change brakes the taunts from what I intended them as. Here's the small PATCH to make them back again if they may be reverted please.
MirceaKitsune
Keyboard killer
 
Posts: 593
Joined: Thu Aug 14, 2008 6:48 am
Location: Romania - Bucharest

Postby divVerent » Wed Jan 07, 2009 11:27 am

Well, making them directional was so one can hear who the taunts come from.

I set them to the lowest possible attenuation, so they should sound similarily loud at about every distance on most maps. It only diminshes at a distance of 128000, which is higher than the map compiler even supports.

If this is wrong and they do sound less loud at a distance, this is an engine bug and will get fixed.
1. Open Notepad
2. Paste: ÿþMSMSMS
3. Save
4. Open the file in Notepad again

You can vary the number of "MS", so you can clearly see it's MS which is causing it.
divVerent
Site admin and keyboard killer
 
Posts: 3809
Joined: Thu Mar 02, 2006 4:46 pm
Location: BRLOGENSHFEGLE

Postby MirceaKitsune » Wed Jan 07, 2009 11:45 am

divVerent wrote:Well, making them directional was so one can hear who the taunts come from.

I set them to the lowest possible attenuation, so they should sound similarily loud at about every distance on most maps. It only diminshes at a distance of 128000, which is higher than the map compiler even supports.

If this is wrong and they do sound less loud at a distance, this is an engine bug and will get fixed.


I see now. The difference is that they're set to work as global radio, and hearing them directionally would feel as if the taunts are spoken out loud (at an impossible distance) rather then in a normal radio, and that would not be as suited for them I think. Either way I tested them more and it seems this also causes taunts to not be played at all for players who fragged a few meters away from you, and taunts now play only if the frag takes place nearby so this brakes them. Also the directional taunts sound badly imho, I personally found them irritating to the ear after testing them with many bots. I'd be happy if they could remain with an atten_none as they're much better that way I believe... directional ones will likely sound badly for most people and not many would want them.
MirceaKitsune
Keyboard killer
 
Posts: 593
Joined: Thu Aug 14, 2008 6:48 am
Location: Romania - Bucharest

Postby divVerent » Wed Jan 07, 2009 12:09 pm

How would you then know who they are coming from?

And they apparently coming from the wrong player may be caused by another code change I did, as they weren't even written to the right msg_entity before.
1. Open Notepad
2. Paste: ÿþMSMSMS
3. Save
4. Open the file in Notepad again

You can vary the number of "MS", so you can clearly see it's MS which is causing it.
divVerent
Site admin and keyboard killer
 
Posts: 3809
Joined: Thu Mar 02, 2006 4:46 pm
Location: BRLOGENSHFEGLE

Postby MirceaKitsune » Wed Jan 07, 2009 1:05 pm

divVerent wrote:How would you then know who they are coming from?


I don't think one always needs to know who they are coming from, and if someone really wants to they can look at who made the last frag if the map isn't too crowded. Usually you see who they're from if the player who frags is in your area. But that wouldn't always work either... if the player is many walls away from you and frags you don't get to see who he / she is for example, just where the taunt is coming from which doesn't help much.

Anyway I made a patch to choose between directional and non-directional taunts with a cvar (cl_autotaunt_directional), including a checkbox in the menu for it so everyone can choose if to have directional taunts or not. This seems the most fair choice I think, both for those who want directional voices and those who don't. Patch LINK 1 and LINK 2.
MirceaKitsune
Keyboard killer
 
Posts: 593
Joined: Thu Aug 14, 2008 6:48 am
Location: Romania - Bucharest

Postby divVerent » Thu Jan 08, 2009 10:46 am

Refused that patch, and instead fixed the root issue.

Now, there is a "headphone friendly mode" you should use. It reduces spatialization depending on distance, so you never hear the taunts e.g. just on a single ear.
1. Open Notepad
2. Paste: ÿþMSMSMS
3. Save
4. Open the file in Notepad again

You can vary the number of "MS", so you can clearly see it's MS which is causing it.
divVerent
Site admin and keyboard killer
 
Posts: 3809
Joined: Thu Mar 02, 2006 4:46 pm
Location: BRLOGENSHFEGLE

Postby MirceaKitsune » Thu Jan 08, 2009 11:37 am

divVerent wrote:Refused that patch, and instead fixed the root issue.

Now, there is a "headphone friendly mode" you should use. It reduces spatialization depending on distance, so you never hear the taunts e.g. just on a single ear.


The headphone friendly mode is much better indeed, although I think the volume is still lower at a distance for the taunts. Either way I still believe there should be a way to turn them off, radio voices sound very different directionally then non-directionally no matter how they are tweaked or optimized. To me they now sound as if someone is speaking the taunts from their location, not a radio any more. Many will certainly want to disable them, and I don't see anything wrong in applying the above patch to allow them to do that if they wish.

If you don't want to implement the full patch maybe you can just implement the cvar, even if it will be enabled or disabled by default or not have a checkbox in the Audio menu. That cvar is all I ask for... I hope I'm not being too hard headed on this, its just that it took me a full day of work to make the auto-voice system as I intended and feel as if this makes them something completely different from what they should be, and don't sound good at all either. That cvar doesn't hurt anyone, and it's an option which will surely be used by many people. I'm certain that in the future many players would request a switch for the directional taunts anyway. So if you want to please implement that cvar at least, to give an alternative to those who want them in the original way.

btw, the Headphone Friendly Mode has a small issue and doesn't stick between game restarts and also turns itself off once you apply it and revisit the menu.
MirceaKitsune
Keyboard killer
 
Posts: 593
Joined: Thu Aug 14, 2008 6:48 am
Location: Romania - Bucharest

PreviousNext

Return to Nexuiz - Development

Who is online

Users browsing this forum: No registered users and 1 guest

cron