Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Need 0 power for th15 #199

Open
BraviNoname opened this issue Dec 26, 2024 · 11 comments
Open

Need 0 power for th15 #199

BraviNoname opened this issue Dec 26, 2024 · 11 comments

Comments

@BraviNoname
Copy link

There used to be the option to start a stage at 0 power in th15 in the very first version of thprac, but it has been removed when the newer version with the blue menus came. I'd like this feature to be back, especially knowing it is available in th12 in the current thprac version.

@Galagyy
Copy link
Contributor

Galagyy commented Dec 29, 2024

Hello, thank you for the idea, I'm unsure if anyone else would approve this suggestion so I've gone ahead and found what you need to change in order to make it run. Keep in mind this would require you to build the project yourself from source.

You'll have to first open the thprac_th15.cpp file and navigate to line number 328 where you should see slider options for Dear ImGui.

// Old
Gui::GuiSlider<int, ImGuiDataType_S32> mPower { TH_POWER, 100, 400 };

// New (changing minimum from 100 to 0.)
Gui::GuiSlider<int, ImGuiDataType_S32> mPower { TH_POWER, 0, 400 };

Over here the code previously set the minimum on the slider to be 100 (1.00 power) but decreasing it to 0 (0.00 power) should let you start a stage at 0 power.

I cannot guarantee this works 100% but this change should let it happen, if you have any issues, feel free to comment here and I'll try my best to respond.

@32th-System
Copy link
Member

If you have Visual Studio installed you could try it out

@BraviNoname
Copy link
Author

I installed Visual Studio, and idk how to edit the thprac exe.

@Galagyy
Copy link
Contributor

Galagyy commented Dec 31, 2024

Hello,

Once you install and open Visual Studio, you can hit the button in the first screenshot and enter the link to this repository (https://github.com/touhouworldcup/thprac) and clone it.

Following that, you can open the project and open the /thprac/src/thprac/thprac_th15.cpp file. You can head over to line 328 and change the line like in the comment afromentioned.

You'll need to ensure that you have Clang installed in Visual Studio and following that you can compile the patch using the button in the second screenshot, ensure that you're building with Release and not Debug.

Screenshot 1:
Screenshot 1

Screenshot 2:
Screenshot 2

@BraviNoname
Copy link
Author

BraviNoname commented Dec 31, 2024

Thank you for the help, it works!

Now I'd like for the thprac users who would like to cap PDH 0 power phase 3 to be able to do so without needing to either time down (the more extreme challenge) or start at 1 power (the toned down challenge).
And besides, to begin with, it is about a feature that has been removed that I'd like to bring back, for myself and eventually others.

If it is possible, I'd like to upload my edited file into the github.

Here is, for reference, a screenshot of the old thprac with 0 power feature.
th15_712

@Galagyy
Copy link
Contributor

Galagyy commented Dec 31, 2024

Hello,

Thanks for the response, glad to see it worked. Regarding the change for PDH, (iirc Junko's Final Spell "Pristine Danmaku Hell") there was probably a reason it was removed and not kept as a feature, removing a feature for no reason doesn't make sense. I'm not 100% sure of this though.

If I got your request right, you'd also like for LoLK to be practicable starting at 0 power, you can do this by applying the same fix outlined earlier.

I have a small feeling I misunderstood what you asked for, if I got something wrong feel free to comment back and I'll try my best to help.

@BraviNoname
Copy link
Author

I don't know what the reason why it was removed, but right now I'd like to add my 0 power to the actual thprac repo in case people would like to do a 0 power challenge on the chapter of their choice.

@Galagyy
Copy link
Contributor

Galagyy commented Dec 31, 2024

If you want to try to add your change to the main repository, you could try opening up a pull request from a forked repository with your change.

You'll have to ensure that your code works properly and has no bugs.

@32th-System
Copy link
Member

i dont think the average person knows how edit source code and recompile it even if you tell them exactly what to do. Also, Visual Studio is like a 10GB install

@32th-System
Copy link
Member

f95a1ba

@32th-System
Copy link
Member

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants