Added upper/lower limits to the hit chance value

Edited hookscript docs.
This commit is contained in:
NovaRain
2023-07-09 15:22:56 +08:00
parent 321f8e1ab2
commit ddb3cf9b6e
6 changed files with 26 additions and 8 deletions
+2 -3
View File
@@ -97,7 +97,7 @@ procedure remove_array_set(variable array, variable item);
// Creates a new array filled from a given array by transforming each value using given procedure name.
procedure array_transform(variable arr, variable valueFunc);
// Create a new temp array filled from a given array by transforming each key and value using given procedure names.
// Create a new temp array filled from a given array by transforming each key and value using given procedure name.
procedure array_transform_kv(variable arr, variable keyFunc, variable valueFunc);
@@ -423,8 +423,7 @@ procedure array_transform(variable arr, variable valueFunc) begin
return retArr;
end
// Create a new temp array filled from a given array by transforming each key and value using given procedure names.
// Create a new temp array filled from a given array by transforming each key and value using given procedure name.
procedure array_transform_kv(variable arr, variable keyFunc, variable valueFunc) begin
variable k, v, retArr := temp_array_map;
foreach (k: v in arr) begin
+1 -1
View File
@@ -23,7 +23,7 @@
int arg6 - Ranged flag. 1 if the hit chance calculation takes into account the distance to the target. This does not mean the attack is a ranged attack
int arg7 - The raw hit chance before applying the cap
int ret0 - the new hit chance
int ret0 - The new hit chance. The value is limited to the range of -99 to 999
```
- name: AfterHitRoll
+1 -1
View File
@@ -108,7 +108,7 @@ int arg5 - Attack Type (see ATKTYPE_* constants)
int arg6 - Ranged flag. 1 if the hit chance calculation takes into account the distance to the target. This does not mean the attack is a ranged attack
int arg7 - The raw hit chance before applying the cap
int ret0 - the new hit chance
int ret0 - The new hit chance. The value is limited to the range of -99 to 999
```
-------------------------------------------