Convert sources from SHIFT-JIS to UTF-8.

SHIFT-JIS was common in 19990, but in 2017 it's just annoying. Convert
the source files with `nkf $file > ${file}_new && mv ${file}_new $file`.
This commit is contained in:
Yamagi Burmeister 2017-11-05 12:57:45 +01:00
parent 1e20e30e61
commit c160418e06
17 changed files with 193 additions and 193 deletions

View file

@ -7,19 +7,19 @@ void droptofloor (edict_t *ent);
edict_t *bot_team_flag1; edict_t *bot_team_flag1;
edict_t *bot_team_flag2; edict_t *bot_team_flag2;
void SetBotFlag1(edict_t *ent) //チーム1の旗 void SetBotFlag1(edict_t *ent) //チーム1の旗
{ {
bot_team_flag1 = ent; bot_team_flag1 = ent;
} }
void SetBotFlag2(edict_t *ent) //チーム2の旗 void SetBotFlag2(edict_t *ent) //チーム2の旗
{ {
bot_team_flag2 = ent; bot_team_flag2 = ent;
} }
edict_t *GetBotFlag1() //チーム1の旗 edict_t *GetBotFlag1() //チーム1の旗
{ {
return bot_team_flag1; return bot_team_flag1;
} }
edict_t *GetBotFlag2() //チーム2の旗 edict_t *GetBotFlag2() //チーム2の旗
{ {
return bot_team_flag2; return bot_team_flag2;
} }
@ -51,7 +51,7 @@ void SpawnItem2 (edict_t *ent, gitem_t *item)
//===================================== //=====================================
// //
// BOT用可視判定 // BOT用可視判定
// //
qboolean Bot_trace (edict_t *ent,edict_t *other) qboolean Bot_trace (edict_t *ent,edict_t *other)
@ -140,7 +140,7 @@ qboolean Bot_traceY (edict_t *ent,edict_t *other)
} }
// //
// BOT用可視判定 2 // BOT用可視判定 2
// //
qboolean Bot_trace2 (edict_t *ent,vec3_t ttz) qboolean Bot_trace2 (edict_t *ent,vec3_t ttz)
@ -157,7 +157,7 @@ qboolean Bot_trace2 (edict_t *ent,vec3_t ttz)
} }
// //
// BOT用可視判定 3 // BOT用可視判定 3
// //
qboolean Bot_traceS (edict_t *ent,edict_t *other) qboolean Bot_traceS (edict_t *ent,edict_t *other)
@ -225,7 +225,7 @@ WATERMODE:
// //
// VEC値からyawを得る // VEC値からyawを得る
// //
float Get_yaw (vec3_t vec) float Get_yaw (vec3_t vec)
@ -266,7 +266,7 @@ float Get_pitch (vec3_t vec)
} }
// //
// VEC値とyaw値の角度差を得る // VEC値とyaw値の角度差を得る
// //
float Get_vec_yaw (vec3_t vec,float yaw) float Get_vec_yaw (vec3_t vec,float yaw)
@ -283,7 +283,7 @@ float Get_vec_yaw (vec3_t vec,float yaw)
return vecsyaw; return vecsyaw;
} }
//yaw に対するvecの相対 //yaw に対するvecの相対
float Get_vec_yaw2 (vec3_t vec,float yaw) float Get_vec_yaw2 (vec3_t vec,float yaw)
{ {
float vecsyaw; float vecsyaw;

View file

@ -86,9 +86,9 @@ void BotEndServerFrame (edict_t *ent);
void Bots_Move_NORM (edict_t *ent); //normal AI void Bots_Move_NORM (edict_t *ent); //normal AI
//spawn //spawn
void SetBotFlag1(edict_t *ent); //チーム1の旗 void SetBotFlag1(edict_t *ent); //チーム1の旗
void SetBotFlag2(edict_t *ent); //チーム2の旗 void SetBotFlag2(edict_t *ent); //チーム2の旗
void CTFSetupNavSpawn(); //ナビの設置 void CTFSetupNavSpawn(); //ナビの設置
//ctf //ctf
void CTFJobAssign (void); //job assign void CTFJobAssign (void); //job assign
@ -208,27 +208,27 @@ void CTFJobAssign (void); //job assign
#define FIRE_CHIKEN 0x00000008 //X chiken fire #define FIRE_CHIKEN 0x00000008 //X chiken fire
#define FIRE_RUSH 0x00000010 //X rush #define FIRE_RUSH 0x00000010 //X rush
#define FIRE_JUMPNRUSH 0x00000020 // #define FIRE_JUMPNRUSH 0x00000020 //
#define FIRE_ESTIMATE 0x00000040 //X estimate 予測 #define FIRE_ESTIMATE 0x00000040 //X estimate 予測
#define FIRE_SCATTER 0x00000080 //scatter バラ撒き #define FIRE_SCATTER 0x00000080 //scatter バラ撒き
#define FIRE_RUNNIN 0x00000100 //run & shot(normal) #define FIRE_RUNNIN 0x00000100 //run & shot(normal)
#define FIRE_JUMPROC 0x00000200 //X ジャンプふぁいあ #define FIRE_JUMPROC 0x00000200 //X ジャンプふぁいあ
#define FIRE_REFUGE 0x00001000 //X 避難 #define FIRE_REFUGE 0x00001000 //X 避難
#define FIRE_EXPAVOID 0x00002000 //X 爆発よけ #define FIRE_EXPAVOID 0x00002000 //X 爆発よけ
#define FIRE_QUADUSE 0x00004000 //X Quad時の連射武器選択 #define FIRE_QUADUSE 0x00004000 //X Quad時の連射武器選択
#define FIRE_AVOIDINV 0x00008000 //X 相手がペンタの時逃げる #define FIRE_AVOIDINV 0x00008000 //X 相手がペンタの時逃げる
#define FIRE_BFG 0x00010000 //X 普通にBFGを撃つ #define FIRE_BFG 0x00010000 //X 普通にBFGを撃つ
#define FIRE_SHIFT_R 0x00020000 //X 右スライド #define FIRE_SHIFT_R 0x00020000 //X 右スライド
#define FIRE_SHIFT_L 0x00040000 //X 左スライド #define FIRE_SHIFT_L 0x00040000 //X 左スライド
#define FIRE_SHIFT (FIRE_SHIFT_R | FIRE_SHIFT_L)//X 右スライド #define FIRE_SHIFT (FIRE_SHIFT_R | FIRE_SHIFT_L)//X 右スライド
#define FIRE_REFLECT 0x00080000 // 壁に反射させる #define FIRE_REFLECT 0x00080000 // 壁に反射させる
#define FIRE_IGNORE 0x10000000 //無視して逃げる #define FIRE_IGNORE 0x10000000 //無視して逃げる
// means of death // means of death
@ -320,8 +320,8 @@ typedef struct
#define BOP_COMBATSKILL 4 //combat skill #define BOP_COMBATSKILL 4 //combat skill
#define BOP_ROCJ 5 //rocket jump #define BOP_ROCJ 5 //rocket jump
#define BOP_REACTION 6 //reaction skill exp. frq SEARCH ENEMY #define BOP_REACTION 6 //reaction skill exp. frq SEARCH ENEMY
#define BOP_VRANGE 7 //V-View of RANGE 縦 #define BOP_VRANGE 7 //V-View of RANGE 縦
#define BOP_HRANGE 8 //H-View of Range 横 #define BOP_HRANGE 8 //H-View of Range 横
#define BOP_PRIWEP 9 //primary weapon #define BOP_PRIWEP 9 //primary weapon
#define BOP_SECWEP 10 //secondary weapon #define BOP_SECWEP 10 //secondary weapon
#define BOP_DODGE 11 //dodge #define BOP_DODGE 11 //dodge

View file

@ -3,9 +3,9 @@
#include "m_player.h" #include "m_player.h"
//====================================================================== //======================================================================
//aim決定 //aim決定
//ent entity //ent entity
//aim aimスキル //aim aimスキル
//yaw dist //yaw dist
//wep weapon //wep weapon
void Get_AimAngle(edict_t *ent,float aim,float dist,int weapon) void Get_AimAngle(edict_t *ent,float aim,float dist,int weapon)
@ -18,7 +18,7 @@ void Get_AimAngle(edict_t *ent,float aim,float dist,int weapon)
switch(weapon) switch(weapon)
{ {
//即判定 //即判定
case WEAP_SHOTGUN: case WEAP_SHOTGUN:
case WEAP_SUPERSHOTGUN: case WEAP_SUPERSHOTGUN:
case WEAP_RAILGUN: case WEAP_RAILGUN:
@ -207,7 +207,7 @@ void Get_AimAngle(edict_t *ent,float aim,float dist,int weapon)
//====================================================================== //======================================================================
//武器使用可能? //武器使用可能?
int CanUsewep(edict_t *ent,int weapon) int CanUsewep(edict_t *ent,int weapon)
{ {
gitem_t *item; gitem_t *item;
@ -483,13 +483,13 @@ qboolean B_UseBfg(edict_t *ent,edict_t *target,int enewep,float aim,float distan
if(k /*&& random() < 0.8*/) if(k /*&& random() < 0.8*/)
{ {
client->buttons |= BUTTON_ATTACK; client->buttons |= BUTTON_ATTACK;
zc->battlemode |= FIRE_STAYFIRE; //モード遷移 zc->battlemode |= FIRE_STAYFIRE; //モード遷移
zc->battlecount = 8 + (int)(10 * random()); zc->battlecount = 8 + (int)(10 * random());
trace_priority = TRP_ALLKEEP; trace_priority = TRP_ALLKEEP;
return true; return true;
} }
} }
//爆発回避 //爆発回避
else if((FFlg[skill] & FIRE_EXPAVOID) else if((FFlg[skill] & FIRE_EXPAVOID)
&& distance < 300 /*&& random() < 0.5 */ && distance < 300 /*&& random() < 0.5 */
&& Bot_traceS(ent,target)) && Bot_traceS(ent,target))
@ -502,7 +502,7 @@ qboolean B_UseBfg(edict_t *ent,edict_t *target,int enewep,float aim,float distan
return true; return true;
} }
} }
//普通 //普通
else if(!(FFlg[skill] &(FIRE_STAYFIRE | FIRE_EXPAVOID))) else if(!(FFlg[skill] &(FIRE_STAYFIRE | FIRE_EXPAVOID)))
{ {
if(k /*&& random() < 0.8*/) if(k /*&& random() < 0.8*/)
@ -1009,10 +1009,10 @@ void Combat_LevelX(edict_t *ent,int foundedenemy,int enewep
target = zc->first_target; target = zc->first_target;
//----------------------------------------------------------------------- //-----------------------------------------------------------------------
//ステータスを反映 //ステータスを反映
//----------------------------------------------------------------------- //-----------------------------------------------------------------------
k = false; k = false;
//予測======================== //予測========================
if(zc->battlemode & FIRE_ESTIMATE) if(zc->battlemode & FIRE_ESTIMATE)
{ {
mywep = Get_KindWeapon(client->pers.weapon); mywep = Get_KindWeapon(client->pers.weapon);
@ -1077,11 +1077,11 @@ void Combat_Level0(edict_t *ent,int foundedenemy,int enewep
//----------------------------------------------------------------------- //-----------------------------------------------------------------------
//ステータスを反映 //ステータスを反映
//----------------------------------------------------------------------- //-----------------------------------------------------------------------
//チキンは狙いがキツイ============== //チキンは狙いがキツイ==============
if(zc->battlemode == FIRE_CHIKEN) aim *= 0.7; if(zc->battlemode == FIRE_CHIKEN) aim *= 0.7;
//左右に回避======================== //左右に回避========================
if(zc->battlemode & FIRE_SHIFT) if(zc->battlemode & FIRE_SHIFT)
{ {
mywep = Get_KindWeapon(client->pers.weapon); mywep = Get_KindWeapon(client->pers.weapon);
@ -1101,7 +1101,7 @@ void Combat_Level0(edict_t *ent,int foundedenemy,int enewep
zc->moveyaw = ent->s.angles[YAW] - 90; zc->moveyaw = ent->s.angles[YAW] - 90;
if(zc->moveyaw < -180) zc->moveyaw += 360; if(zc->moveyaw < -180) zc->moveyaw += 360;
} }
trace_priority = TRP_MOVEKEEP; //後退処理 trace_priority = TRP_MOVEKEEP; //後退処理
} }
} }
else else
@ -1150,7 +1150,7 @@ void Combat_Level0(edict_t *ent,int foundedenemy,int enewep
} }
} }
} }
//無視して走る======================== //無視して走る========================
if(zc->battlemode & FIRE_IGNORE) if(zc->battlemode & FIRE_IGNORE)
{ {
if(--zc->battlecount > 0) if(--zc->battlecount > 0)
@ -1164,7 +1164,7 @@ void Combat_Level0(edict_t *ent,int foundedenemy,int enewep
zc->battlemode = 0; zc->battlemode = 0;
} }
//立ち止まって撃つ準備======================== //立ち止まって撃つ準備========================
if(zc->battlemode & FIRE_PRESTAYFIRE) if(zc->battlemode & FIRE_PRESTAYFIRE)
{ {
if(--zc->battlecount > 0) if(--zc->battlecount > 0)
@ -1172,14 +1172,14 @@ void Combat_Level0(edict_t *ent,int foundedenemy,int enewep
mywep = Get_KindWeapon(client->pers.weapon); mywep = Get_KindWeapon(client->pers.weapon);
Get_AimAngle(ent,aim,distance,mywep); Get_AimAngle(ent,aim,distance,mywep);
if(target->client->weaponstate == WEAPON_FIRING && ent->groundentity) ent->client->ps.pmove.pm_flags |= PMF_DUCKED; if(target->client->weaponstate == WEAPON_FIRING && ent->groundentity) ent->client->ps.pmove.pm_flags |= PMF_DUCKED;
trace_priority = TRP_ALLKEEP; //動かない trace_priority = TRP_ALLKEEP; //動かない
return; return;
} }
if(!(zc->battlemode & FIRE_SHIFT)) zc->battlemode = FIRE_STAYFIRE; //モード遷移 if(!(zc->battlemode & FIRE_SHIFT)) zc->battlemode = FIRE_STAYFIRE; //モード遷移
zc->battlecount = 5 + (int)(20 * random()); zc->battlecount = 5 + (int)(20 * random());
} }
//立ち止まって撃つ======================== //立ち止まって撃つ========================
if(zc->battlemode & FIRE_STAYFIRE) if(zc->battlemode & FIRE_STAYFIRE)
{ {
if(--zc->battlecount > 0) if(--zc->battlecount > 0)
@ -1196,7 +1196,7 @@ void Combat_Level0(edict_t *ent,int foundedenemy,int enewep
} }
else client->ps.pmove.pm_flags |= PMF_DUCKED; else client->ps.pmove.pm_flags |= PMF_DUCKED;
} }
if(!(zc->battlemode & FIRE_SHIFT)) trace_priority = TRP_ALLKEEP; //動かない if(!(zc->battlemode & FIRE_SHIFT)) trace_priority = TRP_ALLKEEP; //動かない
if(Bot_traceS(ent,target) if(Bot_traceS(ent,target)
|| mywep == WEAP_BFG || mywep == WEAP_BFG
|| mywep == WEAP_GRENADELAUNCHER) client->buttons |= BUTTON_ATTACK; || mywep == WEAP_GRENADELAUNCHER) client->buttons |= BUTTON_ATTACK;
@ -1205,7 +1205,7 @@ void Combat_Level0(edict_t *ent,int foundedenemy,int enewep
zc->battlemode = 0; zc->battlemode = 0;
} }
//FIRE_RUSH つっこむ======================== //FIRE_RUSH つっこむ========================
if(zc->battlemode & FIRE_RUSH) if(zc->battlemode & FIRE_RUSH)
{ {
if(--zc->battlecount > 0) if(--zc->battlecount > 0)
@ -1222,7 +1222,7 @@ void Combat_Level0(edict_t *ent,int foundedenemy,int enewep
} }
else client->ps.pmove.pm_flags |= PMF_DUCKED; else client->ps.pmove.pm_flags |= PMF_DUCKED;
} }
trace_priority = TRP_MOVEKEEP; //後退処理 trace_priority = TRP_MOVEKEEP; //後退処理
zc->moveyaw = ent->s.angles[YAW]; zc->moveyaw = ent->s.angles[YAW];
if(Bot_traceS(ent,target)) client->buttons |= BUTTON_ATTACK; if(Bot_traceS(ent,target)) client->buttons |= BUTTON_ATTACK;
@ -1231,7 +1231,7 @@ void Combat_Level0(edict_t *ent,int foundedenemy,int enewep
zc->battlemode = 0; zc->battlemode = 0;
} }
//後退ファイア(爆発回避)======================== //後退ファイア(爆発回避)========================
if(zc->battlemode & FIRE_EXPAVOID) if(zc->battlemode & FIRE_EXPAVOID)
{ {
if(--zc->battlecount > 0) if(--zc->battlecount > 0)
@ -1248,7 +1248,7 @@ void Combat_Level0(edict_t *ent,int foundedenemy,int enewep
} }
else client->ps.pmove.pm_flags |= PMF_DUCKED; else client->ps.pmove.pm_flags |= PMF_DUCKED;
} }
trace_priority = TRP_MOVEKEEP; //後退処理 trace_priority = TRP_MOVEKEEP; //後退処理
zc->moveyaw = ent->s.angles[YAW] + 180; zc->moveyaw = ent->s.angles[YAW] + 180;
if(zc->moveyaw > 180) zc->moveyaw -= 360; if(zc->moveyaw > 180) zc->moveyaw -= 360;
@ -1259,7 +1259,7 @@ void Combat_Level0(edict_t *ent,int foundedenemy,int enewep
} }
zc->battlemode = 0; zc->battlemode = 0;
} }
//BFGファイア(爆発回避)======================== //BFGファイア(爆発回避)========================
if(zc->battlemode & FIRE_BFG) if(zc->battlemode & FIRE_BFG)
{ {
if(--zc->battlecount > 0) if(--zc->battlecount > 0)
@ -1276,7 +1276,7 @@ void Combat_Level0(edict_t *ent,int foundedenemy,int enewep
} }
else client->ps.pmove.pm_flags |= PMF_DUCKED; else client->ps.pmove.pm_flags |= PMF_DUCKED;
} }
trace_priority = TRP_ANGLEKEEP; //後退処理 trace_priority = TRP_ANGLEKEEP; //後退処理
if(Bot_traceS(ent,target) if(Bot_traceS(ent,target)
|| mywep == WEAP_BFG || mywep == WEAP_BFG
@ -1286,7 +1286,7 @@ void Combat_Level0(edict_t *ent,int foundedenemy,int enewep
zc->battlemode = 0; zc->battlemode = 0;
} }
//撃って避難======================== //撃って避難========================
if(zc->battlemode & FIRE_REFUGE) if(zc->battlemode & FIRE_REFUGE)
{ {
if(--zc->battlecount > 0) if(--zc->battlecount > 0)
@ -1303,8 +1303,8 @@ void Combat_Level0(edict_t *ent,int foundedenemy,int enewep
} }
else client->ps.pmove.pm_flags |= PMF_DUCKED; else client->ps.pmove.pm_flags |= PMF_DUCKED;
} }
trace_priority = TRP_ANGLEKEEP; //動かない trace_priority = TRP_ANGLEKEEP; //動かない
// trace_priority = TRP_ALLKEEP; //動かない // trace_priority = TRP_ALLKEEP; //動かない
if(Bot_traceS(ent,target) if(Bot_traceS(ent,target)
|| mywep == WEAP_BFG || mywep == WEAP_BFG
|| mywep == WEAP_GRENADELAUNCHER) client->buttons |= BUTTON_ATTACK; || mywep == WEAP_GRENADELAUNCHER) client->buttons |= BUTTON_ATTACK;
@ -1339,11 +1339,11 @@ void Combat_Level0(edict_t *ent,int foundedenemy,int enewep
} }
//----------------------------------------------------------------------- //-----------------------------------------------------------------------
//特殊ファイアリング //特殊ファイアリング
//----------------------------------------------------------------------- //-----------------------------------------------------------------------
mywep = Get_KindWeapon(client->pers.weapon); mywep = Get_KindWeapon(client->pers.weapon);
//左右回避セット======================== //左右回避セット========================
if(!(zc->battlemode & FIRE_SHIFT) && skill > (random() * skill) /*&& distance < 250*/ if(!(zc->battlemode & FIRE_SHIFT) && skill > (random() * skill) /*&& distance < 250*/
&& (30 * random()) < Bot[zc->botindex].param[BOP_OFFENCE]) && (30 * random()) < Bot[zc->botindex].param[BOP_OFFENCE])
{ {
@ -1377,7 +1377,7 @@ void Combat_Level0(edict_t *ent,int foundedenemy,int enewep
f = -(f + 360); f = -(f + 360);
} }
//俺をみている!! //俺をみている!!
if(f <= -160) if(f <= -160)
{ {
@ -1392,18 +1392,18 @@ void Combat_Level0(edict_t *ent,int foundedenemy,int enewep
} }
} }
//敵がペンタをとっている======================== //敵がペンタをとっている========================
if((FFlg[skill] & FIRE_AVOIDINV) if((FFlg[skill] & FIRE_AVOIDINV)
&& target->client->invincible_framenum > level.framenum) && target->client->invincible_framenum > level.framenum)
{ {
// mywep = Get_KindWeapon(client->pers.weapon); // mywep = Get_KindWeapon(client->pers.weapon);
Get_AimAngle(ent,aim,distance,mywep); Get_AimAngle(ent,aim,distance,mywep);
trace_priority = TRP_MOVEKEEP; //後退処理 trace_priority = TRP_MOVEKEEP; //後退処理
zc->moveyaw = ent->s.angles[YAW] + 180; zc->moveyaw = ent->s.angles[YAW] + 180;
if(zc->moveyaw > 180) zc->moveyaw -= 360; if(zc->moveyaw > 180) zc->moveyaw -= 360;
return; return;
} }
//Quad時の処理================================= //Quad時の処理=================================
if((FFlg[skill] & FIRE_QUADUSE) if((FFlg[skill] & FIRE_QUADUSE)
&& (ent->client->quad_framenum > level.framenum) && (ent->client->quad_framenum > level.framenum)
&& distance < 300) && distance < 300)
@ -1468,7 +1468,7 @@ void Combat_Level0(edict_t *ent,int foundedenemy,int enewep
return; return;
} }
} }
//撃って逃げる処理================================= //撃って逃げる処理=================================
if((FFlg[skill] & FIRE_REFUGE) if((FFlg[skill] & FIRE_REFUGE)
&& zc->battlemode == 0 && zc->route_trace && zc->routeindex > 1 ) && zc->battlemode == 0 && zc->route_trace && zc->routeindex > 1 )
{ {
@ -1485,17 +1485,17 @@ void Combat_Level0(edict_t *ent,int foundedenemy,int enewep
|| mywep == WEAP_ROCKETLAUNCHER || mywep == WEAP_ROCKETLAUNCHER
|| mywep == WEAP_PHALANX) || mywep == WEAP_PHALANX)
{ {
zc->battlemode |= FIRE_REFUGE; //モード遷移 zc->battlemode |= FIRE_REFUGE; //モード遷移
zc->battlecount = 8 + (int)(10 * random()); zc->battlecount = 8 + (int)(10 * random());
trace_priority = TRP_ALLKEEP; trace_priority = TRP_ALLKEEP;
return; return;
} }
} }
} }
//トレース中以外のときにグルグルを防ぐ================================= //トレース中以外のときにグルグルを防ぐ=================================
if(!zc->route_trace && distance < 100) if(!zc->route_trace && distance < 100)
{ {
zc->battlemode |= FIRE_EXPAVOID; //モード遷移 zc->battlemode |= FIRE_EXPAVOID; //モード遷移
zc->battlecount = 4 + (int)(8 * random()); zc->battlecount = 4 + (int)(8 * random());
trace_priority = TRP_ALLKEEP; trace_priority = TRP_ALLKEEP;
} }
@ -1503,7 +1503,7 @@ void Combat_Level0(edict_t *ent,int foundedenemy,int enewep
//----------------------------------------------------------------------- //-----------------------------------------------------------------------
//プライオリティ //プライオリティ
//----------------------------------------------------------------------- //-----------------------------------------------------------------------
//BFG //BFG
if(distance > 200) if(distance > 200)
@ -1624,7 +1624,7 @@ void Combat_Level0(edict_t *ent,int foundedenemy,int enewep
//----------------------------------------------------------------------- //-----------------------------------------------------------------------
//通常ファイアリング //通常ファイアリング
//----------------------------------------------------------------------- //-----------------------------------------------------------------------
zc->secwep_selected = 0; zc->secwep_selected = 0;
//BFG //BFG
@ -1723,7 +1723,7 @@ void Combat_Level0(edict_t *ent,int foundedenemy,int enewep
FIRED: FIRED:
if(zc->secwep_selected == 2) zc->secwep_selected = 1; if(zc->secwep_selected == 2) zc->secwep_selected = 1;
//チキンやろう======================== //チキンやろう========================
if(zc->battlemode == FIRE_CHIKEN) if(zc->battlemode == FIRE_CHIKEN)
{ {
if(--zc->battlesubcnt > 0 && ent->groundentity && ent->waterlevel < 2) if(--zc->battlesubcnt > 0 && ent->groundentity && ent->waterlevel < 2)

View file

@ -94,7 +94,7 @@ void Load_BotInfo()
} }
else else
{ {
fseek( fp, 0, SEEK_SET); //先頭へ移動 fseek( fp, 0, SEEK_SET); //先頭へ移動
while(1) while(1)
{ {
if(fgets( Buff, sizeof(Buff), fp ) == NULL) goto MESS_NOTFOUND; if(fgets( Buff, sizeof(Buff), fp ) == NULL) goto MESS_NOTFOUND;
@ -113,7 +113,7 @@ MESS_NOTFOUND:
//if(botlist->string == NULL) strcpy(MessageSection,BOTLIST_SECTION_DM); //if(botlist->string == NULL) strcpy(MessageSection,BOTLIST_SECTION_DM);
//else //else
sprintf(MessageSection,"[%s]",botlist->string); sprintf(MessageSection,"[%s]",botlist->string);
fseek( fp, 0, SEEK_SET); //先頭へ移動 fseek( fp, 0, SEEK_SET); //先頭へ移動
while(1) while(1)
{ {
if(fgets( Buff, sizeof(Buff), fp ) == NULL) if(fgets( Buff, sizeof(Buff), fp ) == NULL)
@ -127,7 +127,7 @@ MESS_NOTFOUND:
if(MessageSection[0] == 0) if(MessageSection[0] == 0)
{ {
strcpy(MessageSection,BOTLIST_SECTION_DM); strcpy(MessageSection,BOTLIST_SECTION_DM);
fseek( fp, 0, SEEK_SET); //先頭へ移動 fseek( fp, 0, SEEK_SET); //先頭へ移動
while(1) while(1)
{ {
if(fgets( Buff, sizeof(Buff), fp ) == NULL) goto BOTLIST_NOTFOUND; if(fgets( Buff, sizeof(Buff), fp ) == NULL) goto BOTLIST_NOTFOUND;
@ -222,7 +222,7 @@ BOTLIST_NOTFOUND:
// //
//---------------------------------------------------------------- //----------------------------------------------------------------
int Get_NumOfPlayer (void) //Botも含めたplayerの数 int Get_NumOfPlayer (void) //Botも含めたplayerの数
{ {
int i,j; int i,j;
edict_t *ent; edict_t *ent;
@ -465,8 +465,8 @@ void PutBotInServer (edict_t *ent)
ent->pain_debounce_time = level.time; ent->pain_debounce_time = level.time;
ent->targetname = NULL; ent->targetname = NULL;
ent->moveinfo.speed = 1.0; //ジャンプ中の移動率について追加 ent->moveinfo.speed = 1.0; //ジャンプ中の移動率について追加
ent->moveinfo.state = GETTER; //CTFステータス初期化 ent->moveinfo.state = GETTER; //CTFステータス初期化
ent->prethink = NULL; ent->prethink = NULL;
ent->think = Bot_Think; ent->think = Bot_Think;
@ -829,7 +829,7 @@ void ZigockClientJoin(edict_t *ent,int zclass)
{ {
PMenu_Close(ent); PMenu_Close(ent);
ent->moveinfo.sound_end = CLS_ALPHA; //PutClientの前にクラス決定 ent->moveinfo.sound_end = CLS_ALPHA; //PutClientの前にクラス決定
ent->svflags &= ~SVF_NOCLIENT; ent->svflags &= ~SVF_NOCLIENT;
PutClientInServer (ent); PutClientInServer (ent);
@ -971,7 +971,7 @@ void AirStrike_Think(edict_t *ent)
if( target->classname[0] == 'p') if( target->classname[0] == 'p')
{ {
//ctf ならチームメイト無視 //ctf ならチームメイト無視
if(!ctf->value || (ctf->value && ent->owner->client->resp.ctf_team != target->client->resp.ctf_team)) if(!ctf->value || (ctf->value && ent->owner->client->resp.ctf_team != target->client->resp.ctf_team))
{ {
rs_trace = gi.trace (point,NULL,NULL,target->s.origin,ent, CONTENTS_SOLID | CONTENTS_WINDOW | CONTENTS_LAVA | CONTENTS_SLIME); rs_trace = gi.trace (point,NULL,NULL,target->s.origin,ent, CONTENTS_SOLID | CONTENTS_WINDOW | CONTENTS_LAVA | CONTENTS_SLIME);
@ -1020,7 +1020,7 @@ void Cmd_AirStrike(edict_t *ent)
}*/ }*/
VectorCopy(rs_trace.endpos,strpoint); VectorCopy(rs_trace.endpos,strpoint);
strpoint[2] -= 16; //ちょっとだけ下へずらす strpoint[2] -= 16; //ちょっとだけ下へずらす
f = ent->s.angles[YAW]*M_PI*2 / 360; f = ent->s.angles[YAW]*M_PI*2 / 360;
tts[0] = cos(f) * (-8190) ; tts[0] = cos(f) * (-8190) ;

View file

@ -214,7 +214,7 @@ int Bot_SearchEnemy (edict_t *ent)
if((9 * random()) < yaw) if((9 * random()) < yaw)
{ {
//gi.bprintf(PRINT_HIGH,"Team stateON\n"); //gi.bprintf(PRINT_HIGH,"Team stateON\n");
//相手がリーダー //相手がリーダー
if(trent->client->zc.tmplstate == TMS_LEADER) if(trent->client->zc.tmplstate == TMS_LEADER)
{ {
trent->client->zc.followmate = NULL; trent->client->zc.followmate = NULL;
@ -335,7 +335,7 @@ int Bot_SearchEnemy (edict_t *ent)
} }
} }
} }
//音のみで場所を判断 //音のみで場所を判断
else else
{ {
if(Bot[ent->client->zc.botindex].param[BOP_NOISECHK] if(Bot[ent->client->zc.botindex].param[BOP_NOISECHK]
@ -890,7 +890,7 @@ void Bot_SearchItems (edict_t *ent)
} }
//----------------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------------
//バクハツ物回避 //バクハツ物回避
//Avoid explotion //Avoid explotion
// //
#define EXPLO_BOXSIZE 64 #define EXPLO_BOXSIZE 64
@ -932,7 +932,7 @@ qboolean Bot_ExploAvoid(edict_t *ent,vec3_t v)
return true; return true;
} }
//レーザーのチェック //レーザーのチェック
qboolean CheckLaser(vec3_t pos,vec3_t maxs,vec3_t mins) qboolean CheckLaser(vec3_t pos,vec3_t maxs,vec3_t mins)
{ {
int i; int i;
@ -978,7 +978,7 @@ qboolean CheckLaser(vec3_t pos,vec3_t maxs,vec3_t mins)
} }
//----------------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------------
// BOT移動可能判定new // BOT移動可能判定new
// bot move test // bot move test
// return false can't // return false can't
// true stand // true stand
@ -997,7 +997,7 @@ int Bot_moveT ( edict_t *ent,float ryaw,vec3_t pos,float dist,float *bottom)
tcontents =/* MASK_BOTSOLID*/MASK_BOTSOLIDX;//MASK_PLAYERSOLID /*| CONTENTS_TRANSLUCENT*/; //レーザーには触らない tcontents =/* MASK_BOTSOLID*/MASK_BOTSOLIDX;//MASK_PLAYERSOLID /*| CONTENTS_TRANSLUCENT*/; //レーザーには触らない
// if(!ent->waterlevel) tcontents |= CONTENTS_WATER; // if(!ent->waterlevel) tcontents |= CONTENTS_WATER;
if(/*ent->client->zc.waterstate == WAS_FLOAT*/ent->waterlevel >= 1/*2*/) tracelimit = 75;//75;//61; if(/*ent->client->zc.waterstate == WAS_FLOAT*/ent->waterlevel >= 1/*2*/) tracelimit = 75;//75;//61;
@ -1021,7 +1021,7 @@ int Bot_moveT ( edict_t *ent,float ryaw,vec3_t pos,float dist,float *bottom)
if((v[2] - ent->s.origin[2]) > 20) trmax[2] = 31; if((v[2] - ent->s.origin[2]) > 20) trmax[2] = 31;
} }
//移動先がどうなっているのか調べる //移動先がどうなっているのか調べる
yaw = ryaw*M_PI*2 / 360; yaw = ryaw*M_PI*2 / 360;
trend[0] = cos(yaw) * dist ; //start trend[0] = cos(yaw) * dist ; //start
trend[1] = sin(yaw) * dist ; trend[1] = sin(yaw) * dist ;
@ -1033,7 +1033,7 @@ int Bot_moveT ( edict_t *ent,float ryaw,vec3_t pos,float dist,float *bottom)
rs_trace = gi.trace (trstart, trmin, trmax, trend,ent, tcontents); rs_trace = gi.trace (trstart, trmin, trmax, trend,ent, tcontents);
trmax[2] += 1; trmax[2] += 1;
if(rs_trace.allsolid || rs_trace.startsolid || rs_trace.fraction != 1.0) //前には進めない場合 if(rs_trace.allsolid || rs_trace.startsolid || rs_trace.fraction != 1.0) //前には進めない場合
{ {
moveok = false; moveok = false;
VectorCopy (trstart, trend); VectorCopy (trstart, trend);
@ -1119,7 +1119,7 @@ int Bot_moveT ( edict_t *ent,float ryaw,vec3_t pos,float dist,float *bottom)
if(!rs_trace.allsolid && !rs_trace.startsolid) return true; if(!rs_trace.allsolid && !rs_trace.startsolid) return true;
return 2;*/ return 2;*/
} }
else //進めたとしても落ちたくない時のためのチェック else //進めたとしても落ちたくない時のためのチェック
{ {
pos[0] = trstart[0]; pos[0] = trstart[0];
pos[1] = trstart[1]; pos[1] = trstart[1];
@ -1328,7 +1328,7 @@ int Bot_moveW ( edict_t *ent,float ryaw,vec3_t pos,float dist,float *bottom)
tcontents = MASK_BOTSOLIDX/*MASK_PLAYERSOLID*/; tcontents = MASK_BOTSOLIDX/*MASK_PLAYERSOLID*/;
tcontents |= CONTENTS_WATER; tcontents |= CONTENTS_WATER;
//移動先がどうなっているのか調べる //移動先がどうなっているのか調べる
yaw = ryaw*M_PI*2 / 360; yaw = ryaw*M_PI*2 / 360;
trend[0] = cos(yaw) * dist ; //start trend[0] = cos(yaw) * dist ; //start
trend[1] = sin(yaw) * dist ; trend[1] = sin(yaw) * dist ;
@ -1735,7 +1735,7 @@ qboolean Bot_Fall(edict_t *ent,vec3_t pos,float dist)
VectorCopy(v,vv); VectorCopy(v,vv);
vv[2] = 0; vv[2] = 0;
//vel考慮の落下 //vel考慮の落下
if(Route[zc->routeindex].state == GRS_ONTRAIN) if(Route[zc->routeindex].state == GRS_ONTRAIN)
{ {
if(1/*Route[zc->routeindex].ent->trainteam == NULL*/) if(1/*Route[zc->routeindex].ent->trainteam == NULL*/)
@ -1815,7 +1815,7 @@ JUMPCATCH:
vv[2] = 0; vv[2] = 0;
if(mode == 2) if(mode == 2)
{ {
//vel考慮の落下 //vel考慮の落下
if(Route[zc->routeindex].state == GRS_ONTRAIN) if(Route[zc->routeindex].state == GRS_ONTRAIN)
{ {
if(1/*Route[zc->routeindex].ent->trainteam == NULL*/) if(1/*Route[zc->routeindex].ent->trainteam == NULL*/)
@ -2551,7 +2551,7 @@ if(ctf->value) j = 0;
ent->maxs[2] = 4; ent->maxs[2] = 4;
} }
} }
DCHCANC://しゃがみっぱなし DCHCANC://しゃがみっぱなし
//-------------------------------------------------------------------------------------- //--------------------------------------------------------------------------------------
//movingspeed set //movingspeed set
if(ent->groundentity || ent->waterlevel) if(ent->groundentity || ent->waterlevel)
@ -2682,7 +2682,7 @@ DCHCANC://
} }
} }
} }
//撃てGrapple //撃てGrapple
else if(Route[zc->routeindex - 1].state == GRS_GRAPSHOT else if(Route[zc->routeindex - 1].state == GRS_GRAPSHOT
&& ent->client->ctf_grapple == NULL && ent->client->ctf_grapple == NULL
&& zc->first_target == NULL) && zc->first_target == NULL)
@ -3034,7 +3034,7 @@ gi.bprintf(PRINT_HIGH,"OFF 5\n"); //ppx
// //
// //
// //
// 梯子を登る // 梯子を登る
// //
// //
//-------------------------------------------------------------------------------------- //--------------------------------------------------------------------------------------
@ -3222,7 +3222,7 @@ gi.bprintf(PRINT_HIGH,"ladder OFF2!!\n");
// //
// //
// //
// 移動方向決定 // 移動方向決定
// //
// //
//-------------------------------------------------------------------------------------- //--------------------------------------------------------------------------------------
@ -3309,7 +3309,7 @@ gi.bprintf(PRINT_HIGH,"ladder OFF2!!\n");
ent->s.angles[PITCH] = Get_pitch(temppos); ent->s.angles[PITCH] = Get_pitch(temppos);
} }
*/ */
//チームプレイ時のルーチン //チームプレイ時のルーチン
if(ctf->value ||((int)(dmflags->value) & (DF_MODELTEAMS | DF_SKINTEAMS))) if(ctf->value ||((int)(dmflags->value) & (DF_MODELTEAMS | DF_SKINTEAMS)))
{ {
if(ctf->value) if(ctf->value)
@ -3490,7 +3490,7 @@ gi.bprintf(PRINT_HIGH,"ladder OFF2!!\n");
if(1/*!(zc->zcstate & STS_WAITSMASK)*/) if(1/*!(zc->zcstate & STS_WAITSMASK)*/)
{ {
//ルートトレース用index検索 //ルートトレース用index検索
if(!zc->route_trace && zc->rt_releasetime <= level.time) if(!zc->route_trace && zc->rt_releasetime <= level.time)
{ {
//zc->routeindex; //zc->routeindex;
@ -3636,7 +3636,7 @@ gi.bprintf(PRINT_HIGH,"ladder OFF2!!\n");
} }
} }
//トリガを撃つ //トリガを撃つ
if(k && !(ent->client->buttons & BUTTON_ATTACK)) if(k && !(ent->client->buttons & BUTTON_ATTACK))
{ {
//gi.bprintf(PRINT_HIGH,"ooooooo!\n"); //gi.bprintf(PRINT_HIGH,"ooooooo!\n");
@ -3656,7 +3656,7 @@ gi.bprintf(PRINT_HIGH,"ladder OFF2!!\n");
else VectorSubtract(v,ent->s.origin,trmax); else VectorSubtract(v,ent->s.origin,trmax);
//gi.bprintf(PRINT_HIGH,"shoot!\n"); //gi.bprintf(PRINT_HIGH,"shoot!\n");
//爆発モノの時は持ち替え //爆発モノの時は持ち替え
i = Get_KindWeapon(ent->client->pers.weapon); i = Get_KindWeapon(ent->client->pers.weapon);
if(!zc->first_target && it_ent->takedamage) if(!zc->first_target && it_ent->takedamage)
{ {
@ -3727,7 +3727,7 @@ gi.bprintf(PRINT_HIGH,"OFF 10\n");
} }
else f1 = -(JumpMax + 64); else f1 = -(JumpMax + 64);
} }
//到達チェック //到達チェック
if( Route[zc->routeindex].state == GRS_ONROTATE) yaw = -48; if( Route[zc->routeindex].state == GRS_ONROTATE) yaw = -48;
else yaw = 12; else yaw = 12;
if(v[0] <= (ent->absmax[0] - yaw) && v[0] >= (ent->absmin[0] + yaw)) if(v[0] <= (ent->absmax[0] - yaw) && v[0] >= (ent->absmin[0] + yaw))
@ -3740,7 +3740,7 @@ gi.bprintf(PRINT_HIGH,"OFF 10\n");
{ {
if(zc->routeindex < CurrentIndex /*&& TraceX(ent,Route[zc->routeindex + 1].Pt)*/) if(zc->routeindex < CurrentIndex /*&& TraceX(ent,Route[zc->routeindex + 1].Pt)*/)
{ {
//アイテムリンクチェック1>> //アイテムリンクチェック1>>
if(Route[zc->routeindex].state <= GRS_ITEMS) if(Route[zc->routeindex].state <= GRS_ITEMS)
{ {
if(zc->havetarget) if(zc->havetarget)
@ -3778,7 +3778,7 @@ gi.bprintf(PRINT_HIGH,"OFF 10\n");
} }
} }
} }
//アイテムリンクチェック<< //アイテムリンクチェック<<
zc->routeindex++; zc->routeindex++;
//not a normal pod //not a normal pod
if(zc->routeindex < CurrentIndex) if(zc->routeindex < CurrentIndex)
@ -3853,7 +3853,7 @@ gi.bprintf(PRINT_HIGH,"OFF 10\n");
VectorCopy(temppos,ent->s.origin); VectorCopy(temppos,ent->s.origin);
VectorCopy(v,trmin); VectorCopy(v,trmin);
dist -= x; dist -= x;
//アイテムリンクチェック2>> //アイテムリンクチェック2>>
if(Route[zc->routeindex].state <= GRS_ITEMS) if(Route[zc->routeindex].state <= GRS_ITEMS)
{ {
if(zc->havetarget) if(zc->havetarget)
@ -3872,7 +3872,7 @@ gi.bprintf(PRINT_HIGH,"OFF 10\n");
} }
} }
} }
//アイテムリンクチェック<< //アイテムリンクチェック<<
zc->routeindex++; zc->routeindex++;
if(i == 2) ent->client->ps.pmove.pm_flags |= PMF_DUCKED; if(i == 2) ent->client->ps.pmove.pm_flags |= PMF_DUCKED;
@ -3996,7 +3996,7 @@ gi.bprintf(PRINT_HIGH,"OFF 8\n"); //ppx
// //
// //
// //
// あしもと確認 // あしもと確認
// //
// //
//-------------------------------------------------------------------------------------- //--------------------------------------------------------------------------------------
@ -4633,7 +4633,7 @@ gi.bprintf(PRINT_HIGH,"ladder On!\n");
PlayerNoise(ent, ent->s.origin, PNOISE_SELF); //pon PlayerNoise(ent, ent->s.origin, PNOISE_SELF); //pon
Set_BotAnim(ent,ANIM_JUMP,FRAME_jump1-1,FRAME_jump6); Set_BotAnim(ent,ANIM_JUMP,FRAME_jump1-1,FRAME_jump6);
ent->client->buttons |= BUTTON_ATTACK; ent->client->buttons |= BUTTON_ATTACK;
goto VCHCANSEL; //移動処理キャンセル goto VCHCANSEL; //移動処理キャンセル
} }
else zc->second_target = NULL; else zc->second_target = NULL;
} }
@ -5200,7 +5200,7 @@ GOMOVE:
x = zc->second_target->s.origin[2] - ent->s.origin[2]; x = zc->second_target->s.origin[2] - ent->s.origin[2];
if(x > 13/*8*/) x = 13;//8; if(x > 13/*8*/) x = 13;//8;
else if(x < -13/*8*/) x = -13;//8; else if(x < -13/*8*/) x = -13;//8;
if(x < 0)//アイテム下方 if(x < 0)//アイテム下方
{ {
if( Bot_Watermove (ent,temppos,dist,x)) if( Bot_Watermove (ent,temppos,dist,x))
{ {
@ -5209,7 +5209,7 @@ GOMOVE:
} }
} }
else if(x >0 && zc->waterstate == WAS_IN else if(x >0 && zc->waterstate == WAS_IN
&& !(ent->client->ps.pmove.pm_flags & PMF_DUCKED)) //アイテム上方 && !(ent->client->ps.pmove.pm_flags & PMF_DUCKED)) //アイテム上方
{ {
if(ent->velocity[2] < 0) ent->velocity[2] = 0; if(ent->velocity[2] < 0) ent->velocity[2] = 0;
if( Bot_Watermove (ent,temppos,dist,x)) if( Bot_Watermove (ent,temppos,dist,x))
@ -5227,7 +5227,7 @@ GOMOVE:
x = v[2] - ent->s.origin[2]; x = v[2] - ent->s.origin[2];
if(x > 13/*8*/) x = 13;//8; if(x > 13/*8*/) x = 13;//8;
else if(x < -13/*8*/) x = -13;//8; else if(x < -13/*8*/) x = -13;//8;
if(x < 0)//アイテム下方 if(x < 0)//アイテム下方
{ {
if( Bot_Watermove (ent,temppos,dist,x)) if( Bot_Watermove (ent,temppos,dist,x))
{ {
@ -5237,7 +5237,7 @@ GOMOVE:
} }
} }
else if(x > 0 && zc->waterstate == WAS_IN else if(x > 0 && zc->waterstate == WAS_IN
&& !(ent->client->ps.pmove.pm_flags & PMF_DUCKED)) //アイテム上方 && !(ent->client->ps.pmove.pm_flags & PMF_DUCKED)) //アイテム上方
{ {
//gi.bprintf(PRINT_HIGH,"UP! %f\n",x); //gi.bprintf(PRINT_HIGH,"UP! %f\n",x);
if(ent->velocity[2] < -10) ent->velocity[2] = 0; if(ent->velocity[2] < -10) ent->velocity[2] = 0;
@ -5277,7 +5277,7 @@ GOMOVE:
} }
} }
if(zc->waterstate == WAS_IN) ent->moveinfo.decel = level.time; if(zc->waterstate == WAS_IN) ent->moveinfo.decel = level.time;
else if(!k) //水面にずっといたとき else if(!k) //水面にずっといたとき
{ {
if( ( level.time - ent->moveinfo.decel) > 4.0 && !zc->route_trace) if( ( level.time - ent->moveinfo.decel) > 4.0 && !zc->route_trace)
{ {
@ -5513,11 +5513,11 @@ GOMOVE:
zc->second_target = trent; zc->second_target = trent;
trent->target_ent = ent; trent->target_ent = ent;
//トグル式はすぐ走る //トグル式はすぐ走る
if(e->spawnflags & PDOOR_TOGGLE) if(e->spawnflags & PDOOR_TOGGLE)
{ {
f1 = e->moveinfo.start_origin[2] - e->moveinfo.end_origin[2]; f1 = e->moveinfo.start_origin[2] - e->moveinfo.end_origin[2];
//スタート地点が上 //スタート地点が上
if(f1 > 0 ) if(f1 > 0 )
{ {
k = true; k = true;
@ -5543,11 +5543,11 @@ GOMOVE:
} }
} }
} }
//ノーマル //ノーマル
else else
{ {
f1 = e->moveinfo.start_origin[2] - e->moveinfo.end_origin[2]; f1 = e->moveinfo.start_origin[2] - e->moveinfo.end_origin[2];
//スタート地点が上 //スタート地点が上
if(f1 > 0 ) if(f1 > 0 )
{ {
if(e->moveinfo.state == PSTATE_BOTTOM || e->moveinfo.state == PSTATE_UP) if(e->moveinfo.state == PSTATE_BOTTOM || e->moveinfo.state == PSTATE_UP)

View file

@ -10,14 +10,14 @@ typedef struct zgcl_s
int botindex; //botlist's index NO. int botindex; //botlist's index NO.
// true client用 zoom フラグ // true client用 zoom フラグ
int aiming; //0-not 1-aiming 2-firing zoomingflag int aiming; //0-not 1-aiming 2-firing zoomingflag
float distance; //zoom中のFOV値 float distance; //zoom中のFOV値
float olddistance; //旧zooming FOV値 float olddistance; //旧zooming FOV値
qboolean autozoom; //autozoom qboolean autozoom; //autozoom
qboolean lockon; //lockon flag false-not true-locking qboolean lockon; //lockon flag false-not true-locking
// bot用 // bot用
int zcstate; //status int zcstate; //status
int zccmbstt; //combat status int zccmbstt; //combat status

View file

@ -956,7 +956,7 @@ void Cmd_Say_f (edict_t *ent, qboolean team, qboolean arg0)
gi.cprintf(other, PRINT_CHAT, "%s", text); gi.cprintf(other, PRINT_CHAT, "%s", text);
} }
} }
//スナイパー用ZoomIn Out //スナイパー用ZoomIn Out
void Cmd_ZoomIn(edict_t *ent) void Cmd_ZoomIn(edict_t *ent)
{ {
if( ent->client->zc.autozoom ) if( ent->client->zc.autozoom )
@ -1026,7 +1026,7 @@ void Cmd_AutoZoom(edict_t *ent)
} }
} }
//chain の undo //chain の undo
void UndoChain(edict_t *ent ,int step) void UndoChain(edict_t *ent ,int step)
{ {
int count,i; int count,i;

View file

@ -831,12 +831,12 @@ static void CTFFlagThink(edict_t *ent)
void droptofloor (edict_t *ent); void droptofloor (edict_t *ent);
void SpawnItem3 (edict_t *ent, gitem_t *item); void SpawnItem3 (edict_t *ent, gitem_t *item);
//edict_t *GetBotFlag1(); //チーム1の旗 //edict_t *GetBotFlag1(); //チーム1の旗
//edict_t *GetBotFlag2(); //チーム2の旗 //edict_t *GetBotFlag2(); //チーム2の旗
void ChainPodThink (edict_t *ent); void ChainPodThink (edict_t *ent);
qboolean ChkTFlg( void );//旗セットアップ済み? qboolean ChkTFlg( void );//旗セットアップ済み?
void SetBotFlag1(edict_t *ent); //チーム1の旗 void SetBotFlag1(edict_t *ent); //チーム1の旗
void SetBotFlag2(edict_t *ent); //チーム2の旗 void SetBotFlag2(edict_t *ent); //チーム2の旗
void CTFFlagSetup (edict_t *ent) void CTFFlagSetup (edict_t *ent)
{ {
@ -3000,7 +3000,7 @@ void CTFSetupNavSpawn()
//PONKO //PONKO
spawncycle = level.time + FRAMETIME * 100; spawncycle = level.time + FRAMETIME * 100;
//PONKO //PONKO
//ルート初期化 //ルート初期化
CurrentIndex = 0; CurrentIndex = 0;
memset(Route,0,sizeof(Route)); memset(Route,0,sizeof(Route));
memset(code,0,8); memset(code,0,8);
@ -3142,12 +3142,12 @@ void SpawnExtra(vec3_t position,char *classname)
void CTFJobAssign (void) void CTFJobAssign (void)
{ {
int i; int i;
int defend1,defend2; //ディフェンダー総数 int defend1,defend2; //ディフェンダー総数
int mate1,mate2; //チームメイト総数 int mate1,mate2; //チームメイト総数
gclient_t *client; gclient_t *client;
edict_t *e; edict_t *e;
edict_t *defei1,*defei2; //候補 edict_t *defei1,*defei2; //候補
edict_t *geti1,*geti2; //候補 edict_t *geti1,*geti2; //候補
defend1 = 0; defend1 = 0;
defend2 = 0; defend2 = 0;

View file

@ -206,8 +206,8 @@ void Drop_General (edict_t *ent, gitem_t *item)
} }
float Get_yaw (vec3_t vec); float Get_yaw (vec3_t vec);
//edict_t *GetBotFlag1(); //チーム1の旗 //edict_t *GetBotFlag1(); //チーム1の旗
//edict_t *GetBotFlag2(); //チーム2の旗 //edict_t *GetBotFlag2(); //チーム2の旗
//====================================================================== //======================================================================
qboolean Pickup_Navi (edict_t *ent, edict_t *other) qboolean Pickup_Navi (edict_t *ent, edict_t *other)
{ {
@ -241,7 +241,7 @@ qboolean Pickup_Navi (edict_t *ent, edict_t *other)
|| ent->union_ent->moveinfo.state == PSTATE_BOTTOM) other->client->zc.zcstate |= STS_W_ONDOORUP; || ent->union_ent->moveinfo.state == PSTATE_BOTTOM) other->client->zc.zcstate |= STS_W_ONDOORUP;
} }
//j = other->client->zc.routeindex - 10; //j = other->client->zc.routeindex - 10;
//ルートのアップデート //ルートのアップデート
for(i = - MAX_DOORSEARCH; i < MAX_DOORSEARCH ;i++) for(i = - MAX_DOORSEARCH; i < MAX_DOORSEARCH ;i++)
{ {
if(i <= 0) j = other->client->zc.routeindex - (MAX_DOORSEARCH - i) ; if(i <= 0) j = other->client->zc.routeindex - (MAX_DOORSEARCH - i) ;
@ -297,10 +297,10 @@ qboolean Pickup_Navi (edict_t *ent, edict_t *other)
SetRespawn (ent, 1000000); SetRespawn (ent, 1000000);
ent->solid = SOLID_NOT; ent->solid = SOLID_NOT;
} }
//roamnavi やめた //roamnavi やめた
else if( ent->classname[6] == '2') else if( ent->classname[6] == '2')
{ {
//ルートのアップデート //ルートのアップデート
for(i = 0;i < 10;i++) for(i = 0;i < 10;i++)
{ {
if((other->client->zc.routeindex + i) >= CurrentIndex) break; if((other->client->zc.routeindex + i) >= CurrentIndex) break;
@ -1056,7 +1056,7 @@ void Touch_Item (edict_t *ent, edict_t *other, cplane_t *plane, csurface_t *surf
// else gi.bprintf(PRINT_HIGH,"get %s %x inv %i!\n",ent->classname,ent->spawnflags,other->client->pers.inventory[ITEM_INDEX(ent->item)]); // else gi.bprintf(PRINT_HIGH,"get %s %x inv %i!\n",ent->classname,ent->spawnflags,other->client->pers.inventory[ITEM_INDEX(ent->item)]);
k = false; k = false;
//flag set ファンクションの上にある場合は無視 //flag set ファンクションの上にある場合は無視
if(ent->groundentity) if(ent->groundentity->union_ent) k = true; if(ent->groundentity) if(ent->groundentity->union_ent) k = true;
//route update //route update
@ -1215,7 +1215,7 @@ void droptofloor (edict_t *ent)
gi.setmodel (ent, ent->model); gi.setmodel (ent, ent->model);
else else
gi.setmodel (ent, ent->item->world_model); gi.setmodel (ent, ent->item->world_model);
if(ent->classname[6] == 'F') ent->s.modelindex = 0; //かくせ if(ent->classname[6] == 'F') ent->s.modelindex = 0; //かくせ
ent->solid = SOLID_TRIGGER; ent->solid = SOLID_TRIGGER;
ent->movetype = MOVETYPE_TOSS; ent->movetype = MOVETYPE_TOSS;
@ -1373,7 +1373,7 @@ void droptofloor2 (edict_t *ent)
v = tv(8,8,15); v = tv(8,8,15);
VectorCopy (v, ent->maxs); VectorCopy (v, ent->maxs);
///////// /////////
if(ent->union_ent && Q_stricmp (ent->classname,"R_navi2")) //2は移動なし if(ent->union_ent && Q_stricmp (ent->classname,"R_navi2")) //2は移動なし
{ {
// dest[0] = (ent->union_ent->s.origin[0] + ent->union_ent->mins[0] + ent->union_ent->s.origin[0] + ent->union_ent->maxs[0])/2;//ent->s.origin[0]; // dest[0] = (ent->union_ent->s.origin[0] + ent->union_ent->mins[0] + ent->union_ent->s.origin[0] + ent->union_ent->maxs[0])/2;//ent->s.origin[0];
// dest[1] = (ent->union_ent->s.origin[1] + ent->union_ent->mins[1] + ent->union_ent->s.origin[1] + ent->union_ent->maxs[1])/2; // dest[1] = (ent->union_ent->s.origin[1] + ent->union_ent->mins[1] + ent->union_ent->s.origin[1] + ent->union_ent->maxs[1])/2;
@ -1404,7 +1404,7 @@ void droptofloor2 (edict_t *ent)
gi.setmodel (ent, ent->model); gi.setmodel (ent, ent->model);
else else
gi.setmodel (ent, ent->item->world_model);*/ gi.setmodel (ent, ent->item->world_model);*/
ent->s.modelindex = 0; //かくせ! ent->s.modelindex = 0; //かくせ!
//ent->s.modelindex =gi.modelindex ("models/items/armor/body/tris.md2"); //ent->s.modelindex =gi.modelindex ("models/items/armor/body/tris.md2");
if(Q_stricmp (ent->classname,"R_navi3") == 0) ent->solid = SOLID_NOT; if(Q_stricmp (ent->classname,"R_navi3") == 0) ent->solid = SOLID_NOT;
else ent->solid = SOLID_TRIGGER; else ent->solid = SOLID_TRIGGER;
@ -1657,8 +1657,8 @@ Items can't be immediately dropped to floor, because they might
be on an entity that hasn't spawned yet. be on an entity that hasn't spawned yet.
============ ============
*/ */
void SetBotFlag1(edict_t *ent); //チーム1の旗 void SetBotFlag1(edict_t *ent); //チーム1の旗
void SetBotFlag2(edict_t *ent); //チーム2の旗 void SetBotFlag2(edict_t *ent); //チーム2の旗
void SpawnItem (edict_t *ent, gitem_t *item) void SpawnItem (edict_t *ent, gitem_t *item)
{ {

View file

@ -392,22 +392,22 @@ typedef struct
// fixed data // fixed data
vec3_t start_origin; vec3_t start_origin;
vec3_t start_angles; vec3_t start_angles;
vec3_t end_origin; //BFGのターゲットポイントに不正使用 vec3_t end_origin; //BFGのターゲットポイントに不正使用
vec3_t end_angles; vec3_t end_angles;
int sound_start; //スナイパーのアクティベートフラグ int sound_start; //スナイパーのアクティベートフラグ
int sound_middle; int sound_middle;
int sound_end; //hokutoのクラス int sound_end; //hokutoのクラス
float accel; float accel;
float speed; //bot 落下時の移動量に不正使用 float speed; //bot 落下時の移動量に不正使用
float decel; //水面滞在時間に不正使用 float decel; //水面滞在時間に不正使用
float distance; //スナイパー用FOV値 float distance; //スナイパー用FOV値
float wait; float wait;
// state data // state data
int state; //CTFステータスに不正使用 int state; //CTFステータスに不正使用
vec3_t dir; vec3_t dir;
float current_speed; float current_speed;
float move_speed; float move_speed;
@ -928,14 +928,14 @@ typedef struct zgcl_s
{ {
int zclass; //class no. int zclass; //class no.
// true client用 zoom フラグ // true client用 zoom フラグ
int aiming; //0-not 1-aiming 2-firing zoomingflag int aiming; //0-not 1-aiming 2-firing zoomingflag
float distance; //zoom中のFOV値 float distance; //zoom中のFOV値
float olddistance; //旧zooming FOV値 float olddistance; //旧zooming FOV値
qboolean autozoom; //autozoom qboolean autozoom; //autozoom
qboolean lockon; //lockon flag false-not true-locking qboolean lockon; //lockon flag false-not true-locking
// bot用 // bot用
int zcstate; //status int zcstate; //status
int botskill; //skill int botskill; //skill

View file

@ -78,8 +78,8 @@ void ReadLevel (char *filename);
void InitGame (void); void InitGame (void);
void G_RunFrame (void); void G_RunFrame (void);
void SetBotFlag1(edict_t *ent); //チーム1の旗 void SetBotFlag1(edict_t *ent); //チーム1の旗
void SetBotFlag2(edict_t *ent); //チーム2の旗 void SetBotFlag2(edict_t *ent); //チーム2の旗
//=================================================================== //===================================================================
@ -545,7 +545,7 @@ void G_RunFrame (void)
ctfjob_update = level.time + FRAMETIME * 2; ctfjob_update = level.time + FRAMETIME * 2;
} }
} }
//////////旗のスコアチェック //////////旗のスコアチェック
if(zigmode->value == 1) if(zigmode->value == 1)
{ {
if(next_fragadd < level.time) if(next_fragadd < level.time)
@ -561,7 +561,7 @@ void G_RunFrame (void)
g_edicts[i].client->resp.score += 1; g_edicts[i].client->resp.score += 1;
else else
{ {
//旗を持ってるとフラッグを足す //旗を持ってるとフラッグを足す
for ( j = 1 ; j <= maxclients->value ; j++) for ( j = 1 ; j <= maxclients->value ; j++)
{ {
if(g_edicts[j].inuse) if(g_edicts[j].inuse)

View file

@ -128,8 +128,8 @@ only happens when a new game is started or a save game
is loaded. is loaded.
============ ============
*/ */
void SetBotFlag1(edict_t *ent); //チーム1の旗 void SetBotFlag1(edict_t *ent); //チーム1の旗
void SetBotFlag2(edict_t *ent); //チーム2の旗 void SetBotFlag2(edict_t *ent); //チーム2の旗
void InitGame (void) void InitGame (void)
{ {
gi.dprintf ("==== InitGame ====\n"); gi.dprintf ("==== InitGame ====\n");
@ -224,7 +224,7 @@ void InitGame (void)
//ZOID //ZOID
CTFInit(); CTFInit();
//ZOID //ZOID
Load_BotInfo(); //コンフィグ読み込み3ZBConfig.cfg Load_BotInfo(); //コンフィグ読み込み3ZBConfig.cfg
} }
//========================================================= //=========================================================

View file

@ -788,7 +788,7 @@ void G_FindRouteLink(edict_t *ent)
float x; float x;
//旗を発生させる //旗を発生させる
if(!ctf->value && zigmode->value == 1) if(!ctf->value && zigmode->value == 1)
{ {
item = FindItem("Zig Flag"); item = FindItem("Zig Flag");
@ -926,10 +926,10 @@ Creates a server's entity / program execution context by
parsing textual entity definitions out of an ent file. parsing textual entity definitions out of an ent file.
============== ==============
*/ */
//void SetBotFlag1(edict_t *ent); //チーム1の旗 //void SetBotFlag1(edict_t *ent); //チーム1の旗
//void SetBotFlag2(edict_t *ent); //チーム2の旗 //void SetBotFlag2(edict_t *ent); //チーム2の旗
//void CTFSetupNavSpawn(); //ナビの設置 //void CTFSetupNavSpawn(); //ナビの設置
void SpawnEntities (char *mapname, char *entities, char *spawnpoint) void SpawnEntities (char *mapname, char *entities, char *spawnpoint)
{ {
edict_t *ent; edict_t *ent;
@ -1033,7 +1033,7 @@ void SpawnEntities (char *mapname, char *entities, char *spawnpoint)
PlayerTrail_Init (); PlayerTrail_Init ();
//func_trainのリンク //func_trainのリンク
G_FindTrainTeam(); G_FindTrainTeam();
@ -1043,16 +1043,16 @@ void SpawnEntities (char *mapname, char *entities, char *spawnpoint)
//ZOID //ZOID
//ponko //ponko
CTFSetupNavSpawn(); //ナビの設置 CTFSetupNavSpawn(); //ナビの設置
if(!chedit->value) G_FindItemLink(); //アイテムのリンク(通常時のみ) if(!chedit->value) G_FindItemLink(); //アイテムのリンク(通常時のみ)
G_SpawnRouteLink(); G_SpawnRouteLink();
if(zigmode->value == 1) zigflag_spawn = 1; if(zigmode->value == 1) zigflag_spawn = 1;
else zigflag_spawn = 0; else zigflag_spawn = 0;
//旗のアイテムアドレス取得 //旗のアイテムアドレス取得
zflag_item = FindItem("Zig Flag"); zflag_item = FindItem("Zig Flag");
zflag_ent = NULL; //初期化 zflag_ent = NULL; //初期化
// if(CurrentIndex > 0) // if(CurrentIndex > 0)
//ponko //ponko

View file

@ -252,8 +252,8 @@ void SVCmd_WriteIP_f (void)
//ルート修正 //ルート修正
//ノーマルポッドは全て切り捨て //ノーマルポッドは全て切り捨て
void Move_LastRouteIndex() void Move_LastRouteIndex()
{ {
int i; int i;
@ -273,7 +273,7 @@ void Move_LastRouteIndex()
} }
} }
//分岐付きに変換処理 //分岐付きに変換処理
void RouteTreepointSet() void RouteTreepointSet()
{ {
int i; int i;
@ -296,7 +296,7 @@ void Svcmd_Test_f (void)
gi.cprintf (NULL, PRINT_HIGH, "Svcmd_Test_f()\n"); gi.cprintf (NULL, PRINT_HIGH, "Svcmd_Test_f()\n");
} }
//chainファイルのセーブ //chainファイルのセーブ
void SaveChain() void SaveChain()
{ {
char name[256]; char name[256];
@ -309,7 +309,7 @@ void SaveChain()
return; return;
} }
//とりあえずCTFだめ //とりあえずCTFだめ
if(ctf->value) sprintf(name,".\\%s\\chctf\\%s.chf",gamepath->string,level.mapname); if(ctf->value) sprintf(name,".\\%s\\chctf\\%s.chf",gamepath->string,level.mapname);
else sprintf(name,".\\%s\\chdtm\\%s.chn",gamepath->string,level.mapname); else sprintf(name,".\\%s\\chdtm\\%s.chn",gamepath->string,level.mapname);

View file

@ -663,7 +663,7 @@ UpdateExplIndex(rocket);
gi.linkentity (rocket); gi.linkentity (rocket);
} }
//ロックオンミサイル //ロックオンミサイル
void think_lockon_rocket(edict_t *ent) void think_lockon_rocket(edict_t *ent)
{ {
vec3_t v; vec3_t v;
@ -715,7 +715,7 @@ void think_lockon_rocket(edict_t *ent)
return; return;
} }
//時間切れ //時間切れ
if(ent->moveinfo.accel <= level.time) if(ent->moveinfo.accel <= level.time)
{ {
T_RadiusDamage(ent, ent->owner, ent->radius_dmg, NULL, ent->dmg_radius, MOD_R_SPLASH); T_RadiusDamage(ent, ent->owner, ent->radius_dmg, NULL, ent->dmg_radius, MOD_R_SPLASH);

View file

@ -571,7 +571,7 @@ void player_die (edict_t *self, edict_t *inflictor, edict_t *attacker, int damag
if(ctf->value) CTFFragBonuses(self, inflictor, attacker); if(ctf->value) CTFFragBonuses(self, inflictor, attacker);
//ZOID //ZOID
//旗持ってる場合は落とす //旗持ってる場合は落とす
if(self->client->pers.inventory[ITEM_INDEX(zflag_item)]) if(self->client->pers.inventory[ITEM_INDEX(zflag_item)])
zflag_item->drop(self,zflag_item); zflag_item->drop(self,zflag_item);
@ -1061,7 +1061,7 @@ void CopyToBodyQue (edict_t *ent)
body->s = ent->s; body->s = ent->s;
body->s.number = body - g_edicts; body->s.number = body - g_edicts;
//強引にフレームセット //強引にフレームセット
if(body->s.modelindex == skullindex || body->s.modelindex == headindex) body->s.frame = 0; if(body->s.modelindex == skullindex || body->s.modelindex == headindex) body->s.frame = 0;
body->svflags = ent->svflags; body->svflags = ent->svflags;

View file

@ -994,7 +994,7 @@ void Weapon_RocketLauncher_Fire (edict_t *ent)
if(ent->client->zc.aiming != 4) fire_rocket (ent, start, forward, damage, 650, damage_radius, radius_damage); if(ent->client->zc.aiming != 4) fire_rocket (ent, start, forward, damage, 650, damage_radius, radius_damage);
else else
{ {
damage -= 20;//ロックオンは20ダメージ減り damage -= 20;//ロックオンは20ダメージ減り
fire_lockon_rocket (ent, start, forward, damage, 20, damage_radius, radius_damage); fire_lockon_rocket (ent, start, forward, damage, 20, damage_radius, radius_damage);
} }
@ -1011,11 +1011,11 @@ void Weapon_RocketLauncher_Fire (edict_t *ent)
if (! ( (int)dmflags->value & DF_INFINITE_AMMO ) ) if (! ( (int)dmflags->value & DF_INFINITE_AMMO ) )
ent->client->pers.inventory[ent->client->ammo_index]--; ent->client->pers.inventory[ent->client->ammo_index]--;
// ent->client->ps.fov = 90; //ズーム解除 // ent->client->ps.fov = 90; //ズーム解除
ent->client->zc.aiming = 0; //ズーム不可 ent->client->zc.aiming = 0; //ズーム不可
} }
//ロックオンロケットランチャー //ロックオンロケットランチャー
void Weapon_LockonRocketLauncher_Fire (edict_t *ent) void Weapon_LockonRocketLauncher_Fire (edict_t *ent)
{ {
vec3_t tmp,out,aim,min,max; vec3_t tmp,out,aim,min,max;
@ -1024,13 +1024,13 @@ void Weapon_LockonRocketLauncher_Fire (edict_t *ent)
if (ent->client->buttons & BUTTON_ATTACK) if (ent->client->buttons & BUTTON_ATTACK)
{ {
ent->client->zc.lockon = false; //スナイパーにロックオン機能なし ent->client->zc.lockon = false; //スナイパーにロックオン機能なし
if(ent->client->zc.aiming == 0) if(ent->client->zc.aiming == 0)
{ {
gi.sound (ent, CHAN_WEAPON, gi.soundindex("weapons/sshotr1b.wav"), 1, ATTN_NONE, 0); gi.sound (ent, CHAN_WEAPON, gi.soundindex("weapons/sshotr1b.wav"), 1, ATTN_NONE, 0);
ent->client->zc.aiming = 3; ent->client->zc.aiming = 3;
if(ent->client->zc.distance <10 || ent->client->zc.distance > 90) ent->client->zc.distance = 90; if(ent->client->zc.distance <10 || ent->client->zc.distance > 90) ent->client->zc.distance = 90;
ent->client->ps.fov = ent->client->zc.distance;//ズーム開始 ent->client->ps.fov = ent->client->zc.distance;//ズーム開始
} }
VectorSet(max,8,8,8); VectorSet(max,8,8,8);
@ -1065,7 +1065,7 @@ void Weapon_LockonRocketLauncher_Fire (edict_t *ent)
gi.sound (ent, CHAN_AUTO, gi.soundindex("3zb/locrloc.wav"), 1, ATTN_NORM, 0); gi.sound (ent, CHAN_AUTO, gi.soundindex("3zb/locrloc.wav"), 1, ATTN_NORM, 0);
ent->client->zc.first_target = rs_trace.ent; ent->client->zc.first_target = rs_trace.ent;
} }
return; //オートズーム反応せず return; //オートズーム反応せず
} }
else ent->client->zc.first_target = NULL; else ent->client->zc.first_target = NULL;
} }
@ -1107,7 +1107,7 @@ void Weapon_RocketLauncher (edict_t *ent)
static int pause_frames[] = {25, 33, 42, 50, 0}; static int pause_frames[] = {25, 33, 42, 50, 0};
static int fire_frames[] = {5, 0}; static int fire_frames[] = {5, 0};
if(!(ent->client->buttons & BUTTON_ATTACK)) ent->client->zc.aiming = 0; //アクティベート0 if(!(ent->client->buttons & BUTTON_ATTACK)) ent->client->zc.aiming = 0; //アクティベート0
if(0/*1*/) if(0/*1*/)
{ {
@ -1824,7 +1824,7 @@ void RSight_think(edict_t *ent)
if(rs_trace.ent != NULL) if(rs_trace.ent != NULL)
{ {
if(Q_stricmp (rs_trace.ent->classname, "player") == 0) return;//オートズーム反応せず if(Q_stricmp (rs_trace.ent->classname, "player") == 0) return;//オートズーム反応せず
} }
if(ent->owner->client->zc.autozoom ) if(ent->owner->client->zc.autozoom )
@ -1909,20 +1909,20 @@ void weapon_railgun_fire (edict_t *ent)
if (! ( (int)dmflags->value & DF_INFINITE_AMMO ) ) if (! ( (int)dmflags->value & DF_INFINITE_AMMO ) )
ent->client->pers.inventory[ent->client->ammo_index]--; ent->client->pers.inventory[ent->client->ammo_index]--;
// ent->client->ps.fov = 90; //ズーム解除 // ent->client->ps.fov = 90; //ズーム解除
ent->client->zc.aiming = 0; //ズーム不可 ent->client->zc.aiming = 0; //ズーム不可
} }
//スナイパー用railガン //スナイパー用railガン
void Weapon_SnipeRailgun (edict_t *ent) void Weapon_SnipeRailgun (edict_t *ent)
{ {
edict_t *sight; edict_t *sight;
if (ent->client->buttons & BUTTON_ATTACK) if (ent->client->buttons & BUTTON_ATTACK)
{ {
ent->client->zc.lockon = false; //スナイパーにロックオン機能なし ent->client->zc.lockon = false; //スナイパーにロックオン機能なし
if( ent->client->zc.aiming == 0) if( ent->client->zc.aiming == 0)
{ {
//サイトの作成 //サイトの作成
sight = G_Spawn(); sight = G_Spawn();
VectorClear (sight->mins); VectorClear (sight->mins);
VectorClear (sight->maxs); VectorClear (sight->maxs);
@ -1944,7 +1944,7 @@ void Weapon_SnipeRailgun (edict_t *ent)
gi.sound (ent, CHAN_WEAPON, gi.soundindex("weapons/sshotr1b.wav"), 1, ATTN_NONE, 0); gi.sound (ent, CHAN_WEAPON, gi.soundindex("weapons/sshotr1b.wav"), 1, ATTN_NONE, 0);
ent->client->zc.aiming = 1; ent->client->zc.aiming = 1;
if(ent->client->zc.distance <10 || ent->client->zc.distance > 90) ent->client->zc.distance = 90; if(ent->client->zc.distance <10 || ent->client->zc.distance > 90) ent->client->zc.distance = 90;
ent->client->ps.fov = ent->client->zc.distance;//ズーム開始 ent->client->ps.fov = ent->client->zc.distance;//ズーム開始
} }
return; return;
} }
@ -1959,7 +1959,7 @@ void Weapon_Railgun (edict_t *ent)
static int pause_frames[] = {56, 0}; static int pause_frames[] = {56, 0};
static int fire_frames[] = {4, 0}; static int fire_frames[] = {4, 0};
if(!(ent->client->buttons & BUTTON_ATTACK)) ent->client->zc.aiming = 0; //アクティベート0 if(!(ent->client->buttons & BUTTON_ATTACK)) ent->client->zc.aiming = 0; //アクティベート0
if(0) if(0)
{ {