• R/O
  • SSH
  • HTTPS

Commit

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

X operations(XOPS)に非常に近いFPSゲームを制作・リメイクし、成果物をオープンソースとして公開することを目的としたプロジェクトです。


Commit MetaInfo

Revision115 (tree)
Time2015-11-03 13:14:20
Authorxops-mikan

Log Message

歩いて移動している時に走りの操作も行っていると、AIが警戒してしまう問題の修正。

Change Summary

Incremental Difference

--- trunk/objectmanager.cpp (revision 114)
+++ trunk/objectmanager.cpp (revision 115)
@@ -1548,13 +1548,6 @@
15481548
15491549 //オブジェクトにフラグを設定
15501550 HumanIndex[human_id].SetMoveForward();
1551-
1552- //走る足音追加
1553- float posx, posy, posz;
1554- int teamid;
1555- HumanIndex[human_id].GetPosData(&posx, &posy, &posz, NULL);
1556- HumanIndex[human_id].GetParamData(NULL, NULL, NULL, &teamid);
1557- GameSound->SetFootsteps(posx, posy, posz, teamid);
15581551 }
15591552
15601553 //! @brief 後退を実行
@@ -1566,13 +1559,6 @@
15661559
15671560 //オブジェクトにフラグを設定
15681561 HumanIndex[human_id].SetMoveBack();
1569-
1570- //走る足音追加
1571- float posx, posy, posz;
1572- int teamid;
1573- HumanIndex[human_id].GetPosData(&posx, &posy, &posz, NULL);
1574- HumanIndex[human_id].GetParamData(NULL, NULL, NULL, &teamid);
1575- GameSound->SetFootsteps(posx, posy, posz, teamid);
15761562 }
15771563
15781564 //! @brief 左走りを実行
@@ -1584,13 +1570,6 @@
15841570
15851571 //オブジェクトにフラグを設定
15861572 HumanIndex[human_id].SetMoveLeft();
1587-
1588- //走る足音追加
1589- float posx, posy, posz;
1590- int teamid;
1591- HumanIndex[human_id].GetPosData(&posx, &posy, &posz, NULL);
1592- HumanIndex[human_id].GetParamData(NULL, NULL, NULL, &teamid);
1593- GameSound->SetFootsteps(posx, posy, posz, teamid);
15941573 }
15951574
15961575 //! @brief 右走りを実行
@@ -1602,13 +1581,6 @@
16021581
16031582 //オブジェクトにフラグを設定
16041583 HumanIndex[human_id].SetMoveRight();
1605-
1606- //走る足音追加
1607- float posx, posy, posz;
1608- int teamid;
1609- HumanIndex[human_id].GetPosData(&posx, &posy, &posz, NULL);
1610- HumanIndex[human_id].GetParamData(NULL, NULL, NULL, &teamid);
1611- GameSound->SetFootsteps(posx, posy, posz, teamid);
16121584 }
16131585
16141586 //! @brief 歩きを実行
@@ -2255,6 +2227,16 @@
22552227 //死亡時のエフェクト
22562228 DeadEffect(&(HumanIndex[i]));
22572229 }
2230+
2231+ //足音
2232+ if( HumanIndex[i].GetMovemode(false) == 2 ){
2233+ //走る足音追加
2234+ float posx, posy, posz;
2235+ int teamid;
2236+ HumanIndex[i].GetPosData(&posx, &posy, &posz, NULL);
2237+ HumanIndex[i].GetParamData(NULL, NULL, NULL, &teamid);
2238+ GameSound->SetFootsteps(posx, posy, posz, teamid);
2239+ }
22582240 }
22592241
22602242 //武器オブジェクトの処理