GetPlayerRecource (1, 6, >=10000)
GetPlayerResource (1, 6) >=10000
SetPlayerResource (6, -10000, 5, 10);
Check the Manuals and see the correct way to write the functions.
You can also browse through the scripts of other maps. To write scripts, you need to at least look at their basics ;)
Here is the basics:
number GetPlayerResource( nPlayerID, nResID )
Returns the current amount of resource nResID for player nPlayerID. Resource IDs are listed in /scripts/advmap-startup.lua and are as follows:
WOOD = 0
ORE = 1
MERCURY = 2
CRYSTAL = 3
SULFUR = 4
GEM = 5
GOLD = 6
void SetPlayerResource( nPlayerID, nResID, nCount )
Sets the current amount of resource nResID to nCount for player nPlayerID. Based on this function, a higher-level primitive is implemented in the /scripts/advmap-startup.lua file – void SetPlayerStartResource( nPlayerID, nResID, nCount ), which distributes starting resources to the player depending on the difficulty level.
Added 5 minutes ago
I AM COMPLETELY CONFUSED ABOUT WHAT TO DO???:confused: :confused: :confused: :smile33: :smile33: :smile33:
NHF 0.90 : NHF - группа в VK
Карты для HeroesV:
Путешествие , Условие крови , Рука судьбы.Часть 1: В поход , Рука судьбы.Часть 2: Отчаянье , Рука судьбы.Часть 3: Восхождение , Стойкость
Абсолютная власть , Иду на Вы! , Корона Ургаша , На задворках
Мир надо уничтожить... Чтобы создать свой...