summaryrefslogtreecommitdiffstats
path: root/sigscript/ItemWrapper.cpp
diff options
context:
space:
mode:
authorBen Boeckel <MathStuf@gmail.com>2008-09-07 18:49:29 +0000
committerBen Boeckel <MathStuf@gmail.com>2008-09-07 18:49:29 +0000
commitf80268eb885e28c603cc88523cfce2751d1448e1 (patch)
treed3e0a8b482f7d2a4bd177ecc300aa407177a42de /sigscript/ItemWrapper.cpp
parent48f9e57b1638ba047ca2dcd6d3251ee90bf9ef69 (diff)
downloadsigen-f80268eb885e28c603cc88523cfce2751d1448e1.tar.gz
sigen-f80268eb885e28c603cc88523cfce2751d1448e1.tar.xz
sigen-f80268eb885e28c603cc88523cfce2751d1448e1.zip
[FIX] Added a static poll method to Fraction
[FIX] More Arena stuff fleshed out [FIX] Added priority scripts to Ability and Move [FIX] A SigmodWrapper pointer is now passed around the containments [FIX] Config now has templated methods for retrieving values git-svn-id: https://pokegen.svn.sourceforge.net/svnroot/pokegen/trunk@253 6ecfd1a5-f3ed-3746-8530-beee90d26b22
Diffstat (limited to 'sigscript/ItemWrapper.cpp')
-rw-r--r--sigscript/ItemWrapper.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/sigscript/ItemWrapper.cpp b/sigscript/ItemWrapper.cpp
index 1fb400db..71e36149 100644
--- a/sigscript/ItemWrapper.cpp
+++ b/sigscript/ItemWrapper.cpp
@@ -51,8 +51,8 @@ Sigscript::ItemTypeWrapper* Sigscript::ItemWrapper::type()
int Sigscript::ItemWrapper::price() const
{
- if (value("price").canConvert<int>())
- return value("price").toInt();
+ if (hasValueOfType<int>("price"))
+ return valueOfType<int>("price");
return m_item->price();
}