Claim error message fix.
Used to say "Not enough power." for everything.
This commit is contained in:
parent
3bbf84896c
commit
a7c9d15282
@ -172,17 +172,17 @@ factions.register_command ("claim", {
|
|||||||
return true
|
return true
|
||||||
else
|
else
|
||||||
local parcel_faction = factions.get_parcel_faction(parcelpos)
|
local parcel_faction = factions.get_parcel_faction(parcelpos)
|
||||||
if faction.power <= factions_config.power_per_parcel then
|
if parcel_faction and parcel_faction.name == faction.name then
|
||||||
send_error(player, "Not enough power.")
|
send_error(player, "This parcel already belongs to your faction.")
|
||||||
return false
|
return false
|
||||||
elseif not parcel_faction then
|
elseif parcel_faction and parcel_faction.name ~= faction.name then
|
||||||
send_error(player, "Your faction cannot claim any (more) parcel(s).")
|
send_error(player, "This parcel belongs to another faction.")
|
||||||
return false
|
return false
|
||||||
elseif parcel_faction.name == faction.name then
|
elseif faction.power <= factions_config.power_per_parcel then
|
||||||
send_error(player, "This parcel already belongs to your faction.")
|
send_error(player, "Not enough power.")
|
||||||
return false
|
return false
|
||||||
else
|
else
|
||||||
send_error(player, "This parcel belongs to another faction.")
|
send_error(player, "Your faction cannot claim any (more) parcel(s).")
|
||||||
return false
|
return false
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
Loading…
Reference in New Issue
Block a user