-
Notifications
You must be signed in to change notification settings - Fork 3
Scripting Extensions
Alexander edited this page Apr 17, 2018
·
8 revisions
Let's say, you are creating The Best Mission Ever Made, you've decided to use KSS (wise decision). As you know SQF-scripting language, you want to make some extensions for KSS in your mission, but still you don't know how to do that.
Here I'm going to share all useful information on that.
KSS uses two global variables to store delay between decreasing THIRST and HUNGER values.
| Variable name | Description | Default value |
|---|---|---|
KSS_delay_hunger |
Strores the delay in seconds between decreasing HUNGER | 36 |
KSS_delay_thirst |
Strores the delay in seconds between decreasing THIRST | 36 |
Also two variables are used to store information about current THIRST and HUNGER level.
| Variable name | Description | Default value |
|---|---|---|
KSS_hunger |
Stores current HUNGER level | 0 - 100 |
KSS_thirst |
Stores current THIRST level | 0 - 100 |
KSS_alcoholLevel |
Stores current ALCOHOL level | 0 - (infinity) |
Two variables allow you to stop HUNGER or THIRST progress.
| Variable name | Description | Default value |
|---|---|---|
KSS_progress_hunger |
If is set to false, stops decreasing of HUNGER, until you respawn or it's set back to true
|
true |
KSS_progress_thirst |
If is set to false, stops decreasing of THIRST, until you respawn or it's set back to true
|
true |
| Function name | Description | Example |
|---|---|---|
KSS_fnc_Eat |
Adds given number to HUNGER level. It can't be > 100 or < 0. |
[30] call KSS_fnc_Eat |
KSS_fnc_Drink |
Adds given number to THIRST level. It can't be > 100 or < 0
|
[55] call KSS_fnc_Drink |
KSS_fnc_drinkAlcohol |
Adds given number to ALCOHOL level with given duration | [3, 10] call KSS_fnc_drinkAlcohol |