Skip to content

Commit

Permalink
Use a base class instead of an anonymous struct for CVec3
Browse files Browse the repository at this point in the history
  • Loading branch information
CelestialAmber committed Oct 3, 2024
1 parent 90080ef commit ee8d081
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 36 deletions.
11 changes: 5 additions & 6 deletions libs/monolib/include/monolib/Math.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -71,16 +71,15 @@ namespace ml{
bool isInside(const CPnt16& point) const;
};

struct CVec3 {
//Nesting the variables in a nameless
//makes mwcc use lwz/stw for struct copies,
//which is more efficient than lfs/stfd.
struct{
/* Using a base class to contain the float values makes mwcc use
lwz/stw for struct copies, which is more efficient than lfs/stfd. */
struct _CVec3 {
float x;
float y;
float z;
};
};

struct CVec3 : _CVec3 {
static CVec3 zero;
static CVec3 unitX;
static CVec3 unitY;
Expand Down
2 changes: 0 additions & 2 deletions src/kyoshin/appgame/CNandData.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -27,5 +27,3 @@ int CNandData::nandIconTextureSomething[] = {
};

CNandData CNandData::instance = CNandData();


42 changes: 14 additions & 28 deletions src/kyoshin/appgame/ErrMesData.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5,66 +5,52 @@

//"Please insert the "Xenoblade" disc."
static const wchar_t* noDiscErrorMessage = L"ゼノブレイドのディスクをセットしてください。";
/*
"The disc could not be read.
For more details, please read the Wii System Manual."
*/
/* "The disc could not be read.
For more details, please read the Wii System Manual." */
static const wchar_t* discUnreadableErrorMessage =
L"ディスクを読めませんでした。&"
L"詳しくはWii本体の取扱説明書をお読みください。";
//"Reading the disc..."
static const wchar_t* readingDiscErrorMessage = L"ディスクの読み込み中です。";
//"Communication with the Wii Remote was interrupted."
static const wchar_t* wiiRemoteDisconnectedErrorMessage = L"Wiiリモコンの通信が切れました。";
/*
"Please connect the Nunchuck to the Wii Remote.
/* "Please connect the Nunchuck to the Wii Remote.
To change the extension controller to the Classic Controller,
after resetting the game once, at the title screen, please change
the extension controller to the Classic Controller."
*/
the extension controller to the Classic Controller." */
static const wchar_t* nunchuckDisconnectedErrorMessage =
L"Wiiリモコンにヌンチャクを接続してください。&&"
L"拡張コントローラをクラシックコントローラへ&"
L"変更する場合は、一度ゲームをリセットした後、&"
L"タイトル画面で拡張コントローラを&"
L"クラシックコントローラに変更してください。";
/*
"Please connect the Classic Controller to the Wii Remote.
/* "Please connect the Classic Controller to the Wii Remote.
To change the extension controller to the Nunchuck,
after resetting the game once, at the title screen, please change
the extension controller to the nunchuck."
*/
the extension controller to the nunchuck." */
static const wchar_t* classicControllerDisconnectedErrorMessage =
L"Wiiリモコンにクラシックコントローラを接続してください。&&"
L"拡張コントローラをヌンチャクへ&"
L"変更する場合は、一度ゲームをリセットした後、&"
L"タイトル画面で拡張コントローラを&"
L"ヌンチャクに変更してください。";
/*
"There is no extension controller connected to the Wii Remote.
Please connect either the Nunchuck or Classic Controller."
*/
/* "There is no extension controller connected to the Wii Remote.
Please connect either the Nunchuck or Classic Controller." */
static const wchar_t* noExtensionErrorMessage =
L"Wiiリモコンに拡張コントローラが接続されていません。&"
L"ヌンチャクまたはクラシックコントローラを接続してください。";
/*
"The Wii Console's save memory has been damaged.
For more details, please read the Wii System Manual."
*/
/* "The Wii Console's save memory has been damaged.
For more details, please read the Wii System Manual." */
static const wchar_t* memoryDamagedErrorMessage =
L"Wii本体保存メモリが壊れました。&"
L"くわしくはWii本体の取扱説明書をお読みください。";
/*
"Could not read from/write to the Wii Console's save memory.
For more details, please read the Wii System Manual."
*/
/* "Could not read from/write to the Wii Console's save memory.
For more details, please read the Wii System Manual." */
static const wchar_t* memoryReadWriteFailErrorMessage =
L"Wii本体保存メモリの書き込み/読み出しができませんでした。&"
L"くわしくはWii本体の取扱説明書をお読みください。";
/*
"An error occured while reading from/writing to the Wii Console's save memory.
For more details, please read the Wii System Manual."
*/
/* "An error occured while reading from/writing to the Wii Console's save memory.
For more details, please read the Wii System Manual." */
static const wchar_t* errorDuringMemoryReadWriteErrorMessage =
L"Wii本体保存メモリの書き込み/読み出し中にエラーが発生しました。&"
L"くわしくはWii本体の取扱説明書をお読みください。";
Expand Down

0 comments on commit ee8d081

Please sign in to comment.