Difference between revisions of "Radar"

From Vendetta Lua
Jump to: navigation, search
(Added new functions and updated display to use Template:Function)
(Removed the template (causing timeouts) and reordered the list)
 
Line 3: Line 3:
 
== Functions ==
 
== Functions ==
  
{{Function
+
=== GetNearestObjectDistance ===
| name        = GetNearestObjectDistance
+
'''Definition:'''<br>
| desc        = Get distance to the nearest "large" object.  
+
GetNearestObjectDistance() -> nil
| ret1_name    =
+
<br><br>
| ret1_type    = number
+
'''Description:''' <br>
| ret1_desc    =
+
Get distance to the nearest "large" object.
| notes        =
+
<br><br>
}}
+
'''Arguments:'''
 +
?
 +
<br><br>
 +
'''Returns:'''
 +
?
 +
<br><br>
 +
'''Example:'''
 +
<br><br>
  
{{Function
+
=== GetRadarSelectionID ===
| name        = GetRadarSelectionID
+
'''Definition:'''<br>
| desc        = Get [[nodeid]] and [[objectid]] of targeted object
+
GetRadarSelectionID() -> int nodeid objectid
| ret1_name    = nodeid
+
<br><br>
| ret1_type    = number
+
'''Description:''' <br>
| ret1_desc    = [[nodeid]] of targeted object
+
Get [[nodeid]] and [[objectid]] of targeted object
| ret2_name    = objectid
+
<br><br>
| ret2_type    = number
+
'''Arguments:'''<br>
| ret2_desc    = [[objectid]] of targeted object
+
<br><br>
| notes        =
+
'''Returns:'''<br>
}}
+
'''nodeid''' [[nodeid]] of targeted object<br>
 +
'''objectid''' [[objectid]] of targeted object
 +
<br><br>
 +
'''Example:'''
 +
<br><br>
  
{{Function
+
=== HideRadar ===
| name        = Hide3000mNavpoint
+
'''Definition:'''<br>
| desc        =  
+
HideRadar() -> nil
| arg1_name    = ?
+
<br><br>
| arg1_type    =  
+
'''Description:''' <br>
| arg1_desc    =  
+
Hide the radar.
| arg1_opt    =  
+
<br><br>
| ret1_name    = ?
+
'''Arguments:'''
| ret1_type    =
+
?
| ret1_desc    =
+
<br><br>
| notes        =
+
'''Returns:'''
}}
+
?
 +
<br><br>
 +
'''Example:'''
 +
<br><br>
  
{{Function
+
=== Hide3000mNavpoint ===
| name        = HideRadar
+
'''Definition:'''<br>
| desc        = Hide the radar.
+
Hide3000mNavpoint() -> ?
| ret1_name    =  
+
<br><br>
| ret1_type    = nil
+
'''Description:'''<br>
| ret1_desc    =  
+
<br>
| notes        =  
+
'''Arguments:'''
}}
+
?
 +
<br><br>
 +
'''Returns:'''
 +
?
 +
<br><br>
 +
'''Example:'''
 +
<br><br>
  
{{Function
+
=== IsObjectOccluded ===
| name        = IsObjectOccluded
+
'''Definition:'''<br>
| desc        =  
+
IsObjectOccluded() -> ?
| arg1_name    = ?
+
<br><br>
| arg1_type    =
+
'''Description:'''<br>
| arg1_desc    =
+
<br>
| arg1_opt    =
+
'''Arguments:'''
| ret1_name    = ?
+
?
| ret1_type    =
+
<br><br>
| ret1_desc    =
+
'''Returns:'''
| notes        =
+
?
}}
+
<br><br>
 +
'''Example:'''
 +
<br><br>
  
{{Function
+
=== SetAimDirIcon ===
| name        = SetAimDirIcon
+
'''Definition:'''<br>
| desc        = (Presumably) set the icon for hud_new_aimdir.png (mouselook reticle).  
+
SetAimDirIcon() -> nil
| arg1_name    = ?
+
<br><br>
| arg1_type    =
+
'''Description:''' <br>
| arg1_desc    =
+
(Presumably) set the icon for hud_new_aimdir.png (mouselook reticle).  
| arg1_opt    =
+
<br><br>
| ret1_name    = ?
+
'''Arguments:'''
| ret1_type    =
+
?
| ret1_desc    =
+
<br><br>
| notes        =
+
'''Returns:'''
}}
+
?
 +
<br><br>
 +
'''Example:'''
 +
<br><br>
  
