LeeS
Imperator
Does anyone know if City:IsHasResourceLocal(ResourceID#) returns "true" only if the city has the resource local to it and the resource has been improved or does it return "true" merely if the resource is in the range of the city?
As in if I do this:
[edit] perhaps I should have posted this question in the SDK/LUA sub-forum? I am always confused on best forum-use practice when it comes to a specific lua-proramming question like this.
As in if I do this:
Code:
if City:IsHasResourceLocal(GameInfoTypes.RESOURCE_STONE) then
blah blah
blah blah
end
- Will the "blah blah" psuedo-code lines only run if Stone is local to the city and has been improved? Or will those lines be executed if Stone is within the work-radius of the city, regardless of whether the Stone plot has been improved?
- Are there other gotchas with this lua method in that it doesn't work quite as one would expect and I would also need to do checks within the "blah blah" lines for such things as is the city itself working the resource or is some other city (of same or other civ) working the plot where the Stone is located?
[edit] perhaps I should have posted this question in the SDK/LUA sub-forum? I am always confused on best forum-use practice when it comes to a specific lua-proramming question like this.