SetPlayerWeaponZoomFactor: Difference between revisions

(Document new ACS function)
Tag: Source edit
 
m (Fixed a minor typo.)
Tag: Source edit
 
(One intermediate revision by one other user not shown)
Line 1: Line 1:
{{ACSWarning}}
{{ACSWarning}}
{{DevfeatureWarning|version=3.2|type=an [[ACS]] function}}
{{DevfeatureWarning|version=3.2|type=an [[ACS]] function}}
int '''SetPlayerWeaponZoomFactor''' (int ''player'', float ''zoom'' [, int ''flags''])
int '''SetPlayerWeaponZoomFactor''' (int ''player'', float ''zoom''[, int ''flags''])


== Usage ==  
== Usage ==  
Line 8: Line 8:
=== Parameters ===
=== Parameters ===
* ''player'': Player to change the zoom factor of.
* ''player'': Player to change the zoom factor of.
* ''zoom'': The amount to zoom in or out. The player's FOV is divided by this value.=
* ''zoom'': The amount to zoom in or out. The player's FOV is divided by this value.
* ''flags'': Flags to modify the behavior of the zoom. Uses the same values as A_ZoomFactor.
* ''flags'': Flags to modify the behavior of the zoom. Uses the same values as A_ZoomFactor.



Latest revision as of 03:21, 16 March 2024

This article documents a Zandronum-specific ACS feature which may not be supported by ZDoom and its other child ports.
This article documents an ACS function which is only available in development builds of Zandronum 3.2 and newer.

int SetPlayerWeaponZoomFactor (int player, float zoom[, int flags])

Usage

Scales the player's weapon's FOV, similar to the   A_ZoomFactor DECORATE function.

Parameters

  • player: Player to change the zoom factor of.
  • zoom: The amount to zoom in or out. The player's FOV is divided by this value.
  • flags: Flags to modify the behavior of the zoom. Uses the same values as A_ZoomFactor.

Return value

Returns 1 on success, 0 on failure.

Examples

This article lists no examples, please add one.