diff options
Diffstat (limited to 'pokemod/MapEffect.cpp')
| -rw-r--r-- | pokemod/MapEffect.cpp | 37 |
1 files changed, 18 insertions, 19 deletions
diff --git a/pokemod/MapEffect.cpp b/pokemod/MapEffect.cpp index 92d8089e..bab36f48 100644 --- a/pokemod/MapEffect.cpp +++ b/pokemod/MapEffect.cpp @@ -6,19 +6,18 @@ // Created: Fri June 1 2007 20:23:15
// Copyright: ©2007 Nerdy Productions
// Licence:
-// This program is free software; you can redistribute it and/or modify
+// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation; either version 2 of the License, or
+// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
-//
+//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
-//
+//
// You should have received a copy of the GNU General Public License along
-// with this program; if not, write to the Free Software Foundation, Inc.,
-// 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+// with this program. If not, see <http://www.gnu.org/licenses/>.
/////////////////////////////////////////////////////////////////////////////
#include "MapEffect.h"
@@ -152,7 +151,7 @@ void PokeGen::PokeMod::MapEffect::ImportIni(Ini &ini, const unsigned _id) LogImportOver("MapEffect", id, name);
}
-void PokeGen::PokeMod::MapEffect::ExportIni(std::ofstream &fout, const String &map) const
+void PokeGen::PokeMod::MapEffect::ExportIni(QFile &fout, const QString &map) const
{
LogExportStart("MapEffect", id, name);
Ini exMapEffect(map + "mapEffect");
@@ -174,7 +173,7 @@ void PokeGen::PokeMod::MapEffect::ExportIni(std::ofstream &fout, const String &m LogExportOver("MapEffect", id, name);
}
-void PokeGen::PokeMod::MapEffect::SetName(const String &n)
+void PokeGen::PokeMod::MapEffect::SetName(const QString &n)
{
LogSetVar("MapEffect", id, "name", n);
name = n;
@@ -229,7 +228,7 @@ void PokeGen::PokeMod::MapEffect::SetExistFlagStatus(const unsigned s) existFlag.SetStatus(s);
}
-void PokeGen::PokeMod::MapEffect::SetExistFlagStatus(const String &s)
+void PokeGen::PokeMod::MapEffect::SetExistFlagStatus(const QString &s)
{
SetExistFlagStatus(FindIn(FV_END, s, FlagValueStr));
}
@@ -251,7 +250,7 @@ void PokeGen::PokeMod::MapEffect::SetEffect(const unsigned e) }
}
-void PokeGen::PokeMod::MapEffect::SetEffect(const String &e)
+void PokeGen::PokeMod::MapEffect::SetEffect(const QString &e)
{
SetEffect(FindIn(MAPE_END, e, MapEffectStr));
}
@@ -311,7 +310,7 @@ void PokeGen::PokeMod::MapEffect::SetVal2(const unsigned v2) }
}
-void PokeGen::PokeMod::MapEffect::SetVal2(const String &v2)
+void PokeGen::PokeMod::MapEffect::SetVal2(const QString &v2)
{
switch (effect)
{
@@ -343,7 +342,7 @@ void PokeGen::PokeMod::MapEffect::SetDirection(const unsigned d) direction = d;
}
-void PokeGen::PokeMod::MapEffect::SetDirection(const String &d)
+void PokeGen::PokeMod::MapEffect::SetDirection(const QString &d)
{
SetDirection(FindIn(DIR_END_NONE, d, DirectionStr));
}
@@ -367,7 +366,7 @@ void PokeGen::PokeMod::MapEffect::SetDialog(const unsigned d) dialog = d;
}
-PokeGen::PokeMod::String PokeGen::PokeMod::MapEffect::GetName() const
+QString PokeGen::PokeMod::MapEffect::GetName() const
{
LogFetchVar("MapEffect", id, "name", name);
return name;
@@ -409,7 +408,7 @@ unsigned PokeGen::PokeMod::MapEffect::GetExistFlagStatus() const return existFlag.GetStatus();
}
-PokeGen::PokeMod::String PokeGen::PokeMod::MapEffect::GetExistFlagStatusString() const
+QString PokeGen::PokeMod::MapEffect::GetExistFlagStatusString() const
{
LogFetchVar("MapEffect", id, "existFlag status string", existFlag.GetStatus(), name);
return existFlag.GetStatusString();
@@ -427,7 +426,7 @@ unsigned PokeGen::PokeMod::MapEffect::GetEffect() const return effect;
}
-PokeGen::PokeMod::String PokeGen::PokeMod::MapEffect::GetEffectString() const
+QString PokeGen::PokeMod::MapEffect::GetEffectString() const
{
LogFetchVar("MapEffect", id, "effect string", effect, name);
if (effect < MAPE_END)
@@ -447,10 +446,10 @@ unsigned PokeGen::PokeMod::MapEffect::GetVal2() const return val2;
}
-PokeGen::PokeMod::String PokeGen::PokeMod::MapEffect::GetVal2String() const
+QString PokeGen::PokeMod::MapEffect::GetVal2String() const
{
LogFetchVar("MapEffect", id, "val2 string", val2, name);
- String ret = "";
+ QString ret;
switch (effect)
{
case MAPE_ITEM:
@@ -476,7 +475,7 @@ unsigned PokeGen::PokeMod::MapEffect::GetDirection() const return direction;
}
-PokeGen::PokeMod::String PokeGen::PokeMod::MapEffect::GetDirectionString() const
+QString PokeGen::PokeMod::MapEffect::GetDirectionString() const
{
LogFetchVar("MapEffect", id, "direction string", direction, name);
if (direction < DIR_END_NONE)
@@ -502,7 +501,7 @@ unsigned PokeGen::PokeMod::MapEffect::GetDialog() const return dialog;
}
-PokeGen::PokeMod::String PokeGen::PokeMod::MapEffect::GetDialogString() const
+QString PokeGen::PokeMod::MapEffect::GetDialogString() const
{
LogFetchVar("MapEffect", id, "dialog string", dialog, name);
if (const Dialog *d = pokemod->GetDialog(dialog))
|
