SerweryWłasny serwerDla twórcówForumFAQDokumentacjaBezpieczeństwo
Pobierz launcher
  1. Dokumentacja
  2. Funkcje serwera
  3. addResourceConfig

Funkcja

addResourceConfig

Dopisuje plik konfiguracyjny (<config src type>) do meta.xml zasobu – własnego albo utworzonego przez ten skrypt funkcją createResource. Ten sam plik dopisany drugi raz niczego nie zmienia.

Składnia

bool addResourceConfig(resource theResource, string filePath [, string fileType = "server"])

Argumenty

theResourceresource
Zasób.W MTA:SA inny typ: string filePath
filePathstring
Ścieżka pliku.W MTA:SA opcjonalny: string filetype = "server"
fileTypestring, opcjonalny = "server"
"server" albo "client".Nie ma go w MTA:SA

Różnice względem MTA:SA

  • Argumenty zaznaczone innym kolorem różnią się od MTA:SA.

W MTA:SA

addResourceConfig(string filePath, string filetype = "server")

Zwraca

true przy powodzeniu.

Przykład

addResourceConfig(getThisResource(), "ustawienia.xml", "server")

Zobacz też