Zone::getHashOfMapAreaAtCoords: Difference between revisions

From RAGE Multiplayer Wiki
(yay)
 
(yay)
Line 1: Line 1:
Returns a hash representing which part of the map the given coords are located.<br><br>Possible return values:<br>(Hash of) city -&gt; -289320599<br>(Hash of) countryside -&gt; 207209373<br><br>C# Example :<br><br>Ped player = Game.Player.Character;<br>Hash h = Function.Call&lt;Hash&gt;(Hash.GET_HASH_OF_MAP_AREA_AT_COORDS, player.Position.X, player.Position.Y, player.Position.Z);
Returns a hash representing which part of the map the given coords are located.<br><br>Possible return values:<br>(Hash of) city -&gt; -289320599<br>(Hash of) countryside -&gt; 207209373<br><br>C# Example :<br><br>Ped player = Game.Player.Character;<br>Hash h = Function.Call&lt;Hash&gt;(Hash.GET_HASH_OF_MAP_AREA_AT_COORDS, player.Position.X, player.Position.Y, player.Position.Z);
==Syntax==
==Syntax==
<syntaxhighlight lang="javascript">zone.getHashOfMapAreaAtCoords(x, y, z);</syntaxhighlight>
<syntaxhighlight lang="javascript">mp.game.zone.getHashOfMapAreaAtCoords(x, y, z);</syntaxhighlight>
=== Required Arguments ===
=== Required Arguments ===
*'''x:''' float
*'''x:''' float
Line 10: Line 10:
==Example==
==Example==
<syntaxhighlight lang="javascript">
<syntaxhighlight lang="javascript">
todo
// todo
</syntaxhighlight>
</syntaxhighlight>
==See also==
==See also==
{{Zone_function_c}}
{{Zone_s_function_c}}
[[Category:Clientside API]]
[[Category:Clientside API]]
[[Category:TODO: Example]]
[[Category:TODO: Example]]

Revision as of 21:35, 6 May 2017

Returns a hash representing which part of the map the given coords are located.

Possible return values:
(Hash of) city -> -289320599
(Hash of) countryside -> 207209373

C# Example :

Ped player = Game.Player.Character;
Hash h = Function.Call<Hash>(Hash.GET_HASH_OF_MAP_AREA_AT_COORDS, player.Position.X, player.Position.Y, player.Position.Z);

Syntax

mp.game.zone.getHashOfMapAreaAtCoords(x, y, z);

Required Arguments

  • x: float
  • y: float
  • z: float

Return value

  • Model hash or name

Example

// todo

See also

Template:Zone s function c