Merge in xonotic/xonotic-data.pk3dir.git: mand1nga/bot-misc-fixes
git-manager created issue #407 (closed) on 2011-04-11T12:26:38Z:
Purpose of the branch:
Bots: Fix divide by zero error when using the nex (http://dev.xonotic.org/issues/239). Also made them able to charge the nex. Tested with tZork and Samual balances.
Repository: xonotic/xonotic-data.pk3dir.git Commit: 25e0877a Branch: mand1nga/bot-misc-fixes
Merge commands:
cd data/xonotic-data.pk3dir
git checkout master
git reset --hard origin/master
git pull && git diff '25e0877a52566a8dd940991461fe3d994666f5c5'..'origin/mand1nga/bot-misc-fixes'
git merge --no-ff 'origin/mand1nga/bot-misc-fixes'
git push && git push --delete origin 'mand1nga/bot-misc-fixes'
Diffstat:
qcsrc/server/w_nex.qc | 9 +++++++--
1 files changed, 7 insertions(+), 2 deletions(-)
Revision log:
commit 25e0877a52566a8dd940991461fe3d994666f5c5
Author: mand1nga
Commit: mand1nga
Bots: Fix divide by zero error when using the nex. Made them able to charge the nex.
User agreed to the GPLv2*.
Diff:
<pre>diff —git a/qcsrc/server/w\_nex.qc b/qcsrc/server/w\_nex.qc
index a0fce6a..2d5ea6a 100644
— a/qcsrc/server/w\_nex.qc
**+ b/qcsrc/server/w\_nex.qc
@ -87,8 +87,13
@ float w\_nex
float ammo\_amount;
if
{
- self.BUTTON_ATCK = bot_aim;
- self.BUTTON_ATCK2 = bot_aim;
- if(bot_aim(1000000, 0, 1, FALSE))
- self.BUTTON_ATCK = TRUE;
- else
- {
- if(autocvar_g_balance_nex_charge)
- self.BUTTON_ATCK2 = TRUE;
- } } else if (req == WR_THINK) {