{{Function
+
=== SetAimDirIconColor ===
| name        = SetAimDirIconColor
+
'''Definition:'''<br>
| desc        = Change the color of the mouselook reticle?
+
SetAimDirIconColor() -> nil
| arg1_name    = ?
+
<br><br>
| arg1_type    =
+
'''Description:''' <br>
| arg1_desc    =
+
Change the color of the mouselook reticle?
| arg1_opt    =
+
<br><br>
| ret1_name    = ?
+
'''Arguments:'''
| ret1_type    =
+
?
| ret1_desc    =
+
<br><br>
| notes        =
+
'''Returns:'''
}}
+
?
 +
<br><br>
 +
'''Example:'''
 +
<br><br>
  
{{Function
+
=== SetAimDirIconSize ===
| name        = SetAimDirIconSize
+
'''Definition:'''<br>
| desc        = (Presumably) change size of the mouselook reticle.
+
SetAimDirIconSize() -> nil
| arg1_name    = ?
+
<br><br>
| arg1_type    =
+
'''Description:''' <br>
| arg1_desc    =
+
(Presumably) change size of the mouselook reticle.
| arg1_opt    =
+
<br><br>
| ret1_name    = ?
+
'''Arguments:'''
| ret1_type    =
+
?
| ret1_desc    =
+
<br><br>
| notes        =
+
'''Returns:'''
}}
+
?
 +
<br><br>
 +
'''Example:'''
 +
<br><br>
  
{{Function
+
=== SetDestArrows ===
| name        = SetDestArrows
+
'''Definition:'''<br>
| desc        = (Presumably) change some aspect of the nav destination arrows on the HUD.
+
SetDestArrows() -> nil
| arg1_name    = ?
+
<br><br>
| arg1_type    =
+
'''Description:''' <br>
| arg1_desc    =
+
(Presumably) change some aspect of the nav destination arrows on the HUD.
| arg1_opt    =
+
<br><br>
| ret1_name    = ?
+
'''Arguments:'''
| ret1_type    =
+
?
| ret1_desc    =
+
<br><br>
| notes        =
+
'''Returns:'''
}}
+
?
 +
<br><br>
 +
'''Example:'''
 +
<br><br>
  
{{Function
+
=== SetHUDIcon ===
| name        = SetHUDIcon
+
'''Definition:'''<br>
| desc        =  
+
SetHUDIcon() -> ?
| arg1_name    = ?
+
<br><br>
| arg1_type    =
+
'''Description:'''<br>
| arg1_desc    =
+
<br>
| arg1_opt    =
+
'''Arguments:'''
| ret1_name    = ?
+
?
| ret1_type    =
+
<br><br>
| ret1_desc    =
+
'''Returns:'''
| notes        =
+
?
}}
+
<br><br>
 +
'''Example:'''
 +
<br><br>
  
{{Function
+
=== SetNavDestinationArrowIconSize ===
| name        = SetNavDestinationArrowIconSize
+
'''Definition:'''<br>
| desc        =  
+
SetNavDestinationArrowIconSize() -> nil
| arg1_name    = ?
+
<br><br>
| arg1_type    =  
+
'''Description:''' <br>
| arg1_desc    =
+
Set the size of the arrows on the wormhole indicator on the HUD.
| arg1_opt    =
+
<br><br>
| ret1_name    = ?
+
'''Arguments:'''
| ret1_type    =
+
?
| ret1_desc    =
+
<br><br>
| notes        =
+
'''Returns:'''
}}
+
?
 +
<br><br>
 +
'''Example:'''
 +
<br><br>
  
{{Function
+
=== SetNavpointFontHeight ===
| name        = SetNavpointFontHeight
+
'''Definition:'''<br>
| desc        = (Presumably) change the size of the green + on the radar in ion storms.
+
SetNavpointFontHeight() -> nil
| arg1_name    = ?
+
<br><br>
| arg1_type    =
+
'''Description:''' <br>
| arg1_desc    =
+
(Presumably) change the size of the green + on the radar in ion storms.
| arg1_opt    =
+
<br><br>
| ret1_name    = ?
+
'''Arguments:'''
| ret1_type    =
+
?
| ret1_desc    =
+
<br><br>
| notes        =
+
'''Returns:'''
}}
+
?
 +
<br><br>
 +
'''Example:'''
 +
<br><br>
  
{{Function
+
=== SetRadarSelection ===
| name        = SetRadarSelection
+
'''Definition:'''<br>
| desc        = Change targets.
+
SetRadarSelection(int [[nodeid]], int [[objectid]]) -> nil
| arg1_name    = nodeid
+
<br><br>
| arg1_type    = number
+
'''Description:''' <br>
| arg1_desc    = [[nodeid]] of the object you want to target (2 for most things except ships)
+
Change targets.
| arg1_opt    =
+
<br><br>
| arg2_name    = objectid
+
'''Arguments:'''<br>
| arg2_type    = number
+
'''nodeid''' [[nodeid]] of the object you want to target (2 for most things except ships).<br>
| arg2_desc    = [[objectid]] of the object you want to target.
+
'''objectid''' [[objectid]] of the object you want to target.
| arg2_opt    =
+
<br><br>
| ret1_name    =
+
'''Returns:'''
| ret1_type    = nil
+
<br><br>
| ret1_desc    =
+
'''Example:'''
| notes        =
+
<br><br>
}}
+
  
