luafunctionref
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| luafunctionref [2025/01/08 20:45] – [update_get_map_destroyed_vehicle] bredroll | luafunctionref [2025/05/05 07:05] (current) – [update] bredroll | ||
|---|---|---|---|
| Line 48: | Line 48: | ||
| Next is the update cycle, most of the heavy lifting goes on in here, these are where you can introspect the current vehicle, carrier details, weapons, map, nearby units, other players, missiles, etc. graphical/ | Next is the update cycle, most of the heavy lifting goes on in here, these are where you can introspect the current vehicle, carrier details, weapons, map, nearby units, other players, missiles, etc. graphical/ | ||
| + | |||
| + | === Refresh Rate === | ||
| + | |||
| + | I have recently discovered there is another factor that influences how often a script '' | ||
| + | |||
| ==== Functions ====== | ==== Functions ====== | ||
| Line 1371: | Line 1376: | ||
| Destroyed vehicles have several methods. | Destroyed vehicles have several methods. | ||
| - | * '' | + | * '' |
| - | * '' | + | * get a '' |
| - | * '' | + | * '' |
| + | * get the team ID of the destroyed vehicle | ||
| + | * '' | ||
| + | * get float in range 0-1 based on the age of destruction, | ||
| Usable in: | Usable in: | ||
| Line 1387: | Line 1395: | ||
| Native/C function | Native/C function | ||
| + | |||
| + | Get the number of destroyed vehicles visible on the game map. | ||
| Usable in: | Usable in: | ||
| Line 1400: | Line 1410: | ||
| Native/C function | Native/C function | ||
| + | |||
| + | Get an object representing a player or AI controlled unit in game, the unit may be docked or active. | ||
| + | |||
| + | The HUD can obtain 3D position (lat-lon-alt) information about a unit where the screen scripts can only obtain 2D (lat-lon). The HUD can also not see unit waypoints where as screens can fully get/set waypoint data. | ||
| + | |||
| + | vehicle objects have many methods, the most commonly used are: | ||
| + | |||
| + | * '' | ||
| + | * locking/ | ||
| + | * '' | ||
| + | * get the vehicle ID number. | ||
| + | * '' | ||
| + | * get the vehicle type (a value in the '' | ||
| + | * '' | ||
| + | * get the vehicle team number | ||
| + | * '' | ||
| + | * get the vehicle team number | ||
| + | * '' | ||
| + | * get the vehicle 2D position as a '' | ||
| + | * '' | ||
| + | * get the vehicle 3D position as a '' | ||
| + | |||
| Usable in: | Usable in: | ||
luafunctionref.1736369105.txt.gz · Last modified: 2025/01/08 20:45 by bredroll
