summaryrefslogtreecommitdiff
path: root/src/cat
diff options
context:
space:
mode:
authorBryan Hoyle <starfoxprime@gmail.com>2012-11-16 21:51:55 (GMT)
committer Bryan Hoyle <starfoxprime@gmail.com>2012-11-16 21:51:55 (GMT)
commit874cd400093c38e67fde4a1861603bce83135539 (patch)
treee9c8b31b7cc752133dd0e110c652ed9775e859d5 /src/cat
parente0aa92b017a8d5602ce8b43f6e240ab42a25fac4 (diff)
parentd8be547c734cfaa3d121412b11381b4787380762 (diff)
downloadpowder-874cd400093c38e67fde4a1861603bce83135539.zip
powder-874cd400093c38e67fde4a1861603bce83135539.tar.gz
Merge branch 'master' of github.com:FacialTurd/PowderToypp
Diffstat (limited to 'src/cat')
-rw-r--r--src/cat/LegacyLuaAPI.cpp2
-rw-r--r--src/cat/TPTScriptInterface.cpp2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/cat/LegacyLuaAPI.cpp b/src/cat/LegacyLuaAPI.cpp
index d6e6ce6..9a478e7 100644
--- a/src/cat/LegacyLuaAPI.cpp
+++ b/src/cat/LegacyLuaAPI.cpp
@@ -462,7 +462,7 @@ int luacon_elementwrite(lua_State* l){
free(key);
return luaL_error(l, "Name too long");
}
- if(luacon_ci->GetParticleType(tempstring) == -1)
+ if(luacon_ci->GetParticleType(tempstring) != -1)
{
free(tempstring);
free(key);
diff --git a/src/cat/TPTScriptInterface.cpp b/src/cat/TPTScriptInterface.cpp
index 4782838..684467f 100644
--- a/src/cat/TPTScriptInterface.cpp
+++ b/src/cat/TPTScriptInterface.cpp
@@ -219,7 +219,7 @@ AnyType TPTScriptInterface::tptS_set(std::deque<std::string> * words)
newValue = GetParticleType(((StringType)value).Value());
if (newValue < 0 || newValue >= PT_NUM)
{
- if (((StringType)value).Value() == "GOLD")
+ if (((StringType)value).Value() == "GOLD" || ((StringType)value).Value() == "gold")
throw GeneralException("No, GOLD will not be an element");
else
throw GeneralException("Invalid element");