-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #16 from Amethyst-szs/dev
Version 1.2 release, merging dev into stable
- Loading branch information
Showing
30 changed files
with
472 additions
and
116 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
FTP_IP ?= 192.168.0.9 # put console IP here | ||
FTP_IP ?= 192.168.0.24 # put console IP here | ||
.PHONY: all clean | ||
|
||
all: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,74 @@ | ||
#include "helpers/ImGuiHelper.h" | ||
|
||
void ImGuiHelper::drawVector3Drag(const char* prefixName, const char* tooltip, sead::Vector3f* vec, float speed, float limit) | ||
{ | ||
if(!vec) | ||
return; | ||
|
||
const char* symbols = "XYZ"; | ||
sead::FixedSafeString<0xf> sliderName(prefixName); | ||
|
||
ImGui::BeginGroup(); | ||
|
||
for(uint i = 0; i < strlen(symbols); i++) { | ||
sliderName.append(symbols[i]); | ||
ImGui::DragFloat(sliderName.cstr(), &vec->e[i], speed, -limit, limit, "%.2f", ImGuiSliderFlags_NoRoundToFormat); | ||
sliderName.chop(1); | ||
} | ||
|
||
ImGui::EndGroup(); | ||
|
||
if(ImGui::IsItemHovered()) | ||
ImGui::SetTooltip(tooltip); | ||
|
||
ImGui::Separator(); | ||
} | ||
|
||
void ImGuiHelper::drawVector3Slide(const char* prefixName, const char* tooltip, sead::Vector3f* vec, float limit, bool isNormalize) | ||
{ | ||
if(!vec) | ||
return; | ||
|
||
const char* symbols = "XYZ"; | ||
sead::FixedSafeString<0xf> sliderName(prefixName); | ||
|
||
ImGui::BeginGroup(); | ||
|
||
for(uint i = 0; i < strlen(symbols); i++) { | ||
sliderName.append(symbols[i]); | ||
ImGui::SliderFloat(sliderName.cstr(), &vec->e[i], -limit, limit, "%.2f", ImGuiSliderFlags_NoRoundToFormat); | ||
sliderName.chop(1); | ||
} | ||
|
||
if(isNormalize) | ||
vec->normalize(); | ||
|
||
ImGui::EndGroup(); | ||
|
||
if(ImGui::IsItemHovered()) | ||
ImGui::SetTooltip(tooltip); | ||
|
||
ImGui::Separator(); | ||
} | ||
|
||
void ImGuiHelper::drawQuat(const char* tooltip, sead::Quatf* quat) | ||
{ | ||
if(!quat) | ||
return; | ||
|
||
ImGui::BeginGroup(); | ||
|
||
ImGui::DragFloat("QW", &quat->w, 0.05f, 0.f, 0.f, "%.2f", ImGuiSliderFlags_NoRoundToFormat); | ||
ImGui::SliderFloat("QX", &quat->x, -1.f, 1.f, "%.3f", ImGuiSliderFlags_NoRoundToFormat); | ||
ImGui::SliderFloat("QY", &quat->y, -1.f, 1.f, "%.3f", ImGuiSliderFlags_NoRoundToFormat); | ||
ImGui::SliderFloat("QZ", &quat->z, -1.f, 1.f, "%.3f", ImGuiSliderFlags_NoRoundToFormat); | ||
|
||
// quat->normalize(); | ||
|
||
ImGui::EndGroup(); | ||
|
||
if(ImGui::IsItemHovered()) | ||
ImGui::SetTooltip(tooltip); | ||
|
||
ImGui::Separator(); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
#include "imgui.h" | ||
|
||
#include "sead/prim/seadSafeString.h" | ||
#include "sead/math/seadVector.h" | ||
#include "sead/math/seadQuat.h" | ||
|
||
namespace ImGuiHelper { | ||
|
||
// Vector editors | ||
void drawVector3Drag(const char* prefixName, const char* tooltip, sead::Vector3f* vec, float speed, float limit); | ||
void drawVector3Slide(const char* prefixName, const char* tooltip, sead::Vector3f* vec, float limit, bool isNormalize); | ||
|
||
// Quaternion editors | ||
void drawQuat(const char* tooltip, sead::Quatf* quat); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
#include "LoadLogger.hpp" | ||
#include "devgui/DevGuiManager.h" | ||
#include "lib.hpp" | ||
#include "nifm.h" | ||
#include "socket.h" | ||
#include "util.h" | ||
|
||
void LoadLog::pushTextToVector(const char* text) { | ||
sead::DateTime currentTime = sead::DateTime(0); | ||
sead::CalendarTime calendarTime; | ||
char temp[256]; | ||
|
||
currentTime.setNow(); | ||
currentTime.getCalendarTime(&calendarTime); | ||
|
||
if (mTextLines.size() > mMaxListSize) | ||
mTextLines.erase(mTextLines.begin()); | ||
snprintf(temp, sizeof(temp), "%02d:%02d:%02d | %s", calendarTime.getHour(), calendarTime.getMinute(), calendarTime.getSecond(), text); | ||
|
||
mTextLines.push_back(strdup(temp)); | ||
} |
Oops, something went wrong.