Unknown_Hero Mage
Messages : 780 Quality Points : 78 Registration Date : 2015-09-06
| Subject: [Ironfist ver 1.3.0] Bug in lua scripts with IDs "CREATURE_PEASANT" or "0" 2018-10-07, 23:02 | |
| The creature IDs "CREATURE_PEASANT" or "0" do not work in scripts. This does not work: - Code:
-
hero = GetCurrentHero(); if HasTroop(hero, CREATURE_PEASANT, 1) == true then numberPeasant = GetCreatureAmount(hero, CREATURE_PEASANT); MessageBox("The hero has "..numberPeasant.." Peasants."); end; This does not work: - Code:
-
hero = GetCurrentHero(); if HasTroop(hero, 0, 1) == true then numberPeasant = GetCreatureAmount(hero, 0); MessageBox("The hero has "..numberPeasant.." Peasants."); end; This works: - Code:
-
hero = GetCurrentHero(); if HasTroop(hero, CREATURE_ARCHER, 1) == true then numberArcher = GetCreatureAmount(hero, CREATURE_ARCHER); MessageBox("The hero has "..numberArcher.." Archers."); end; This works: - Code:
-
hero = GetCurrentHero(); if HasTroop(hero, 1, 1) == true then numberArcher = GetCreatureAmount(hero, 1); MessageBox("The hero has "..numberArcher.." Archers."); end; Why so much hate towards peasants? | |
|
Darmani Master Modder
Messages : 289 Quality Points : 47 Registration Date : 2014-12-27
| Subject: Re: [Ironfist ver 1.3.0] Bug in lua scripts with IDs "CREATURE_PEASANT" or "0" 2018-10-12, 17:32 | |
| Good catch. Already spotted the bug; will be fixed shortly. | |
|
Unknown_Hero Mage
Messages : 780 Quality Points : 78 Registration Date : 2015-09-06
| Subject: Re: [Ironfist ver 1.3.0] Bug in lua scripts with IDs "CREATURE_PEASANT" or "0" 2018-10-13, 04:48 | |
| Thanks. | |
|
XT3RM1N8R Gargoyle
Messages : 23 Quality Points : 1 Registration Date : 2016-11-06 Age : 27 Location : USA
| Subject: Bug Fixed 2018-10-16, 16:56 | |
| Thanks for letting us know! This bug has been fixed! ________________________ Lazy Signature
| |
|
Unknown_Hero Mage
Messages : 780 Quality Points : 78 Registration Date : 2015-09-06
| Subject: Re: [Ironfist ver 1.3.0] Bug in lua scripts with IDs "CREATURE_PEASANT" or "0" 2018-10-16, 23:35 | |
| Thanks, it works well with the latest version of October 16, 2018. | |
|
Sponsored content
| Subject: Re: [Ironfist ver 1.3.0] Bug in lua scripts with IDs "CREATURE_PEASANT" or "0" | |
| |
|