X operations(XOPS)に非常に近いFPSゲームを制作・リメイクし、成果物をオープンソースとして公開することを目的としたプロジェクトです。
| Revision | 337 (tree) |
|---|---|
| Time | 2022-11-13 16:24:25 |
| Author | |
ポイントパラメーターの値を、signed char型(1byte)からsigned short int型(2byte)に変更。
| @@ -2030,7 +2030,7 @@ | ||
| 2030 | 2030 | class human *targethuman; |
| 2031 | 2031 | |
| 2032 | 2032 | if( target_humanid == -1 ){ |
| 2033 | - signed char nextpointp4 = pdata.p3; | |
| 2033 | + signed short int nextpointp4 = pdata.p3; | |
| 2034 | 2034 | |
| 2035 | 2035 | //ポイント(人)の情報を取得 |
| 2036 | 2036 | if( Points->SearchPointdata(&pdata, 0x08, 0, 0, 0, nextpointp4, 0) == 0 ){ |
| @@ -2079,7 +2079,7 @@ | ||
| 2079 | 2079 | return false; |
| 2080 | 2080 | } |
| 2081 | 2081 | |
| 2082 | - signed char nextpointp4 = pdata.p3; | |
| 2082 | + signed short int nextpointp4 = pdata.p3; | |
| 2083 | 2083 | |
| 2084 | 2084 | //ランダムパス処理 |
| 2085 | 2085 | if( pdata.p1 == 8 ){ |
| @@ -420,7 +420,7 @@ | ||
| 420 | 420 | FILE *fp; |
| 421 | 421 | unsigned char pdata_header[2]; |
| 422 | 422 | float pdata_mainf[4]; |
| 423 | - char pdata_mainc[4]; | |
| 423 | + signed char pdata_mainc[4]; | |
| 424 | 424 | char fname2[MAX_PATH]; |
| 425 | 425 | |
| 426 | 426 | #ifdef ENABLE_DEBUGLOG |
| @@ -456,10 +456,10 @@ | ||
| 456 | 456 | |
| 457 | 457 | //パラメータ取得 |
| 458 | 458 | fread( pdata_mainc, 1, 4, fp ); |
| 459 | - data[i].p1 = pdata_mainc[0]; | |
| 460 | - data[i].p2 = pdata_mainc[1]; | |
| 461 | - data[i].p3 = pdata_mainc[2]; | |
| 462 | - data[i].p4 = pdata_mainc[3]; | |
| 459 | + data[i].p1 = (signed short int)pdata_mainc[0]; | |
| 460 | + data[i].p2 = (signed short int)pdata_mainc[1]; | |
| 461 | + data[i].p3 = (signed short int)pdata_mainc[2]; | |
| 462 | + data[i].p4 = (signed short int)pdata_mainc[3]; | |
| 463 | 463 | } |
| 464 | 464 | |
| 465 | 465 | //ファイルポインタを閉じる |
| @@ -564,7 +564,7 @@ | ||
| 564 | 564 | //! @param p4 第4パラメータ |
| 565 | 565 | //! @return 成功:0 失敗:0以外 |
| 566 | 566 | //! @warning AIが使用するパス(p1:3 or p1:8)以外への使用は、保証されておらず推奨しません。 |
| 567 | -int PointDataInterface::SetParam(int id, signed char p1, signed char p2, signed char p3, signed char p4) | |
| 567 | +int PointDataInterface::SetParam(int id, signed short int p1, signed short int p2, signed short int p3, signed short int p4) | |
| 568 | 568 | { |
| 569 | 569 | if( data == NULL ){ return 1; } |
| 570 | 570 | if( (id < 0)||(datas <= id) ){ return 2; } |
| @@ -610,7 +610,7 @@ | ||
| 610 | 610 | //! 0x05 // p1とp3を検索対象にする |
| 611 | 611 | //! 0xF1 // p1のみを検索対象にする (7〜5ビット目は無視) |
| 612 | 612 | //! @endcode |
| 613 | -int PointDataInterface::SearchPointdata(int* id, unsigned char pmask, signed char p1, signed char p2, signed char p3, signed char p4, int offset) | |
| 613 | +int PointDataInterface::SearchPointdata(int* id, unsigned char pmask, signed short int p1, signed short int p2, signed short int p3, signed short int p4, int offset) | |
| 614 | 614 | { |
| 615 | 615 | int cnt = 0; |
| 616 | 616 |
| @@ -653,7 +653,7 @@ | ||
| 653 | 653 | //! @param offset 検索を開始するデータ |
| 654 | 654 | //! @return 該当ポイント数 |
| 655 | 655 | //! @attention この関数の詳しい説明は、同オーバーロード関数をご覧ください。 |
| 656 | -int PointDataInterface::SearchPointdata(pointdata *out_data, unsigned char pmask, signed char p1, signed char p2, signed char p3, signed char p4, int offset) | |
| 656 | +int PointDataInterface::SearchPointdata(pointdata *out_data, unsigned char pmask, signed short int p1, signed short int p2, signed short int p3, signed short int p4, int offset) | |
| 657 | 657 | { |
| 658 | 658 | int id, total; |
| 659 | 659 |
| @@ -89,10 +89,10 @@ | ||
| 89 | 89 | float y; //!< Position |
| 90 | 90 | float z; //!< Position |
| 91 | 91 | float r; //!< Rotation |
| 92 | - signed char p1; //!< Param | |
| 93 | - signed char p2; //!< Param | |
| 94 | - signed char p3; //!< Param | |
| 95 | - signed char p4; //!< Param | |
| 92 | + signed short int p1; //!< Param | |
| 93 | + signed short int p2; //!< Param | |
| 94 | + signed short int p3; //!< Param | |
| 95 | + signed short int p4; //!< Param | |
| 96 | 96 | } pointdata; |
| 97 | 97 | |
| 98 | 98 | //! 追加小物用の構造体 |
| @@ -155,10 +155,10 @@ | ||
| 155 | 155 | ~PointDataInterface(); |
| 156 | 156 | int LoadFiledata(const char *fname); |
| 157 | 157 | int Getdata(pointdata *out_data, int id); |
| 158 | - int SetParam(int id, signed char p1, signed char p2, signed char p3, signed char p4); | |
| 158 | + int SetParam(int id, signed short int p1, signed short int p2, signed short int p3, signed short int p4); | |
| 159 | 159 | int GetMessageText(char *str, int id); |
| 160 | - int SearchPointdata(int* id, unsigned char pmask, signed char p1, signed char p2, signed char p3, signed char p4, int offset = 0); | |
| 161 | - int SearchPointdata(pointdata *out_data, unsigned char pmask, signed char p1, signed char p2, signed char p3, signed char p4, int offset = 0); | |
| 160 | + int SearchPointdata(int* id, unsigned char pmask, signed short int p1, signed short int p2, signed short int p3, signed short int p4, int offset = 0); | |
| 161 | + int SearchPointdata(pointdata *out_data, unsigned char pmask, signed short int p1, signed short int p2, signed short int p3, signed short int p4, int offset = 0); | |
| 162 | 162 | }; |
| 163 | 163 | |
| 164 | 164 | //! @brief MIFを管理するクラス |
| @@ -56,7 +56,7 @@ | ||
| 56 | 56 | |
| 57 | 57 | //! @brief リセット |
| 58 | 58 | //! @param EntryP4 イベント処理を開始する認識番号 (-100、-110、-120 など) |
| 59 | -void EventControl::Reset(signed char EntryP4) | |
| 59 | +void EventControl::Reset(signed short int EntryP4) | |
| 60 | 60 | { |
| 61 | 61 | nextp4 = EntryP4; |
| 62 | 62 | waitcnt = 0; |
| @@ -64,7 +64,7 @@ | ||
| 64 | 64 | |
| 65 | 65 | //! @brief 次に処理する認識番号 |
| 66 | 66 | //! @return P4:認識番号 |
| 67 | -signed char EventControl::GetNextP4() | |
| 67 | +signed short int EventControl::GetNextP4() | |
| 68 | 68 | { |
| 69 | 69 | return nextp4; |
| 70 | 70 | } |
| @@ -74,7 +74,7 @@ | ||
| 74 | 74 | //! @param reverse 条件反転(生存判定化) |
| 75 | 75 | //! @return true:次のイベントへ進む false:次へ進まない |
| 76 | 76 | //! @attention 対象人物が存在しない場合、falseになります。 |
| 77 | -bool EventControl::CheckDead(signed char targetP4, bool reverse) | |
| 77 | +bool EventControl::CheckDead(signed short int targetP4, bool reverse) | |
| 78 | 78 | { |
| 79 | 79 | human* thuman; |
| 80 | 80 |
| @@ -99,7 +99,7 @@ | ||
| 99 | 99 | //! @param reverse 条件反転(未着判定化) |
| 100 | 100 | //! @return true:次のイベントへ進む false:次へ進まない |
| 101 | 101 | //! @attention 対象人物が存在しない場合、falseになります。 |
| 102 | -bool EventControl::CheckArrival(float pos_x, float pos_y, float pos_z, float dist_r, signed char targetP4, bool reverse) | |
| 102 | +bool EventControl::CheckArrival(float pos_x, float pos_y, float pos_z, float dist_r, signed short int targetP4, bool reverse) | |
| 103 | 103 | { |
| 104 | 104 | human* thuman; |
| 105 | 105 | float hx, hy, hz; |
| @@ -127,7 +127,7 @@ | ||
| 127 | 127 | //! @param reverse 条件反転(未所有判定化) |
| 128 | 128 | //! @return true:次のイベントへ進む false:次へ進まない |
| 129 | 129 | //! @attention 対象人物が存在しない場合、falseになります。 |
| 130 | -bool EventControl::CheckHaveWeapon(int WeaponID, signed char targetP4, bool reverse) | |
| 130 | +bool EventControl::CheckHaveWeapon(int WeaponID, signed short int targetP4, bool reverse) | |
| 131 | 131 | { |
| 132 | 132 | human* thuman; |
| 133 | 133 | int selectweapon; |
| @@ -167,7 +167,7 @@ | ||
| 167 | 167 | //! @param targetP4 ターゲットの認識番号 |
| 168 | 168 | //! @param newmode 移動モード |
| 169 | 169 | //! @return 成功:true 失敗:false |
| 170 | -bool EventControl::SetMovePathMode(signed char targetP4, int newmode) | |
| 170 | +bool EventControl::SetMovePathMode(signed short int targetP4, int newmode) | |
| 171 | 171 | { |
| 172 | 172 | pointdata pathdata; |
| 173 | 173 | int pid; |
| @@ -177,7 +177,7 @@ | ||
| 177 | 177 | //対象がAIパスならば、強制的にパラメータを書き換える |
| 178 | 178 | Point->Getdata(&pathdata, pid); |
| 179 | 179 | if( (pathdata.p1 == 3)||(pathdata.p1 == 8) ){ |
| 180 | - pathdata.p2 = (signed char)newmode; | |
| 180 | + pathdata.p2 = (signed short int)newmode; | |
| 181 | 181 | Point->SetParam(pid, pathdata.p1, pathdata.p2, pathdata.p3, pathdata.p4); |
| 182 | 182 | return true; |
| 183 | 183 | } |
| @@ -190,7 +190,7 @@ | ||
| 190 | 190 | //! @param targetP4 ターゲットの認識番号 |
| 191 | 191 | //! @param TeamID チーム番号 |
| 192 | 192 | //! @return 成功:true 失敗:false |
| 193 | -bool EventControl::SetTeamID(signed char targetP4, int TeamID) | |
| 193 | +bool EventControl::SetTeamID(signed short int targetP4, int TeamID) | |
| 194 | 194 | { |
| 195 | 195 | human* thuman; |
| 196 | 196 |
| @@ -206,7 +206,7 @@ | ||
| 206 | 206 | //! @param reverse 条件反転(未破壊判定化) |
| 207 | 207 | //! @return true:次のイベントへ進む false:次へ進まない |
| 208 | 208 | //! @attention 対象小物が存在しない場合、破壊済みとして処理されます。 |
| 209 | -bool EventControl::CheckBreakSmallObject(signed char targetP4, bool reverse) | |
| 209 | +bool EventControl::CheckBreakSmallObject(signed short int targetP4, bool reverse) | |
| 210 | 210 | { |
| 211 | 211 | smallobject* tsmallobject; |
| 212 | 212 | bool flag = true; //false:未破壊、true:破壊済みor存在しない |
| @@ -56,15 +56,15 @@ | ||
| 56 | 56 | { |
| 57 | 57 | class PointDataInterface *Point; //!< PointDataInterfaceクラスのポインタ |
| 58 | 58 | class ObjectManager *ObjMgr; //!< ObjectManagerクラスのポインタ |
| 59 | - signed char nextp4; //!< 次に処理するP4:認識番号 | |
| 60 | - int waitcnt; //!< 時間待ち用カウント | |
| 59 | + signed short int nextp4; //!< 次に処理するP4:認識番号 | |
| 60 | + int waitcnt; //!< 時間待ち用カウント | |
| 61 | 61 | |
| 62 | - bool CheckDead(signed char targetP4, bool reverse); | |
| 63 | - bool CheckArrival(float pos_x, float pos_y, float pos_z, float dist_r, signed char targetP4, bool reverse); | |
| 64 | - bool CheckHaveWeapon(int WeaponID, signed char targetP4, bool reverse); | |
| 65 | - bool SetMovePathMode(signed char targetP4, int newmode); | |
| 66 | - bool SetTeamID(signed char targetP4, int TeamID); | |
| 67 | - bool CheckBreakSmallObject(signed char targetP4, bool reverse); | |
| 62 | + bool CheckDead(signed short int targetP4, bool reverse); | |
| 63 | + bool CheckArrival(float pos_x, float pos_y, float pos_z, float dist_r, signed short int targetP4, bool reverse); | |
| 64 | + bool CheckHaveWeapon(int WeaponID, signed short int targetP4, bool reverse); | |
| 65 | + bool SetMovePathMode(signed short int targetP4, int newmode); | |
| 66 | + bool SetTeamID(signed short int targetP4, int TeamID); | |
| 67 | + bool CheckBreakSmallObject(signed short int targetP4, bool reverse); | |
| 68 | 68 | bool WaitSec(int sec); |
| 69 | 69 | void SetMessage(int SetID, int *MessageID, bool *SetMessageID); |
| 70 | 70 |
| @@ -72,8 +72,8 @@ | ||
| 72 | 72 | EventControl(PointDataInterface *in_Point = NULL, ObjectManager *in_ObjMgr = NULL); |
| 73 | 73 | ~EventControl(); |
| 74 | 74 | void SetClass(PointDataInterface *in_Point, ObjectManager *in_ObjMgr); |
| 75 | - void Reset(signed char EntryP4); | |
| 76 | - signed char GetNextP4(); | |
| 75 | + void Reset(signed short int EntryP4); | |
| 76 | + signed short int GetNextP4(); | |
| 77 | 77 | int ProcessEventPoint(bool SkipFlag, EventParameter *Param); |
| 78 | 78 | }; |
| 79 | 79 |
| @@ -3435,7 +3435,7 @@ | ||
| 3435 | 3435 | //イベントの到着ポイントを表示 |
| 3436 | 3436 | if( EventStop == false ){ |
| 3437 | 3437 | for(int i=0; i<TOTAL_EVENTLINE; i++){ |
| 3438 | - signed char p4 = Event[i].GetNextP4(); | |
| 3438 | + signed short int p4 = Event[i].GetNextP4(); | |
| 3439 | 3439 | pointdata data; |
| 3440 | 3440 | if( PointData.SearchPointdata(&data, 0x08, 0, 0, 0, p4, 0) != 0 ){ |
| 3441 | 3441 | float y; |
| @@ -3656,7 +3656,7 @@ | ||
| 3656 | 3656 | //イベントタスク表示 |
| 3657 | 3657 | if( strcmp(NewCommand, "event") == 0 ){ |
| 3658 | 3658 | for(int i=0; i<TOTAL_EVENTLINE; i++){ |
| 3659 | - signed char p4 = Event[i].GetNextP4(); | |
| 3659 | + signed short int p4 = Event[i].GetNextP4(); | |
| 3660 | 3660 | pointdata data; |
| 3661 | 3661 | if( PointData.SearchPointdata(&data, 0x08, 0, 0, 0, p4, 0) == 0 ){ |
| 3662 | 3662 | sprintf(str, "Event %d No task.", i); |
| @@ -3671,7 +3671,7 @@ | ||
| 3671 | 3671 | //イベントタスクスキップ |
| 3672 | 3672 | if( GetCommandNum("skip", &id) == true ){ |
| 3673 | 3673 | if( (0 <= id)&&(id < TOTAL_EVENTLINE) ){ |
| 3674 | - signed char p4 = Event[id].GetNextP4(); | |
| 3674 | + signed short int p4 = Event[id].GetNextP4(); | |
| 3675 | 3675 | pointdata data; |
| 3676 | 3676 | if( PointData.SearchPointdata(&data, 0x08, 0, 0, 0, p4, 0) == 0 ){ |
| 3677 | 3677 | sprintf(str, "Event %d No task.", id); |
| @@ -157,7 +157,7 @@ | ||
| 157 | 157 | } |
| 158 | 158 | |
| 159 | 159 | //! @brief コンストラクタ |
| 160 | -human::human(class ParameterInfo *in_Param, float x, float y, float z, float rx, int id_param, int dataid, signed char p4, int team, bool flag) | |
| 160 | +human::human(class ParameterInfo *in_Param, float x, float y, float z, float rx, int id_param, int dataid, signed short int p4, int team, bool flag) | |
| 161 | 161 | { |
| 162 | 162 | //HumanParameter data; |
| 163 | 163 |
| @@ -241,7 +241,7 @@ | ||
| 241 | 241 | //! @param team チーム番号 |
| 242 | 242 | //! @param init オブジェクトを初期化 |
| 243 | 243 | //! @warning init引数をtrueにして初期化する場合、先にSetPosData()関数で角度を設定しておくこと。 |
| 244 | -void human::SetParamData(int id_param, int dataid, signed char p4, int team, bool init) | |
| 244 | +void human::SetParamData(int id_param, int dataid, signed short int p4, int team, bool init) | |
| 245 | 245 | { |
| 246 | 246 | id_parameter = id_param; |
| 247 | 247 | point_dataid = dataid; |
| @@ -297,7 +297,7 @@ | ||
| 297 | 297 | //! @param dataid ポイントのデータ番号を受け取るポインタ(NULL可) |
| 298 | 298 | //! @param p4 第4パラメータを受け取るポインタ(NULL可) |
| 299 | 299 | //! @param team チーム番号を受け取るポインタ(NULL可) |
| 300 | -void human::GetParamData(int *id_param, int *dataid, signed char *p4, int *team) | |
| 300 | +void human::GetParamData(int *id_param, int *dataid, signed short int *p4, int *team) | |
| 301 | 301 | { |
| 302 | 302 | if( id_param != NULL ){ *id_param = id_parameter; } |
| 303 | 303 | if( dataid != NULL ){ *dataid = point_dataid; } |
| @@ -2392,7 +2392,7 @@ | ||
| 2392 | 2392 | } |
| 2393 | 2393 | |
| 2394 | 2394 | //! @brief コンストラクタ |
| 2395 | -smallobject::smallobject(class ParameterInfo *in_Param, class MIFInterface *in_MIFdata, float x, float y, float z, float rx, int id_param, signed char p4, bool flag) | |
| 2395 | +smallobject::smallobject(class ParameterInfo *in_Param, class MIFInterface *in_MIFdata, float x, float y, float z, float rx, int id_param, signed short int p4, bool flag) | |
| 2396 | 2396 | { |
| 2397 | 2397 | Param = in_Param; |
| 2398 | 2398 | MIFdata = in_MIFdata; |
| @@ -2439,7 +2439,7 @@ | ||
| 2439 | 2439 | //! @param id_param 小物の種類番号 |
| 2440 | 2440 | //! @param p4 第4パラメータ |
| 2441 | 2441 | //! @param init オブジェクトを初期化 |
| 2442 | -void smallobject::SetParamData(int id_param, signed char p4, bool init) | |
| 2442 | +void smallobject::SetParamData(int id_param, signed short int p4, bool init) | |
| 2443 | 2443 | { |
| 2444 | 2444 | rotation_y = 0.0f; |
| 2445 | 2445 | id_parameter = id_param; |
| @@ -2472,7 +2472,7 @@ | ||
| 2472 | 2472 | //! @brief 設定値を取得 |
| 2473 | 2473 | //! @param id_param 小物の種類番号を受け取るポインタ(NULL可) |
| 2474 | 2474 | //! @param p4 第4パラメータを受け取るポインタ(NULL可) |
| 2475 | -void smallobject::GetParamData(int *id_param, signed char *p4) | |
| 2475 | +void smallobject::GetParamData(int *id_param, signed short int *p4) | |
| 2476 | 2476 | { |
| 2477 | 2477 | if( id_param != NULL ){ *id_param = id_parameter; } |
| 2478 | 2478 | if( p4 != NULL ){ *p4 = point_p4; } |
| @@ -135,20 +135,20 @@ | ||
| 135 | 135 | class human : public object |
| 136 | 136 | { |
| 137 | 137 | protected: |
| 138 | - int point_dataid; //!< ポイントのデータ番号 | |
| 139 | - signed char point_p4; //!< ポイントの認識番号 | |
| 140 | - int teamid; //!< チーム番号 | |
| 141 | - float move_x; //!< X軸速度 | |
| 142 | - float move_y; //!< Y軸(落下)速度 | |
| 143 | - float move_z; //!< Z軸速度 | |
| 144 | - bool move_y_flag; //!< Y軸移動フラグ | |
| 145 | - int move_y_upper; //!< Y軸上昇禁止カウンター | |
| 146 | - bool move_y_landing; //!< 着地フラグ | |
| 147 | - float rotation_y; //!< 全体の回転角度 | |
| 148 | - float armrotation_y; //!< 腕の回転角度 | |
| 149 | - float upmodel_size; //!< 上半身描画サイズ | |
| 150 | - float armmodel_size; //!< 腕描画サイズ | |
| 151 | - float legmodel_size; //!< 足描画サイズ | |
| 138 | + int point_dataid; //!< ポイントのデータ番号 | |
| 139 | + signed short int point_p4; //!< ポイントの認識番号 | |
| 140 | + int teamid; //!< チーム番号 | |
| 141 | + float move_x; //!< X軸速度 | |
| 142 | + float move_y; //!< Y軸(落下)速度 | |
| 143 | + float move_z; //!< Z軸速度 | |
| 144 | + bool move_y_flag; //!< Y軸移動フラグ | |
| 145 | + int move_y_upper; //!< Y軸上昇禁止カウンター | |
| 146 | + bool move_y_landing; //!< 着地フラグ | |
| 147 | + float rotation_y; //!< 全体の回転角度 | |
| 148 | + float armrotation_y; //!< 腕の回転角度 | |
| 149 | + float upmodel_size; //!< 上半身描画サイズ | |
| 150 | + float armmodel_size; //!< 腕描画サイズ | |
| 151 | + float legmodel_size; //!< 足描画サイズ | |
| 152 | 152 | class weapon *weapon[TOTAL_HAVEWEAPON]; //!< 武器 |
| 153 | 153 | int noweapon_bullets[TOTAL_HAVEWEAPON]; //!< 武器未所持時の合計弾数 |
| 154 | 154 | int noweapon_loadbullets[TOTAL_HAVEWEAPON]; //!< 武器未所持時の装弾数 |
| @@ -182,11 +182,11 @@ | ||
| 182 | 182 | bool CollisionBlockScratch(class Collision *CollD, class BlockDataInterface *inblockdata, float *px, float *py, float *pz, float px_old, float py_old, float pz_old, float in_vx, float in_vy, float in_vz, int mode); |
| 183 | 183 | |
| 184 | 184 | public: |
| 185 | - human(class ParameterInfo *in_Param = NULL, float x = 0.0f, float y = 0.0f, float z = 0.0f, float rx = 0.0f, int id_param = -1, int dataid = 0, signed char p4 = 0, int team = 0, bool flag = false); | |
| 185 | + human(class ParameterInfo *in_Param = NULL, float x = 0.0f, float y = 0.0f, float z = 0.0f, float rx = 0.0f, int id_param = -1, int dataid = 0, signed short int p4 = 0, int team = 0, bool flag = false); | |
| 186 | 186 | ~human(); |
| 187 | 187 | virtual void SetParameterInfoClass(class ParameterInfo *in_Param); |
| 188 | - virtual void SetParamData(int id_param, int dataid, signed char p4, int team, bool init); | |
| 189 | - virtual void GetParamData(int *id_param, int *dataid, signed char *p4, int *team); | |
| 188 | + virtual void SetParamData(int id_param, int dataid, signed short int p4, int team, bool init); | |
| 189 | + virtual void GetParamData(int *id_param, int *dataid, signed short int *p4, int *team); | |
| 190 | 190 | virtual void GetMovePos(float *x, float *y, float *z); |
| 191 | 191 | virtual void SetModel(int upmodel, int armmodel[], int legmodel, int walkmodel[], int runmodel[]); |
| 192 | 192 | virtual int GetHP(); |
| @@ -272,21 +272,21 @@ | ||
| 272 | 272 | { |
| 273 | 273 | protected: |
| 274 | 274 | class MIFInterface *MIFdata; //!< MIFを管理するクラスへのポインタ |
| 275 | - float rotation_y; //!< 回転角度 | |
| 276 | - signed char point_p4; //!< ポイントの認識番号 | |
| 277 | - int hp; //!< 体力 | |
| 278 | - float jump_rx; //!< 飛ばす横軸角度 | |
| 279 | - float move_rx; //!< 飛ばす横軸移動量 | |
| 280 | - float add_rx; //!< 飛ばす横軸回転量 | |
| 281 | - float add_ry; //!< 飛ばす縦軸回転量 | |
| 282 | - int jump_cnt; //!< 飛ばす上昇カウント | |
| 275 | + float rotation_y; //!< 回転角度 | |
| 276 | + signed short int point_p4; //!< ポイントの認識番号 | |
| 277 | + int hp; //!< 体力 | |
| 278 | + float jump_rx; //!< 飛ばす横軸角度 | |
| 279 | + float move_rx; //!< 飛ばす横軸移動量 | |
| 280 | + float add_rx; //!< 飛ばす横軸回転量 | |
| 281 | + float add_ry; //!< 飛ばす縦軸回転量 | |
| 282 | + int jump_cnt; //!< 飛ばす上昇カウント | |
| 283 | 283 | |
| 284 | 284 | public: |
| 285 | - smallobject(class ParameterInfo *in_Param = NULL, class MIFInterface *in_MIFdata = NULL, float x = 0.0f, float y = 0.0f, float z = 0.0f, float rx = 0.0f, int id_param = 0, signed char p4 = 0, bool flag = false); | |
| 285 | + smallobject(class ParameterInfo *in_Param = NULL, class MIFInterface *in_MIFdata = NULL, float x = 0.0f, float y = 0.0f, float z = 0.0f, float rx = 0.0f, int id_param = 0, signed short int p4 = 0, bool flag = false); | |
| 286 | 286 | ~smallobject(); |
| 287 | 287 | virtual void SetMIFInterfaceClass(class MIFInterface *in_MIFdata); |
| 288 | - virtual void SetParamData(int id_param, signed char p4, bool init); | |
| 289 | - virtual void GetParamData(int *id_param, signed char *p4); | |
| 288 | + virtual void SetParamData(int id_param, signed short int p4, bool init); | |
| 289 | + virtual void GetParamData(int *id_param, signed short int *p4); | |
| 290 | 290 | virtual int GetHP(); |
| 291 | 291 | virtual float CollisionMap(class Collision *CollD); |
| 292 | 292 | virtual void HitBullet(int attacks); |
| @@ -268,7 +268,7 @@ | ||
| 268 | 268 | //! @param RandomFlag ランダム補正を有効にする |
| 269 | 269 | //! @return 成功:データ番号(0以上) 失敗:-1 |
| 270 | 270 | //! @attention 無効な人の種類番号が指定された場合は 通称:謎人間 が登場します。テクスチャはマップテクスチャ0番が使用され、HPは 0 が指定(=即死)されます。 |
| 271 | -int ObjectManager::AddHumanIndex(float px, float py, float pz, float rx, int paramID, int TeamID, int WeaponID[], signed char param4, bool RandomFlag) | |
| 271 | +int ObjectManager::AddHumanIndex(float px, float py, float pz, float rx, int paramID, int TeamID, int WeaponID[], signed short int param4, bool RandomFlag) | |
| 272 | 272 | { |
| 273 | 273 | int GetHumanFlag; |
| 274 | 274 | HumanParameter HumanParam; |
| @@ -1751,9 +1751,9 @@ | ||
| 1751 | 1751 | //! @param p4 検索対象の認識番号 |
| 1752 | 1752 | //! @return 該当したhumanクラスのポインタ (見つからない場合はNULL) |
| 1753 | 1753 | //! @attention 複数該当する場合、最初に該当したデータを返します。 |
| 1754 | -human* ObjectManager::SearchHuman(signed char p4) | |
| 1754 | +human* ObjectManager::SearchHuman(signed short int p4) | |
| 1755 | 1755 | { |
| 1756 | - signed char humanp4; | |
| 1756 | + signed short int humanp4; | |
| 1757 | 1757 | |
| 1758 | 1758 | for(int i=0; i<MAX_HUMAN; i++){ |
| 1759 | 1759 | //使われていない人ならば処理しない |
| @@ -1774,9 +1774,9 @@ | ||
| 1774 | 1774 | //! @param p4 検索対象の認識番号 |
| 1775 | 1775 | //! @return 該当したsmallobjectクラスのポインタ (見つからない場合はNULL) |
| 1776 | 1776 | //! @attention 複数該当する場合、最初に該当したデータを返します。 |
| 1777 | -smallobject* ObjectManager::SearchSmallobject(signed char p4) | |
| 1777 | +smallobject* ObjectManager::SearchSmallobject(signed short int p4) | |
| 1778 | 1778 | { |
| 1779 | - signed char smallobjectp4; | |
| 1779 | + signed short int smallobjectp4; | |
| 1780 | 1780 | |
| 1781 | 1781 | for(int i=0; i<MAX_SMALLOBJECT; i++){ |
| 1782 | 1782 | //使われていない人ならば処理しない |
| @@ -2486,7 +2486,7 @@ | ||
| 2486 | 2486 | if( HumanIndex[id].GetDeadFlag() == false ){ return false; } |
| 2487 | 2487 | |
| 2488 | 2488 | int id_param, dataid, team; |
| 2489 | - signed char p4; | |
| 2489 | + signed short int p4; | |
| 2490 | 2490 | HumanIndex[id].GetParamData(&id_param, &dataid, &p4, &team); |
| 2491 | 2491 | if( (id_param < 0)||( TOTAL_PARAMETERINFO_HUMAN <= id_param) ){ return false; } //謎人間なら処理しない |
| 2492 | 2492 | HumanIndex[id].SetParamData(id_param, dataid, p4, team, true); |
| @@ -133,7 +133,7 @@ | ||
| 133 | 133 | ObjectManager(); |
| 134 | 134 | ~ObjectManager(); |
| 135 | 135 | void SetClass(ParameterInfo *in_GameParamInfo, D3DGraphics *in_d3dg, ResourceManager *in_Resource, BlockDataInterface *in_BlockData, PointDataInterface *in_PointData, Collision *in_CollD, SoundManager *in_GameSound, MIFInterface *in_MIFdata); |
| 136 | - int AddHumanIndex(float px, float py, float pz, float rx, int CharacterID, int TeamID, int WeaponID[], signed char param4, bool RandomFlag); | |
| 136 | + int AddHumanIndex(float px, float py, float pz, float rx, int CharacterID, int TeamID, int WeaponID[], signed short int param4, bool RandomFlag); | |
| 137 | 137 | int AddVisualWeaponIndex(int WeaponID, bool loadbullet); |
| 138 | 138 | int AddSmallObjectIndex(float px, float py, float pz, float rx, int paramID, bool MapColl); |
| 139 | 139 | int AddEffect(float pos_x, float pos_y, float pos_z, float move_x, float move_y, float move_z, float addmove_y, float rotation, float addrotation, float size, float addsize, int texture, int brightness, int addbrightness, float alpha, float addalpha, int settype, int count); |
| @@ -154,8 +154,8 @@ | ||
| 154 | 154 | int GetBulletObjectID(bullet* object); |
| 155 | 155 | bullet* GetNewBulletObject(); |
| 156 | 156 | grenade* GetNewGrenadeObject(); |
| 157 | - human* SearchHuman(signed char p4); | |
| 158 | - smallobject* SearchSmallobject(signed char p4); | |
| 157 | + human* SearchHuman(signed short int p4); | |
| 158 | + smallobject* SearchSmallobject(signed short int p4); | |
| 159 | 159 | void GetTotalObjects(int *HumanCnt, int *WeaponCnt, int *SmallobjectCnt, int *BulletCnt, int *GrenadeCnt, int *EffectCnt); |
| 160 | 160 | void MoveForward(int human_id); |
| 161 | 161 | void MoveBack(int human_id); |