diff options
author | eray orçunus <erayorcunus@gmail.com> | 2020-09-30 19:02:47 +0200 |
---|---|---|
committer | eray orçunus <erayorcunus@gmail.com> | 2020-09-30 19:03:01 +0200 |
commit | 595421da3908a2d3e7a1b063605bb3f2a3adb65b (patch) | |
tree | 1fe2f8eb9da450d5f8efdb27f1b9cbd8d541e01c /src/extras/frontendoption.h | |
parent | Fix more (diff) | |
download | re3-595421da3908a2d3e7a1b063605bb3f2a3adb65b.tar re3-595421da3908a2d3e7a1b063605bb3f2a3adb65b.tar.gz re3-595421da3908a2d3e7a1b063605bb3f2a3adb65b.tar.bz2 re3-595421da3908a2d3e7a1b063605bb3f2a3adb65b.tar.lz re3-595421da3908a2d3e7a1b063605bb3f2a3adb65b.tar.xz re3-595421da3908a2d3e7a1b063605bb3f2a3adb65b.tar.zst re3-595421da3908a2d3e7a1b063605bb3f2a3adb65b.zip |
Diffstat (limited to 'src/extras/frontendoption.h')
-rw-r--r-- | src/extras/frontendoption.h | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/extras/frontendoption.h b/src/extras/frontendoption.h index b2bfbf5e..f721abb0 100644 --- a/src/extras/frontendoption.h +++ b/src/extras/frontendoption.h @@ -10,7 +10,7 @@ // About texts: // All text parameters accept wchar(including hardcoded wchar* and TheText.Get) -// except FrontendScreenAdd(it's char[8] by the design of Frontend). +// except FrontendScreenAdd(it's char[8] GXT key by the design of Frontend). // All texts reload if custom options reloaded too, which includes language changes and via live reload feature in debug menu! // Execute direction: @@ -26,7 +26,7 @@ // // Static/select: You allocate the variable, pass it to function and game sets it from user input among the strings given to function, // then you can handle ChangeFunc(only called on enter if onlyApplyOnEnter set, or set immediately) -// and ReturnPrevPageFunc optionally. You can store the option in gta3.set if you pass true to corresponding parameter. +// and ReturnPrevPageFunc optionally. You can store the option in an INI file if you pass the key(as a char array) to corresponding parameter. // // Dynamic: Passing variable to function is only needed if you want to store it, otherwise you should do // all the operations with ButtonPressFunc, this includes allocating the variable. @@ -95,7 +95,7 @@ struct FrontendOption ReturnPrevPageFunc returnPrevPageFunc; int8* value; int8 displayedValue; // only if onlyApplyOnEnter enabled for now - bool save; + char* save; int32 ogOptionId; // for replacements, see overwrite parameter of SetCursor union { @@ -151,10 +151,10 @@ uint8 GetNumberOfMenuOptions(int screen); void FrontendOptionSetCursor(int screen, int8 option, bool overwrite = false); -// var is optional in AddDynamic, you can enable save parameter if you pass one, otherwise pass nil/0 +// var is optional in AddDynamic, enables you to save them in an INI file(also needs passing char array to saveName param. obv), otherwise pass nil/0 void FrontendOptionAddBuiltinAction(const wchar* leftText, int action, ButtonPressFunc buttonPressFunc, ReturnPrevPageFunc returnPrevPageFunc); -void FrontendOptionAddSelect(const wchar* leftText, const wchar** rightTexts, int8 numRightTexts, int8 *var, bool onlyApplyOnEnter, ChangeFunc changeFunc, ReturnPrevPageFunc returnPrevPageFunc, bool save = false); -void FrontendOptionAddDynamic(const wchar* leftText, DrawFunc rightTextDrawFunc, int8 *var, ButtonPressFunc buttonPressFunc, ReturnPrevPageFunc returnPrevPageFunc, bool save = false); +void FrontendOptionAddSelect(const wchar* leftText, const wchar** rightTexts, int8 numRightTexts, int8 *var, bool onlyApplyOnEnter, ChangeFunc changeFunc, ReturnPrevPageFunc returnPrevPageFunc, char* saveName = nil); +void FrontendOptionAddDynamic(const wchar* leftText, DrawFunc rightTextDrawFunc, int8 *var, ButtonPressFunc buttonPressFunc, ReturnPrevPageFunc returnPrevPageFunc, char* saveName = nil); void FrontendOptionAddRedirect(const wchar* text, int to, int8 selectedOption = 0, bool fadeIn = true); void FrontendOptionAddBackButton(const wchar* text, bool fadeIn = true); |