{{Function
+
=== SetRadarSelectionByPoint ===
| name        = SetRadarSelectionByPoint
+
'''Definition:'''<br>
| desc        =  
+
SetRadarSelectionByPoint(float percentW, float percentH, string targetcommand) -> nil
| arg1_name    = ?
+
<br><br>
| arg1_type    =  
+
'''Description:''' <br>
| arg1_desc    =
+
Change targets based on a given point on the screen and a specified targeting command.
| arg1_opt    =
+
<br><br>
| ret1_name    = ?
+
'''Arguments:'''<br>
| ret1_type    =
+
'''percentW''' a float ranging from 0 to 1 indicating what percentage of the screen width the point is located at<br>
| ret1_desc    =
+
'''percentH''' a float ranging from 0 to 1 indicating what percentage of the screen height the point is located at<br>
| notes        =  
+
'''targetcommand''' VO targeting command (eg RadarNextFront)
}}
+
<br><br>
 +
'''Returns:'''
 +
<br><br>
 +
'''Example:'''
 +
<source lang="lua">radar.SetRadarSelectionByPoint(0.3837, 0.9927, "RadarNextFront")</source>
 +
<br><br>
  
{{Function
+
=== SetSelColor ===
| name        = SetSelColor
+
'''Definition:'''<br>
| desc        = Set targetbox color of the currently selected object.
+
SetSelColor(int r, g, b) -> nil
| arg1_name    = r
+
<br><br>
| arg1_type    = number
+
'''Description:''' <br>
| arg1_desc    = red component of color (0-255). nil is interpreted as 0
+
Set targetbox color of the currently selected object.
| arg1_opt    =
+
<br><br>
| arg2_name    = g
+
'''Arguments:'''<br>
| arg2_type    = number
+
'''r''' red component of color (0-255). nil is interpreted as 0<br>
| arg2_desc    = green component
+
'''g''' green component<br>
| arg2_opt    =
+
'''b''' blue component
| arg3_name    = b
+
<br><br>
| arg3_type    = number
+
'''Returns:'''
| arg3_desc    = blue component
+
<br><br>
| arg3_opt    =
+
'''Example:'''
| ret1_name    =
+
<source lang="lua">radar.SetSelColor(255, 0, 0) -- turns the target box red</source>
| ret1_type    = nil
+
<br><br>
| ret1_desc    =
+
| notes        = <source lang="lua">radar.SetSelColor(255, 0, 0) -- turns the target box red</source>
+
}}
+
  
{{Function
+
=== SetViewPort ===
| name        = SetViewport
+
'''Definition:'''<br>
| desc        =  
+
SetViewPort() -> ?
| arg1_name    = ?
+
<br><br>
| arg1_type    =
+
'''Description:'''<br>
| arg1_desc    =
+
<br>
| arg1_opt    =
+
'''Arguments:'''
| ret1_name    = ?
+
?
| ret1_type    =
+
<br><br>
| ret1_desc    =
+
'''Returns:'''
| notes        =
+
?
}}
+
<br><br>
 +
'''Example:'''
 +
<br><br>
  
{{Function
+
=== SetWormholeIconSize ===
| name        = SetWormholeIconSize
+
'''Definition:'''<br>
| desc        = (Presumably) change the size of the wormhole icon on the radar.
+
SetWormholeIconSize() -> nil
| arg1_name    = ?
+
<br><br>
| arg1_type    =
+
'''Description:''' <br>
| arg1_desc    =
+
(Presumably) change the size of the wormhole icon on the radar.
| arg1_opt    =
+
<br><br>
| ret1_name    = ?
+
'''Arguments:'''
| ret1_type    =
+
?
| ret1_desc    =
+
<br><br>
| notes        =
+
'''Returns:'''
}}
+
?
 
+
<br><br>
{{Function
+
'''Example:'''
| name        = Show3000mNavpoint
+
<br><br>
| desc        =
+
| arg1_name    = ?
+
| arg1_type    =
+
| arg1_desc    =
+
| arg1_opt    =
+
| ret1_name    = ?
+
| ret1_type    =
+
| ret1_desc    =
+
| notes        =
+
}}
+
 
+
{{Function
+
| name        = ShowRadar
+
| desc        = Show the radar.
+
| ret1_name    =
+
| ret1_type    = nil
+
| ret1_desc    =
+
| notes        =
+
}}
+
  
 +
=== Show3000mNavpoint ===
 +
'''Definition:'''<br>
 +
