EVENT DISPLAYCROSSHAIR: Difference between revisions
Jump to navigation
Jump to search
mNo edit summary |
Doom64hunter (talk | contribs) m This actually has 3 return values |
||
(5 intermediate revisions by 4 users not shown) | |||
Line 1: | Line 1: | ||
EVENT_DISPLAYCROSSHAIR | {{EventTable|1=EVENT_DISPLAYCROSSHAIR|2=[[screenpeek]]|3=[[i|player->i]]|4=3 values}} | ||
'''EVENT_DISPLAYCROSSHAIR''' is a [[EDuke32 event list|Game Event]]. | |||
If | This [[event]] is called when the player crosshair is being displayed. If it is disabled, the event will not execute. | ||
Gamevar [[RETURN]] is set to the crosshair's [[picnum]]. Modifying this value will allow the game to handle positioning duties itself, etc. Setting RETURN to -1 disables hardcoded drawing of the crosshair completely. | |||
See also [[EVENT_DISPLAYPOINTER]]. | |||
== Return Values == | |||
It is possible to change the tile, as well as the position of the crosshair. | |||
:; userdef.return 0 ([[RETURN]]) | |||
:: Set to the crosshair picnum, default is 2523. Change this to alter the crosshair sprite displayed onscreen. | |||
:; userdef.return 1 | |||
:: Contains the x-position of the crosshair. The default is <code>((160<<16) - ([[look_ang]] << 15))</code>. | |||
:; userdef.return 2 | |||
:: Contains the y-position of the crosshair. The default is <code> 100<<16 </code>. | |||
[[Category:Events]] | [[Category:Events]] |
Latest revision as of 04:58, 4 February 2022
Event ID | player# | THISACTOR | RETURN | |
---|---|---|---|---|
EVENT_DISPLAYCROSSHAIR | screenpeek | player->i | 3 values |
EVENT_DISPLAYCROSSHAIR is a Game Event.
This event is called when the player crosshair is being displayed. If it is disabled, the event will not execute.
Gamevar RETURN is set to the crosshair's picnum. Modifying this value will allow the game to handle positioning duties itself, etc. Setting RETURN to -1 disables hardcoded drawing of the crosshair completely.
See also EVENT_DISPLAYPOINTER.
Return Values
It is possible to change the tile, as well as the position of the crosshair.
- userdef.return 0 (RETURN)
- Set to the crosshair picnum, default is 2523. Change this to alter the crosshair sprite displayed onscreen.
- userdef.return 1
- Contains the x-position of the crosshair. The default is
((160<<16) - (look_ang << 15))
.
- userdef.return 2
- Contains the y-position of the crosshair. The default is
100<<16
.