WoW:API SetMapZoom: Difference between revisions

From AddOn Studio
Jump to navigation Jump to search
No edit summary
({{wowapi}}, formatting, cosmic map.)
Line 1: Line 1:
<center>'''SetMapZoom''' ''-Documentation by [[user:Meog|Meog]]-''</center>
{{wowapi}} __NOTOC__
 
Sets what is displayed by the current world map to a specific continent and zone.
Sets what is displayed by the current world map to a specific continent and zone.
  SetMapZoom(continentIndex [,zoneIndex])
  SetMapZoom(continentIndex [,zoneIndex])


----
==Parameters==
;''Arguments''
===Arguments===
 
:;continentIndex : Number - Specifies the continent corresponding to the numbers of [[API_GetMapContinents|GetMapContinents()]], in addition to 0 for Azeroth and -1 for the Cosmic map.
:(continentIndex [,zoneIndex])
:;continentIndex : Number - Specifies the continent corresponding to the numbers of [[API_GetMapContinents|GetMapContinents()]], or 0 for whole world.
:;zoneIndex : Number - Specifies the zone corresponding to the numbers of [[API_GetMapZones|GetMapZones(continentIndex)]], omit for whole continent.
:;zoneIndex : Number - Specifies the zone corresponding to the numbers of [[API_GetMapZones|GetMapZones(continentIndex)]], omit for whole continent.


----
==Example==
;''Example''
  SetMapZoom(2, 10); -- 1.
  SetMapZoom(2, 10); -- 1.
SetMapZoom(2, nil); -- 2.
  SetMapZoom(2); -- 2.
  SetMapZoom(2); -- 2.
  SetMapZoom(0); -- 3.
  SetMapZoom(0); -- 3.
 
SetMapZoom(-1); -- 4.
;''Result''
WorldMapFrame:Show();
1. Set the current map zoom of the world map to Elvynn Forrest.
===Results===
2. Shows the Eastern Kingdoms
# Set the current map zoom of the world map to Elvynn Forrest.
3. Shows both continents
# Shows the Eastern Kingdoms
 
# Shows both continents
 
# Shows the cosmic map.
----
{{WoW API}}

Revision as of 17:16, 23 December 2006

WoW API < SetMapZoom

Sets what is displayed by the current world map to a specific continent and zone.

SetMapZoom(continentIndex [,zoneIndex])

Parameters

Arguments

continentIndex
Number - Specifies the continent corresponding to the numbers of GetMapContinents(), in addition to 0 for Azeroth and -1 for the Cosmic map.
zoneIndex
Number - Specifies the zone corresponding to the numbers of GetMapZones(continentIndex), omit for whole continent.

Example

SetMapZoom(2, 10); -- 1.
SetMapZoom(2); -- 2.
SetMapZoom(0); -- 3.
SetMapZoom(-1); -- 4.
WorldMapFrame:Show();

Results

  1. Set the current map zoom of the world map to Elvynn Forrest.
  2. Shows the Eastern Kingdoms
  3. Shows both continents
  4. Shows the cosmic map.