Show3000mNavpoint() -> ?
 +
<br><br>
 +
'''Description:'''<br>
 +
<br>
 +
'''Arguments:'''
 +
?
 +
<br><br>
 +
'''Returns:'''
 +
?
 +
<br><br>
 +
'''Example:'''
 +
<br><br>
  
 +
=== ShowRadar ===
 +
'''Definition:'''<br>
 +
ShowRadar() -> nil
 +
<br><br>
 +
'''Description:''' <br>
 +
Show the radar.
 +
<br><br>
 +
'''Arguments:'''
 +
?
 +
<br><br>
 +
'''Returns:'''
 +
?
 +
<br><br>
 +
'''Example:'''
 +
<br><br>
  
 
[[Category:Tables]]
 
[[Category:Tables]]

Latest revision as of 15:36, 22 September 2014

Functions for miscellaneous radar stuffs.

Functions

GetNearestObjectDistance

Definition:
GetNearestObjectDistance() -> nil

Description:
Get distance to the nearest "large" object.

Arguments: ?

Returns: ?

Example:

GetRadarSelectionID

Definition:
GetRadarSelectionID() -> int nodeid objectid

Description:
Get nodeid and objectid of targeted object

Arguments:


Returns:
nodeid nodeid of targeted object
objectid objectid of targeted object

Example:

HideRadar

Definition:
HideRadar() -> nil

Description:
Hide the radar.

Arguments: ?

Returns: ?

Example:

Hide3000mNavpoint

Definition:
Hide3000mNavpoint() -> ?

Description:

Arguments: ?

Returns: ?

Example:

IsObjectOccluded

Definition:
IsObjectOccluded() -> ?

Description:

Arguments: ?

Returns: ?

Example:

SetAimDirIcon

Definition:
SetAimDirIcon() -> nil

Description:
(Presumably) set the icon for hud_new_aimdir.png (mouselook reticle).

Arguments: ?

Returns: ?

Example:

SetAimDirIconColor

Definition:
SetAimDirIconColor() -> nil

Description:
Change the color of the mouselook reticle?

Arguments: ?

Returns: ?

Example:

SetAimDirIconSize

Definition:
SetAimDirIconSize() -> nil

Description:
(Presumably) change size of the mouselook reticle.

Arguments: ?

Returns: ?

Example:

SetDestArrows

Definition:
SetDestArrows() -> nil

Description:
(Presumably) change some aspect of the nav destination arrows on the HUD.

Arguments: ?

Returns: ?

Example:

SetHUDIcon

Definition:
SetHUDIcon() -> ?

Description:

Arguments: ?

Returns: ?

Example:

SetNavDestinationArrowIconSize

Definition:
SetNavDestinationArrowIconSize() -> nil

Description:
Set the size of the arrows on the wormhole indicator on the HUD.

Arguments: ?

Returns: ?

Example:

SetNavpointFontHeight

Definition:
SetNavpointFontHeight() -> nil

Description:
(Presumably) change the size of the green + on the radar in ion storms.

Arguments: ?

Returns: ?

Example:

SetRadarSelection

Definition:
SetRadarSelection(int nodeid, int objectid) -> nil

Description:
Change targets.

Arguments:
nodeid nodeid of the object you want to target (2 for most things except ships).
objectid objectid of the object you want to target.

Returns:

Example:

SetRadarSelectionByPoint

Definition:
SetRadarSelectionByPoint(float percentW, float percentH, string targetcommand) -> nil

Description:
Change targets based on a given point on the screen and a specified targeting command.

Arguments:
percentW a float ranging from 0 to 1 indicating what percentage of the screen width the point is located at
percentH a float ranging from 0 to 1 indicating what percentage of the screen height the point is located at
targetcommand VO targeting command (eg RadarNextFront)

Returns:

Example:

radar.SetRadarSelectionByPoint(0.3837, 0.9927, "RadarNextFront")



SetSelColor

Definition:
SetSelColor(int r, g, b) -> nil

Description:
Set targetbox color of the currently selected object.

Arguments:
r red component of color (0-255). nil is interpreted as 0
g green component
b blue component

Returns:

Example:

radar.SetSelColor(255, 0, 0) -- turns the target box red



SetViewPort

Definition:
SetViewPort() -> ?

Description:

Arguments: ?

Returns: ?

Example:

SetWormholeIconSize

Definition:
SetWormholeIconSize() -> nil

Description:
(Presumably) change the size of the wormhole icon on the radar.

Arguments: ?

Returns: ?

Example:

Show3000mNavpoint

Definition:
Show3000mNavpoint() -> ?

Description:

Arguments: ?

Returns: ?

Example:

ShowRadar

Definition:
ShowRadar() -> nil

Description:
Show the radar.

Arguments: ?

Returns: ?

Example: