Jass:Config – Mappedia

Jass:Config

Aus Mappedia
Wechseln zu: Navigation, Suche
Funktion: Config
Parameter: nothing
Rückgabewert: nothing
Autor: Blizzard
Quelle: Kartenskript
Synchron: Unbekannt

Diese Funktion wird mit dem Kartenskript erzeugt und initialisiert alle Kartendaten.

Code-Einschleusung

Da sie bereits im Kartenauswahlmenü aufgerufen wird, sobald ein Benutzer die Karte auswählt, kann per vJass durch eine Code-Einschleusung zum Beispiel Musik im Kartenauswahlmenü abgespielt werden:

//! inject config
	call SetMapName("Bla")
	call SetMapDescription("Beschreibung")
	call SetPlayers(7)
	call SetTeams(7)
	call SetGamePlacement(MAP_PLACEMENT_TEAMS_TOGETHER)

	call DefineStartLocation(0, - 22592.0, 18944.0)
	call DefineStartLocation(1, - 22592.0, 18944.0)
	call DefineStartLocation(2, - 22592.0, 18944.0)
	call DefineStartLocation(3, - 22592.0, 18944.0)
	call DefineStartLocation(4, - 22592.0, 18944.0)
	call DefineStartLocation(5, - 22592.0, 18944.0)
	call DefineStartLocation(6, - 22592.0, 18944.0)

	// Player setup
	call InitCustomPlayerSlots()
	call InitCustomTeams()
	call InitAllyPriorities()

	call PlayMusic("Music\\LoadingScreen.mp3")
//! endinject


Code

Der Inhalt hängt stets von der jeweiligen Karte ab:

function config takes nothing returns nothing
    call SetMapName( "TRIGSTR_001" )
    call SetMapDescription( "" )
    call SetPlayers( 7 )
    call SetTeams( 7 )
    call SetGamePlacement( MAP_PLACEMENT_TEAMS_TOGETHER )

    call DefineStartLocation( 0, -22592.0, 18944.0 )
    call DefineStartLocation( 1, -22592.0, 18944.0 )
    call DefineStartLocation( 2, -22592.0, 18944.0 )
    call DefineStartLocation( 3, -22592.0, 18944.0 )
    call DefineStartLocation( 4, -22592.0, 18944.0 )
    call DefineStartLocation( 5, -22592.0, 18944.0 )
    call DefineStartLocation( 6, -22592.0, 18944.0 )

    // Player setup
    call InitCustomPlayerSlots(  )
    call InitCustomTeams(  )
    call InitAllyPriorities(  )
endfunction
Meine Werkzeuge
Namensräume
Varianten
Aktionen
Navigation
Warcraft-Mapping
Werkzeuge