How to add a new option?
I have created some progress bar packs and I want to make a function of choice a pack in the "Options" screen. But I cannot add my own option (called "ProgressBarType") to the list in "preferences.lua".
A fragment from "stratagus.lua":
if (preferences == nil) then
preferences = {
...
ProgressBarType = 0,
}
end.
...
SetProgressBarT
Question information
- Language:
- English Edit question
- Status:
- Solved
- For:
- Wargus Edit question
- Assignee:
- Pali Edit question
- Solved by:
- Pali
- Solved:
- 2011-08-14
- Last query:
- 2011-08-14
- Last reply:
- 2011-08-12
|
#1 |
You need native C/C++ function SetProgressBarType in Stratagus and export it to Lua in Stratagus too. Or you can create Lua function and add it to some Wargus lua scripts.
Riug74 (riug-74) said : | #2 |
Thanks Pali, that solved my question.
Where can I find theses native C/C++ functions?
Pali (pali) said : | #4 |
SetProgressBarType does not exists.
All functions are in Stratagus source code (and exported in files src/stratagus/