From 73a9660e15ccd5bbabd5c90a63a3e15e36cee9fa Mon Sep 17 00:00:00 2001 From: Ben Boeckel Date: Sat, 7 Jun 2008 17:17:56 +0000 Subject: [FIX] UI files now use <> including rather than "" for KDE classes [FIX] Moved battle to pokebattle [FIX] Starting to figure out the battle system git-svn-id: https://pokegen.svn.sourceforge.net/svnroot/pokegen/trunk@197 6ecfd1a5-f3ed-3746-8530-beee90d26b22 --- Changelog | 9 ++++ battle/Arena.cpp | 39 -------------- battle/Arena.h | 79 ----------------------------- battle/Bot.h | 47 ----------------- battle/Ghost.cpp | 98 ------------------------------------ battle/Ghost.h | 70 -------------------------- battle/GhostBot.h | 47 ----------------- battle/Pokemon.h | 95 ---------------------------------- battle/Team.cpp | 77 ---------------------------- battle/Team.h | 55 -------------------- battle/battle.pro | 60 ---------------------- pokebattle/Arena.cpp | 19 +++++++ pokebattle/Arena.h | 40 +++++++++++++++ pokebattle/Bot.h | 29 +++++++++++ pokebattle/Ghost.cpp | 93 ++++++++++++++++++++++++++++++++++ pokebattle/Ghost.h | 59 ++++++++++++++++++++++ pokebattle/GhostBot.h | 26 ++++++++++ pokebattle/Pokemon.h | 26 ++++++++++ pokebattle/Team.cpp | 72 ++++++++++++++++++++++++++ pokebattle/Team.h | 26 ++++++++++ pokebattle/battle.pro | 25 +++++++++ pokemodr/gui/ability.ui | 2 +- pokemodr/gui/author.ui | 2 +- pokemodr/gui/badge.ui | 8 +-- pokemodr/gui/coinlist.ui | 2 +- pokemodr/gui/coinlistobject.ui | 4 +- pokemodr/gui/egggroup.ui | 2 +- pokemodr/gui/fraction.ui | 4 +- pokemodr/gui/globalscript.ui | 2 +- pokemodr/gui/item.ui | 6 +-- pokemodr/gui/itemtype.ui | 6 +-- pokemodr/gui/map.ui | 6 +-- pokemodr/gui/mapeffect.ui | 4 +- pokemodr/gui/maptrainer.ui | 6 +-- pokemodr/gui/maptrainerteammember.ui | 6 +-- pokemodr/gui/mapwarp.ui | 4 +- pokemodr/gui/mapwildlist.ui | 2 +- pokemodr/gui/mapwildlistencounter.ui | 4 +- pokemodr/gui/move.ui | 6 +-- pokemodr/gui/nature.ui | 6 +-- pokemodr/gui/point.ui | 2 +- pokemodr/gui/pokemod.ui | 8 +-- pokemodr/gui/pokemodr.ui | 4 +- pokemodr/gui/rules.ui | 6 +-- pokemodr/gui/script.ui | 4 +- pokemodr/gui/sound.ui | 2 +- pokemodr/gui/species.ui | 12 ++--- pokemodr/gui/speciesability.ui | 4 +- pokemodr/gui/speciesitem.ui | 4 +- pokemodr/gui/speciesmove.ui | 4 +- pokemodr/gui/sprite.ui | 4 +- pokemodr/gui/status.ui | 2 +- pokemodr/gui/store.ui | 4 +- pokemodr/gui/tile.ui | 6 +-- pokemodr/gui/time.ui | 2 +- pokemodr/gui/trainer.ui | 6 +-- pokemodr/gui/type.ui | 2 +- pokemodr/gui/weather.ui | 2 +- 58 files changed, 504 insertions(+), 747 deletions(-) delete mode 100644 battle/Arena.cpp delete mode 100644 battle/Arena.h delete mode 100644 battle/Bot.h delete mode 100644 battle/Ghost.cpp delete mode 100644 battle/Ghost.h delete mode 100644 battle/GhostBot.h delete mode 100644 battle/Pokemon.h delete mode 100644 battle/Team.cpp delete mode 100644 battle/Team.h delete mode 100644 battle/battle.pro create mode 100644 pokebattle/Arena.cpp create mode 100644 pokebattle/Arena.h create mode 100644 pokebattle/Bot.h create mode 100644 pokebattle/Ghost.cpp create mode 100644 pokebattle/Ghost.h create mode 100644 pokebattle/GhostBot.h create mode 100644 pokebattle/Pokemon.h create mode 100644 pokebattle/Team.cpp create mode 100644 pokebattle/Team.h create mode 100644 pokebattle/battle.pro diff --git a/Changelog b/Changelog index 8267d469..a432cae4 100644 --- a/Changelog +++ b/Changelog @@ -1,3 +1,12 @@ +----------------- +Rev: 197 +Date: 7 June 2008 +User: MathStuf +----------------- +[FIX] UI files now use <> including rather than "" for KDE classes +[FIX] Moved battle to pokebattle +[FIX] Starting to figure out the battle system + ----------------- Rev: 196 Date: 6 June 2008 diff --git a/battle/Arena.cpp b/battle/Arena.cpp deleted file mode 100644 index 0927a50c..00000000 --- a/battle/Arena.cpp +++ /dev/null @@ -1,39 +0,0 @@ -///////////////////////////////////////////////////////////////////////////// -// Name: ai/AlphaBeta.cpp -// Purpose: Alpha-Beta pruning MiniMax tree -// Author: Ben Boeckel -// Modified by: Ben Boeckel -// Created: Tue Oct 16 2007 09:09:44 -// Copyright: ©2007-2008 Ben Boeckel and Nerdy Productions -// Licence: -// 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 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, see . -///////////////////////////////////////////////////////////////////////////// - -#include "Arena.h" - -long Arena::AlphaBeta(AIProfile ai, Arena arena, const unsigned depth, const long alpha, const long beta) -{ - long val; - if (!depth) - return ai.eval(Arena); - while (CanSimulate()) - { - val = -AlphaBeta(Arena.Simulate(), depth - 1, -beta, -alpha); - if (beta <= val) - return beta; - if (alpha < val) - alpha = val; - } - return alpha; -} diff --git a/battle/Arena.h b/battle/Arena.h deleted file mode 100644 index 3745b065..00000000 --- a/battle/Arena.h +++ /dev/null @@ -1,79 +0,0 @@ -///////////////////////////////////////////////////////////////////////////// -// Name: battle/Arena.h -// Purpose: Class to handle the battle environment -// Author: Ben Boeckel -// Modified by: Ben Boeckel -// Created: Tue Oct 16 2007 09:21:30 -// Copyright: ©2007-2008 Ben Boeckel and Nerdy Productions -// Licence: -// 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 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, see . -///////////////////////////////////////////////////////////////////////////// - -#ifndef __BATTLE_ARENA__ -#define __BATTLE_ARENA__ - -#include -#include "Pokemon.h" -#include "Team.h" -#include "pokemod/Ability.h" -#include "pokemod/Item.h" -#include "pokemod/MapTrainer.h" -#include "pokemod/Move.h" -#include "pokemod/Nature.h" -#include "pokemod/Pokemon.h" -#include "pokemod/Type.h" - -class Arena -{ - public: - typedef struct - { - unsigned action; - union - { - Pokemon pokemon; - unsigned value; - }; - }Action; - - enum - { - A_Fight = 0, - A_Switch = 1, - A_Item = 2, - A_Run = 3, - A_End_Choices = 4, - A_Ability = 4, - A_HeldItem = 5, - A_End_All = 6 - }; - - Arena(Team& p, Team& e); - - bool Play(); - - unsigned CheckWeather() const; - private: - void AskForActions(); - void ParseActions(const Action action1, const Action action2); - - long PokeGen::AlphaBeta(AIProfile ai, Arena arena, const unsigned depth, const long alpha = LONG_MIN, const long beta = LONG_MAX); - - Team player; - Team opponent; - - unsigned weather; -}; - -#endif diff --git a/battle/Bot.h b/battle/Bot.h deleted file mode 100644 index d20333da..00000000 --- a/battle/Bot.h +++ /dev/null @@ -1,47 +0,0 @@ -///////////////////////////////////////////////////////////////////////////// -// Name: battle/Bot.h -// Purpose: AI interface to the Team class -// Author: Ben Boeckel -// Modified by: Ben Boeckel -// Created: Tue Oct 16 2007 11:44:16 -// Copyright: ©2007-2008 Ben Boeckel and Nerdy Productions -// Licence: -// 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 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, see . -///////////////////////////////////////////////////////////////////////////// - -#ifndef __POKEGEN_BOT__ -#define __POKEGEN_BOT__ - -#include -#include -#include "../general/Ini.h" -#include "AIProfile.h" -#include "Arena.h" -#include "GhostBot.h" -#include "Team.h" -#include "../pokemod/MapTrainer.h" - -class Bot : public Team -{ - public: - Bot(const PokeMod::Pokemod& par, PokeMod::MapTrainer trainer); - - void InformOfAction(Arena::Action action); - Arena::Action RequestAction(Arena arena); - private: - GhostBot simulator; - AIProfile ai; -}; - -#endif diff --git a/battle/Ghost.cpp b/battle/Ghost.cpp deleted file mode 100644 index b994da05..00000000 --- a/battle/Ghost.cpp +++ /dev/null @@ -1,98 +0,0 @@ -///////////////////////////////////////////////////////////////////////////// -// Name: battle/Ghost.cpp -// Purpose: Ghost used by the AI for simulations -// Author: Ben Boeckel -// Modified by: Ben Boeckel -// Created: Tue Oct 16 2007 19:29:30 -// Copyright: ©2007-2008 Ben Boeckel and Nerdy Productions -// Licence: -// 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 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, see . -///////////////////////////////////////////////////////////////////////////// - -#include "Ghost.h" - -Ghost(const PokeMod::Pokemod& par, const unsigned s, const unsigned l, const unsigned t) : - Pokemon(par, s, l), - teamSize(t), - unknownMoves(par->GetMaxMoves()) -{ - for (unsigned i = 0; i < PokeMod::ST_End_GSC; ++i) - { - dv[i] = 0; - statExp[i] = 0; - minStats[i] = GetStat(i); - dv[i] = pokemod->GetMaxDV(); - statExp[i] = 65535; - maxStats[i] = GetStat(i); - } - Species* pkmn = pokemod->GetSpeciesByID(s); - if (pkmn->GetNumAbilities() == 1) - FeedAbility(pkmn->GetAbility(0)); -} - -void FeedAttack(const unsigned actualDamage, const unsigned stat, const unsigned otherLevel, const unsigned power, const bool isAttacker) -{ - -} - -void FeedItem(const unsigned i) -{ - items.append(i); -} - -void FeedMove(const unsigned m) -{ - if (!moves.contains(m)) - { - moves.insert(m); - --unknownMoves; - moveChances[m] = UINT_MAX; - for (QMutableMapIterator i(moveChances); i.hasNext(); i.next()) - { - if (i.value() != UINT_MAX) - { - i.value() *= unknownMoves; - i.value() /= (unknownMoves + 1); - if (!i.value()) - moveChances.erase(i); - } - } - for (QListIterator i(moveCombos); i.hasNext(); i.next()) - { - if (i.prereqs.intersect(moves).size() && !moves.contains(i.move)) - moves[i.move] *= i.chance; - } - } -} - -void FeedMoveChance(const unsigned m, const unsigned weight) -{ - moveChances[m] = weight; -} - -void FeedAbility(const unsigned a) -{ - ability = a; -} - -void UpdateHP() -{ - curHP = hpPercent * maxStats[PokeMod::ST_HP]; -} - -void SetHP(const Frac p) -{ - hpPercent = p; - UpdateHP(); -} diff --git a/battle/Ghost.h b/battle/Ghost.h deleted file mode 100644 index 84d0d09e..00000000 --- a/battle/Ghost.h +++ /dev/null @@ -1,70 +0,0 @@ -///////////////////////////////////////////////////////////////////////////// -// Name: battle/Ghost.h -// Purpose: Ghost used by the AI for simulations -// Author: Ben Boeckel -// Modified by: Ben Boeckel -// Created: Tue Oct 16 2007 11:52:23 -// Copyright: ©2007-2008 Ben Boeckel and Nerdy Productions -// Licence: -// 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 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, see . -///////////////////////////////////////////////////////////////////////////// - -#ifndef __POKEGEN_GHOST__ -#define __POKEGEN_GHOST__ - -#include -#include -#include -#include "../general/Ini.h" -#include "../pokemod/Frac.h" -#include "Arena.h" -#include "Team.h" - -class Ghost : public Pokemon -{ - public: - Ghost(const PokeMod::Pokemod& par, const unsigned s, const unsigned l); - - void FeedAttack(const unsigned actualDamage, const unsigned stat, const unsigned otherLevel, const unsigned power, const bool isAttacker); - void FeedItem(const unsigned i); - void FeedMove(const unsigned m); - void FeedMoveChance(const unsigned m, const unsigned weight); - void FeedMoveCombo(const MoveCombo m); - void FeedAbility(const unsigned a); - - void UpdateHP(); - void SetHP(const Frac p); - private: - struct MoveCombo - { - public: - MoveCombo(const QSet p, const unsigned m, const unsigned c) : - prereqs(p), - move(m), - chance(c) - { - } - QSet prereqs; - unsigned move; - const unsigned chance; - }; - - unsigned minStats[PokeMod::ST_End_GSC]; - unsigned maxStats[PokeMod::ST_End_GSC]; - QMap moveChances; - QList moveCombos; - unsigned unknownMoves; -}; - -#endif diff --git a/battle/GhostBot.h b/battle/GhostBot.h deleted file mode 100644 index f5c986d8..00000000 --- a/battle/GhostBot.h +++ /dev/null @@ -1,47 +0,0 @@ -///////////////////////////////////////////////////////////////////////////// -// Name: pokegen/GhostBot.h -// Purpose: Ghost player used by the AI for simulations -// Author: Ben Boeckel -// Modified by: Ben Boeckel -// Created: Tue Oct 16 2007 11:52:23 -// Copyright: ©2007-2008 Ben Boeckel and Nerdy Productions -// Licence: -// 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 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, see . -///////////////////////////////////////////////////////////////////////////// - -#ifndef __POKEGEN_GHOSTBOT__ -#define __POKEGEN_GHOSTBOT__ - -#include -#include -#include "../Ini.h" -#include "AIProfile.h" -#include "Arena.h" -#include "Ghost.h" -#include "Team.h" - -class GhostBot : public Team -{ - public: - Ghost(const PokeMod::Pokemod& par, const QString aiFile, Bot host, const unsigned s, const unsigned l); - - void FeedAttack(const unsigned stat, const unsigned otherLevel, const unsigned power, const bool isAttacker); - void FeedItem(const unsigned i); - void FeedMove(const unsigned m); - void FeedAbility(const unsigned a); - private: - AIProfile ai; -}; - -#endif diff --git a/battle/Pokemon.h b/battle/Pokemon.h deleted file mode 100644 index 5b5b7a8c..00000000 --- a/battle/Pokemon.h +++ /dev/null @@ -1,95 +0,0 @@ -///////////////////////////////////////////////////////////////////////////// -// Name: pokegen/Pokemon.h -// Purpose: Data relevant to a Pokemon in the game -// Author: Ben Boeckel -// Modified by: Ben Boeckel -// Created: Tue Oct 16 2007 09:21:30 -// Copyright: ©2007-2008 Ben Boeckel and Nerdy Productions -// Licence: -// 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 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, see . -///////////////////////////////////////////////////////////////////////////// - -#ifndef __POKEGEN_POKEMON__ -#define __POKEGEN_POKEMON__ - -#include -#include -#include -#include "../general/Frac.h" -#include "../general/Ini.h" -#include "../pokemod/Ability.h" -#include "../pokemod/Item.h" -#include "../pokemod/Nature.h" -#include "../pokemod/Pokemod.h" -#include "../pokemod/Species.h" - -class Pokemon -{ - public: - Pokemon(const PokeMod::Pokemod& par, Ini ini); - Pokemon(const PokeMod::Pokemod& par, const unsigned s, const unsigned l); - - unsigned GetStat(const unsigned s) const; - unsigned GetLevel() const; - - unsigned GetNumMoves() const; - bool SimulateMove(const unsigned m) const; - bool UseMove(const unsigned m); - bool UnlearnMove(const unsigned m); - - bool SetStatus(const unsigned s); - - bool UseItemOn(const unsigned i); - - unsigned GetNumHeldItems() const; - unsigned GetHeldItem(const unsigned h); - bool GiveItem(const unsigned i); - bool TakeItem(const unsigned i); - bool SimulateTakeItem(const unsigned i) const; - - bool CanFight() const; - - void OutOfBattle(); - protected: - typedef struct - { - Frac statMultipliers[PokeMod::ST_End_Battle]; - bool isConfused; - bool isAttracted; - QList diabled; - unsigned substituteHP; - Frac toxicMultiplier; - }BattleSettings; - - void GrowLevel(); - - unsigned species; - QString name; - QSet moves; - QList heldItems; - QList powerPoints; - unsigned dv[PokeMod::ST_End_GSC]; - unsigned statExp[PokeMod::ST_End_GSC]; - unsigned curHP; - unsigned experience; - unsigned nature; - unsigned ability; - unsigned status; - - BattleSettings battleSettings; - - const PokeMod::Pokemod& pokemod; -}; - -#endif diff --git a/battle/Team.cpp b/battle/Team.cpp deleted file mode 100644 index f1d83b54..00000000 --- a/battle/Team.cpp +++ /dev/null @@ -1,77 +0,0 @@ -///////////////////////////////////////////////////////////////////////////// -// Name: battle/Team.cpp -// Purpose: Base class which is used to interface with the arena -// Author: Ben Boeckel -// Modified by: Ben Boeckel -// Created: Tue Oct 16 2007 19:22:20 -// Copyright: ©2007-2008 Ben Boeckel and Nerdy Productions -// Licence: -// 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 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, see . -///////////////////////////////////////////////////////////////////////////// - -#include "Team.h" - -Team::Team(const PokeMod::Pokemod& par) : - active(0), - parent(par) -{ -} - -void Team::AddItem(const unsigned i, const unsigned amt) -{ - if (amt) - items[i] = amt; -} - -void Team::UseItem(const unsigned i) -{ - if (items.contains(i) && (items[i] != UINT_MAX)) - { - --items[i]; - if (!items[i]) - items.remove(i); - } -} - -void Team::AddPokemon(Pokemon& p) -{ - pokemon.append(&p); -} - -void Team::SwapPokemon(const unsigned a, const unsigned b) -{ - if ((a < pokemon.size()) && (b < pokemon.size())) - { - Pokemon* p = pokemon[a]; - pokemon[a] = pokemon[b]; - pokemon[b] = p; - } -} - -bool Team::SetActivePokemon(const unsigned a) -{ - if ((a < pokemon.size()) && pokemon[a]->CanFight()) - active = a; -} - -unsigned Team::CanFight() const -{ - unsigned alive = 0; - for (unsigned i = 0; (i < pokemon.size()) && !alive; ++i) - { - if (pokemon[i]->CanFight()) - ++alive; - } - return alive; -} diff --git a/battle/Team.h b/battle/Team.h deleted file mode 100644 index b18b60fa..00000000 --- a/battle/Team.h +++ /dev/null @@ -1,55 +0,0 @@ -///////////////////////////////////////////////////////////////////////////// -// Name: battle/Team.h -// Purpose: Base class which is used to interface with the arena -// Author: Ben Boeckel -// Modified by: Ben Boeckel -// Created: Tue Oct 16 2007 09:21:30 -// Copyright: ©2007-2008 Ben Boeckel and Nerdy Productions -// Licence: -// 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 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, see . -///////////////////////////////////////////////////////////////////////////// - -#ifndef __BATTLE_TEAM__ -#define __BATTLE_TEAM__ - -#include -#include -#include "Arena.h" -#include "Pokemon.h" - -class Team -{ - public: - Team(const PokeMod::Pokemod& par); - - void AddItem(const unsigned i, const unsigned amt); - void UseItem(const unsigned i); - - void AddPokemon(Pokemon& p); - void SwapPokemon(const unsigned a, const unsigned b); - bool SetActivePokemon(const unsigned a); - - unsigned CanFight() const; - - virtual void InformOfAction(Arena::Action action); - virtual Arena::Action RequestAction(Arena arena); - protected: - QList pokemon; - QMap items; - unsigned active; - - const PokeMod::Pokemod& parent; -}; - -#endif diff --git a/battle/battle.pro b/battle/battle.pro deleted file mode 100644 index 818d3fe7..00000000 --- a/battle/battle.pro +++ /dev/null @@ -1,60 +0,0 @@ -OBJECTS_DIR = .obj -DESTDIR = ../../lib -TEMPLATE = lib -LIBS += -L../../lib -lgeneral -lpokemod - -CONFIG += qt warn_on dll exceptions - -# Following is reformatted from the KTIGCC .pro file -win32 { - KDEPREFIX = $$(KDEPREFIX) - isEmpty(KDEPREFIX){ - # Try running kde4-config, however chances are it's not in the path or it was compiled with a bad prefix. - KDEPREFIX = $$system(kde4-config --prefix) - isEmpty(KDEPREFIX) : error("KDE 4 kdelibs not found, set KDEPREFIX.") - !exists($$KDEPREFIX) : error("KDE 4 kdelibs not found, set KDEPREFIX.") - } - KDEINCDIR = $$KDEPREFIX/include - # $$KDEINCDIR/mingw contains the kdewin32 headers, defining stuff like mkdtemp. - INCLUDEPATH += $$KDEINCDIR/mingw $$KDEINCDIR - LIBS += -lkdewin32 - QMAKE_LIBDIR = $$KDEPREFIX/lib $$QMAKE_LIBDIR -}else { - KDEPREFIX = $$system(kde4-config --prefix) - isEmpty(KDEPREFIX) : error("KDE 4 kdelibs required.") - exists($$KDEPREFIX/include/kde4/KDE){ - KDEINCDIR = $$KDEPREFIX/include/kde4 - } else : exists($$KDEPREFIX/include/kde/KDE){ - KDEINCDIR = $$KDEPREFIX/include/kde - } else { - KDEINCDIR = $$KDEPREFIX/include - } - INCLUDEPATH += $$KDEINCDIR - KDELIBDIR = $$KDEPREFIX/lib$$system(kde4-config --libsuffix) - KDEDEVELLIBDIR = $$KDELIBDIR - exists($$KDEDEVELLIBDIR/kde4/devel){ - KDEDEVELLIBDIR = $$KDEDEVELLIBDIR/kde4/devel - } - !equals(KDEDEVELLIBDIR,/usr/lib) : !equals(KDEDEVELLIBDIR,/usr/lib64){ - QMAKE_LIBDIR = $$KDEDEVELLIBDIR $$QMAKE_LIBDIR - } - !equals(KDELIBDIR,/usr/lib):!equals(KDELIBDIR,/usr/lib64){ - !darwin-* : !macx-* { - LIBS += -Wl,--rpath,"$$KDELIBDIR" - } - } -} - -INCLUDEPATH += ../pokemod ../general -TARGETDEPS += ../../lib/libpokemod.so ../../lib/libgeneral.so - -SOURCES += Arena.cpp \ - Ghost.cpp \ - Team.cpp - -HEADERS += Arena.h \ - Bot.h \ - GhostBot.h \ - Ghost.h \ - Pokemon.h \ - Team.h diff --git a/pokebattle/Arena.cpp b/pokebattle/Arena.cpp new file mode 100644 index 00000000..7894db93 --- /dev/null +++ b/pokebattle/Arena.cpp @@ -0,0 +1,19 @@ +/* + * Copyright 2007-2008 Ben Boeckel + * + * 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 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, see . + */ + +#include "Arena.h" + diff --git a/pokebattle/Arena.h b/pokebattle/Arena.h new file mode 100644 index 00000000..9b291222 --- /dev/null +++ b/pokebattle/Arena.h @@ -0,0 +1,40 @@ +/* + * Copyright 2007-2008 Ben Boeckel + * + * 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 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, see . + */ + +#ifndef __POKEBATTLE_ARENA__ +#define __POKEBATTLE_ARENA__ + +class Arena : public QObject +{ + Q_OBJECT + + public: + Arena(Team& p, Team& e); + + bool Play(); + + unsigned CheckWeather() const; + private: + long PokeGen::AlphaBeta(AIProfile ai, Arena arena, const unsigned depth, const long alpha = LONG_MIN, const long beta = LONG_MAX); + + Team player; + Team opponent; + + unsigned weather; +}; + +#endif diff --git a/pokebattle/Bot.h b/pokebattle/Bot.h new file mode 100644 index 00000000..64f48a89 --- /dev/null +++ b/pokebattle/Bot.h @@ -0,0 +1,29 @@ +/* + * Copyright 2007-2008 Ben Boeckel + * + * 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 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, see . + */ + +#ifndef __POKEBATTLE_BOT__ +#define __POKEBATTLE_BOT__ + +class Bot : public Team +{ + Q_OBJECT + + private: + long alphaBeta(const Arena& arena, const Trainer& , const long alpha = LONG_MIN, const long beta = LONG_MAX); +}; + +#endif diff --git a/pokebattle/Ghost.cpp b/pokebattle/Ghost.cpp new file mode 100644 index 00000000..79c08ff0 --- /dev/null +++ b/pokebattle/Ghost.cpp @@ -0,0 +1,93 @@ +/* + * Copyright 2007-2008 Ben Boeckel + * + * 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 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, see . + */ + +#include "Ghost.h" + +Ghost(const PokeMod::Pokemod& par, const unsigned s, const unsigned l, const unsigned t) : + Pokemon(par, s, l), + teamSize(t), + unknownMoves(par->GetMaxMoves()) +{ + for (unsigned i = 0; i < PokeMod::ST_End_GSC; ++i) + { + dv[i] = 0; + statExp[i] = 0; + minStats[i] = GetStat(i); + dv[i] = pokemod->GetMaxDV(); + statExp[i] = 65535; + maxStats[i] = GetStat(i); + } + Species* pkmn = pokemod->GetSpeciesByID(s); + if (pkmn->GetNumAbilities() == 1) + FeedAbility(pkmn->GetAbility(0)); +} + +void FeedAttack(const unsigned actualDamage, const unsigned stat, const unsigned otherLevel, const unsigned power, const bool isAttacker) +{ + +} + +void FeedItem(const unsigned i) +{ + items.append(i); +} + +void FeedMove(const unsigned m) +{ + if (!moves.contains(m)) + { + moves.insert(m); + --unknownMoves; + moveChances[m] = UINT_MAX; + for (QMutableMapIterator i(moveChances); i.hasNext(); i.next()) + { + if (i.value() != UINT_MAX) + { + i.value() *= unknownMoves; + i.value() /= (unknownMoves + 1); + if (!i.value()) + moveChances.erase(i); + } + } + for (QListIterator i(moveCombos); i.hasNext(); i.next()) + { + if (i.prereqs.intersect(moves).size() && !moves.contains(i.move)) + moves[i.move] *= i.chance; + } + } +} + +void FeedMoveChance(const unsigned m, const unsigned weight) +{ + moveChances[m] = weight; +} + +void FeedAbility(const unsigned a) +{ + ability = a; +} + +void UpdateHP() +{ + curHP = hpPercent * maxStats[PokeMod::ST_HP]; +} + +void SetHP(const Frac p) +{ + hpPercent = p; + UpdateHP(); +} diff --git a/pokebattle/Ghost.h b/pokebattle/Ghost.h new file mode 100644 index 00000000..17824298 --- /dev/null +++ b/pokebattle/Ghost.h @@ -0,0 +1,59 @@ +/* + * Copyright 2007-2008 Ben Boeckel + * + * 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 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, see . + */ + +#ifndef __POKEBATTLE_GHOST__ +#define __POKEBATTLE_GHOST__ + +class Ghost : public Pokemon +{ + Q_OBJECT + + public: + Ghost(const PokeMod::Pokemod& par, const unsigned s, const unsigned l); + + void FeedAttack(const unsigned actualDamage, const unsigned stat, const unsigned otherLevel, const unsigned power, const bool isAttacker); + void FeedItem(const unsigned i); + void FeedMove(const unsigned m); + void FeedMoveChance(const unsigned m, const unsigned weight); + void FeedMoveCombo(const MoveCombo m); + void FeedAbility(const unsigned a); + + void UpdateHP(); + void SetHP(const Frac p); + private: + struct MoveCombo + { + public: + MoveCombo(const QSet p, const unsigned m, const unsigned c) : + prereqs(p), + move(m), + chance(c) + { + } + QSet prereqs; + unsigned move; + const unsigned chance; + }; + + unsigned minStats[PokeMod::ST_End_GSC]; + unsigned maxStats[PokeMod::ST_End_GSC]; + QMap moveChances; + QList moveCombos; + unsigned unknownMoves; +}; + +#endif diff --git a/pokebattle/GhostBot.h b/pokebattle/GhostBot.h new file mode 100644 index 00000000..9fd2474c --- /dev/null +++ b/pokebattle/GhostBot.h @@ -0,0 +1,26 @@ +/* + * Copyright 2007-2008 Ben Boeckel + * + * 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 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, see . + */ + +#ifndef __POKEBATTLE_GHOSTBOT__ +#define __POKEBATTLE_GHOSTBOT__ + +class GhostBot : public Team +{ + Q_OBJECT +}; + +#endif diff --git a/pokebattle/Pokemon.h b/pokebattle/Pokemon.h new file mode 100644 index 00000000..04d3a0b9 --- /dev/null +++ b/pokebattle/Pokemon.h @@ -0,0 +1,26 @@ +/* + * Copyright 2007-2008 Ben Boeckel + * + * 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 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, see . + */ + +#ifndef __POKEBATTLE_TEAMMEMBER__ +#define __POKEBATTLE_TEAMMEMBER__ + +class TeamMember : public QObject +{ + Q_OBJECT +}; + +#endif diff --git a/pokebattle/Team.cpp b/pokebattle/Team.cpp new file mode 100644 index 00000000..707b05d9 --- /dev/null +++ b/pokebattle/Team.cpp @@ -0,0 +1,72 @@ +/* + * Copyright 2007-2008 Ben Boeckel + * + * 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 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, see . + */ + +#include "Team.h" + +Team::Team(const PokeMod::Pokemod& par) : + active(0), + parent(par) +{ +} + +void Team::AddItem(const unsigned i, const unsigned amt) +{ + if (amt) + items[i] = amt; +} + +void Team::UseItem(const unsigned i) +{ + if (items.contains(i) && (items[i] != UINT_MAX)) + { + --items[i]; + if (!items[i]) + items.remove(i); + } +} + +void Team::AddPokemon(Pokemon& p) +{ + pokemon.append(&p); +} + +void Team::SwapPokemon(const unsigned a, const unsigned b) +{ + if ((a < pokemon.size()) && (b < pokemon.size())) + { + Pokemon* p = pokemon[a]; + pokemon[a] = pokemon[b]; + pokemon[b] = p; + } +} + +bool Team::SetActivePokemon(const unsigned a) +{ + if ((a < pokemon.size()) && pokemon[a]->CanFight()) + active = a; +} + +unsigned Team::CanFight() const +{ + unsigned alive = 0; + for (unsigned i = 0; (i < pokemon.size()) && !alive; ++i) + { + if (pokemon[i]->CanFight()) + ++alive; + } + return alive; +} diff --git a/pokebattle/Team.h b/pokebattle/Team.h new file mode 100644 index 00000000..5ec14807 --- /dev/null +++ b/pokebattle/Team.h @@ -0,0 +1,26 @@ +/* + * Copyright 2007-2008 Ben Boeckel + * + * 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 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, see . + */ + +#ifndef __POKEBATTLE_TEAM__ +#define __POKEBATTLE_TEAM__ + +class Team : public QObject +{ + Q_OBJECT +}; + +#endif diff --git a/pokebattle/battle.pro b/pokebattle/battle.pro new file mode 100644 index 00000000..391e4160 --- /dev/null +++ b/pokebattle/battle.pro @@ -0,0 +1,25 @@ +include(../version.pri) +OBJECTS_DIR = .obj +DESTDIR = ../bin +TEMPLATE = lib +LIBS += -L../bin \ + -lpokemod + +CONFIG += qt \ + warn_on \ + dll + +include(../install.pri) + +SOURCES += Arena.cpp \ + Ghost.cpp \ + Team.cpp + +HEADERS += Arena.h \ + Bot.h \ + GhostBot.h \ + Ghost.h \ + Pokemon.h \ + Team.h + +include(../headers.pri) diff --git a/pokemodr/gui/ability.ui b/pokemodr/gui/ability.ui index ffbfaa69..c750096e 100644 --- a/pokemodr/gui/ability.ui +++ b/pokemodr/gui/ability.ui @@ -64,7 +64,7 @@ KLineEdit QLineEdit -
klineedit.h
+
KLineEdit
ScriptWidget diff --git a/pokemodr/gui/author.ui b/pokemodr/gui/author.ui index 25c63ce7..328f07be 100644 --- a/pokemodr/gui/author.ui +++ b/pokemodr/gui/author.ui @@ -78,7 +78,7 @@ KLineEdit QLineEdit -
klineedit.h
+
KLineEdit
diff --git a/pokemodr/gui/badge.ui b/pokemodr/gui/badge.ui index c8f0b7e2..ad5030b6 100644 --- a/pokemodr/gui/badge.ui +++ b/pokemodr/gui/badge.ui @@ -162,22 +162,22 @@ KComboBox QComboBox -
kcombobox.h
+
KComboBox
KIntNumInput QWidget -
knuminput.h
+
KIntNumInput
KLineEdit QLineEdit -
klineedit.h
+
KLineEdit
KPushButton QPushButton -
kpushbutton.h
+
KPushButton
FractionWidget diff --git a/pokemodr/gui/coinlist.ui b/pokemodr/gui/coinlist.ui index fd763d5a..f30c4275 100644 --- a/pokemodr/gui/coinlist.ui +++ b/pokemodr/gui/coinlist.ui @@ -52,7 +52,7 @@ KLineEdit QLineEdit -
klineedit.h
+
KLineEdit
ScriptWidget diff --git a/pokemodr/gui/coinlistobject.ui b/pokemodr/gui/coinlistobject.ui index a5027bc8..f7c6570d 100644 --- a/pokemodr/gui/coinlistobject.ui +++ b/pokemodr/gui/coinlistobject.ui @@ -91,12 +91,12 @@ KComboBox QComboBox -
kcombobox.h
+
KComboBox
KIntNumInput QWidget -
knuminput.h
+
KIntNumInput
diff --git a/pokemodr/gui/egggroup.ui b/pokemodr/gui/egggroup.ui index a50ab2bf..42a66df2 100644 --- a/pokemodr/gui/egggroup.ui +++ b/pokemodr/gui/egggroup.ui @@ -40,7 +40,7 @@ KLineEdit QLineEdit -
klineedit.h
+
KLineEdit
diff --git a/pokemodr/gui/fraction.ui b/pokemodr/gui/fraction.ui index d3eb9587..51bd76f9 100644 --- a/pokemodr/gui/fraction.ui +++ b/pokemodr/gui/fraction.ui @@ -35,12 +35,12 @@ KIntNumInput QWidget -
knuminput.h
+
KIntNumInput
KLineEdit QLineEdit -
klineedit.h
+
KLineEdit
diff --git a/pokemodr/gui/globalscript.ui b/pokemodr/gui/globalscript.ui index fb920252..e07aacf1 100644 --- a/pokemodr/gui/globalscript.ui +++ b/pokemodr/gui/globalscript.ui @@ -49,7 +49,7 @@ KLineEdit QLineEdit -
klineedit.h
+
KLineEdit
ScriptWidget diff --git a/pokemodr/gui/item.ui b/pokemodr/gui/item.ui index c47c47a8..473572a5 100644 --- a/pokemodr/gui/item.ui +++ b/pokemodr/gui/item.ui @@ -116,17 +116,17 @@ KComboBox QComboBox -
kcombobox.h
+
KComboBox
KIntNumInput QWidget -
knuminput.h
+
KIntNumInput
KLineEdit QLineEdit -
klineedit.h
+
KLineEdit
ScriptWidget diff --git a/pokemodr/gui/itemtype.ui b/pokemodr/gui/itemtype.ui index 87ed946f..b8413a23 100644 --- a/pokemodr/gui/itemtype.ui +++ b/pokemodr/gui/itemtype.ui @@ -94,17 +94,17 @@ KComboBox QComboBox -
kcombobox.h
+
KComboBox
KIntNumInput QWidget -
knuminput.h
+
KIntNumInput
KLineEdit QLineEdit -
klineedit.h
+
KLineEdit
diff --git a/pokemodr/gui/map.ui b/pokemodr/gui/map.ui index c180b5d4..9f9883d5 100644 --- a/pokemodr/gui/map.ui +++ b/pokemodr/gui/map.ui @@ -136,17 +136,17 @@ KComboBox QComboBox -
kcombobox.h
+
KComboBox
KLineEdit QLineEdit -
klineedit.h
+
KLineEdit
KPushButton QPushButton -
kpushbutton.h
+
KPushButton
diff --git a/pokemodr/gui/mapeffect.ui b/pokemodr/gui/mapeffect.ui index c842f7f9..33c44760 100644 --- a/pokemodr/gui/mapeffect.ui +++ b/pokemodr/gui/mapeffect.ui @@ -133,12 +133,12 @@ KLineEdit QLineEdit -
klineedit.h
+
KLineEdit
KPushButton QPushButton -
kpushbutton.h
+
KPushButton
ScriptWidget diff --git a/pokemodr/gui/maptrainer.ui b/pokemodr/gui/maptrainer.ui index 3555a3df..694d1ad8 100644 --- a/pokemodr/gui/maptrainer.ui +++ b/pokemodr/gui/maptrainer.ui @@ -115,17 +115,17 @@ KComboBox QComboBox -
kcombobox.h
+
KComboBox
KIntNumInput QWidget -
knuminput.h
+
KIntNumInput
KLineEdit QLineEdit -
klineedit.h
+
KLineEdit
ScriptWidget diff --git a/pokemodr/gui/maptrainerteammember.ui b/pokemodr/gui/maptrainerteammember.ui index 73412ac3..1191e86f 100644 --- a/pokemodr/gui/maptrainerteammember.ui +++ b/pokemodr/gui/maptrainerteammember.ui @@ -132,17 +132,17 @@ KComboBox QComboBox -
kcombobox.h
+
KComboBox
KIntNumInput QWidget -
knuminput.h
+
KIntNumInput
KListWidget QListWidget -
klistwidget.h
+
KListWidget
diff --git a/pokemodr/gui/mapwarp.ui b/pokemodr/gui/mapwarp.ui index 284f7f4c..89b05b8c 100644 --- a/pokemodr/gui/mapwarp.ui +++ b/pokemodr/gui/mapwarp.ui @@ -116,12 +116,12 @@ KComboBox QComboBox -
kcombobox.h
+
KComboBox
KLineEdit QLineEdit -
klineedit.h
+
KLineEdit
ScriptWidget diff --git a/pokemodr/gui/mapwildlist.ui b/pokemodr/gui/mapwildlist.ui index 77360138..c14c85f3 100644 --- a/pokemodr/gui/mapwildlist.ui +++ b/pokemodr/gui/mapwildlist.ui @@ -40,7 +40,7 @@ KLineEdit QLineEdit -
klineedit.h
+
KLineEdit
diff --git a/pokemodr/gui/mapwildlistencounter.ui b/pokemodr/gui/mapwildlistencounter.ui index 980e8da5..e329b892 100644 --- a/pokemodr/gui/mapwildlistencounter.ui +++ b/pokemodr/gui/mapwildlistencounter.ui @@ -75,12 +75,12 @@ KComboBox QComboBox -
kcombobox.h
+
KComboBox
KIntNumInput QWidget -
knuminput.h
+
KIntNumInput
diff --git a/pokemodr/gui/move.ui b/pokemodr/gui/move.ui index 841c7524..86e419c9 100644 --- a/pokemodr/gui/move.ui +++ b/pokemodr/gui/move.ui @@ -167,17 +167,17 @@ KComboBox QComboBox -
kcombobox.h
+
KComboBox
KIntNumInput QWidget -
knuminput.h
+
KIntNumInput
KLineEdit QLineEdit -
klineedit.h
+
KLineEdit
FractionWidget diff --git a/pokemodr/gui/nature.ui b/pokemodr/gui/nature.ui index 38683034..c782442c 100644 --- a/pokemodr/gui/nature.ui +++ b/pokemodr/gui/nature.ui @@ -91,17 +91,17 @@ KComboBox QComboBox -
kcombobox.h
+
KComboBox
KIntNumInput QWidget -
knuminput.h
+
KIntNumInput
KLineEdit QLineEdit -
klineedit.h
+
KLineEdit
FractionWidget diff --git a/pokemodr/gui/point.ui b/pokemodr/gui/point.ui index cb1db190..13b71c63 100644 --- a/pokemodr/gui/point.ui +++ b/pokemodr/gui/point.ui @@ -28,7 +28,7 @@ KIntNumInput QWidget -
knuminput.h
+
KIntNumInput
diff --git a/pokemodr/gui/pokemod.ui b/pokemodr/gui/pokemod.ui index 71201558..6ea2d44b 100644 --- a/pokemodr/gui/pokemod.ui +++ b/pokemodr/gui/pokemod.ui @@ -438,22 +438,22 @@ KComboBox QComboBox -
kcombobox.h
+
KComboBox
KLineEdit QLineEdit -
klineedit.h
+
KLineEdit
KPushButton QPushButton -
kpushbutton.h
+
KPushButton
KTabWidget QTabWidget -
ktabwidget.h
+
KTabWidget
1
diff --git a/pokemodr/gui/pokemodr.ui b/pokemodr/gui/pokemodr.ui index 39cca87a..c9b6a74c 100644 --- a/pokemodr/gui/pokemodr.ui +++ b/pokemodr/gui/pokemodr.ui @@ -83,12 +83,12 @@ KPushButton QPushButton -
kpushbutton.h
+
KPushButton
KMainWindow QMainWindow -
kmainwindow.h
+
KMainWindow
1
diff --git a/pokemodr/gui/rules.ui b/pokemodr/gui/rules.ui index 4afd943e..5e287c11 100644 --- a/pokemodr/gui/rules.ui +++ b/pokemodr/gui/rules.ui @@ -451,17 +451,17 @@ KComboBox QComboBox -
kcombobox.h
+
KComboBox
KIntNumInput QWidget -
knuminput.h
+
KIntNumInput
KTabWidget QTabWidget -
ktabwidget.h
+
KTabWidget
1
diff --git a/pokemodr/gui/script.ui b/pokemodr/gui/script.ui index 62d6a2ce..4853c8e6 100644 --- a/pokemodr/gui/script.ui +++ b/pokemodr/gui/script.ui @@ -39,12 +39,12 @@ KComboBox QComboBox -
kcombobox.h
+
KComboBox
KTextEdit QTextEdit -
ktextedit.h
+
KTextEdit
diff --git a/pokemodr/gui/sound.ui b/pokemodr/gui/sound.ui index 2aa1e980..03d11ea1 100644 --- a/pokemodr/gui/sound.ui +++ b/pokemodr/gui/sound.ui @@ -62,7 +62,7 @@ KLineEdit QLineEdit -
klineedit.h
+
KLineEdit
Phonon::SeekSlider diff --git a/pokemodr/gui/species.ui b/pokemodr/gui/species.ui index b72eb5e3..071fd759 100644 --- a/pokemodr/gui/species.ui +++ b/pokemodr/gui/species.ui @@ -670,32 +670,32 @@ KComboBox QComboBox -
kcombobox.h
+
KComboBox
KIntNumInput QWidget -
knuminput.h
+
KIntNumInput
KLineEdit QLineEdit -
klineedit.h
+
KLineEdit
KListWidget QListWidget -
klistwidget.h
+
KListWidget
KPushButton QPushButton -
kpushbutton.h
+
KPushButton
KTabWidget QTabWidget -
ktabwidget.h
+
KTabWidget
1
diff --git a/pokemodr/gui/speciesability.ui b/pokemodr/gui/speciesability.ui index bd3555f6..6d2fbb66 100644 --- a/pokemodr/gui/speciesability.ui +++ b/pokemodr/gui/speciesability.ui @@ -56,12 +56,12 @@ KComboBox QComboBox -
kcombobox.h
+
KComboBox
KIntNumInput QWidget -
knuminput.h
+
KIntNumInput
diff --git a/pokemodr/gui/speciesitem.ui b/pokemodr/gui/speciesitem.ui index 4af1340d..ee13b2d9 100644 --- a/pokemodr/gui/speciesitem.ui +++ b/pokemodr/gui/speciesitem.ui @@ -56,12 +56,12 @@ KComboBox QComboBox -
kcombobox.h
+
KComboBox
KIntNumInput QWidget -
knuminput.h
+
KIntNumInput
diff --git a/pokemodr/gui/speciesmove.ui b/pokemodr/gui/speciesmove.ui index 43af96c7..bc13fd85 100644 --- a/pokemodr/gui/speciesmove.ui +++ b/pokemodr/gui/speciesmove.ui @@ -75,12 +75,12 @@ KComboBox QComboBox -
kcombobox.h
+
KComboBox
KIntNumInput QWidget -
knuminput.h
+
KIntNumInput
diff --git a/pokemodr/gui/sprite.ui b/pokemodr/gui/sprite.ui index 01b5df1b..e93314af 100644 --- a/pokemodr/gui/sprite.ui +++ b/pokemodr/gui/sprite.ui @@ -78,12 +78,12 @@ KLineEdit QLineEdit -
klineedit.h
+
KLineEdit
KPushButton QPushButton -
kpushbutton.h
+
KPushButton
diff --git a/pokemodr/gui/status.ui b/pokemodr/gui/status.ui index 5037c86b..762bdaf5 100644 --- a/pokemodr/gui/status.ui +++ b/pokemodr/gui/status.ui @@ -52,7 +52,7 @@ KLineEdit QLineEdit -
klineedit.h
+
KLineEdit
ScriptWidget diff --git a/pokemodr/gui/store.ui b/pokemodr/gui/store.ui index 36267b2a..befd88ef 100644 --- a/pokemodr/gui/store.ui +++ b/pokemodr/gui/store.ui @@ -56,12 +56,12 @@ KLineEdit QLineEdit -
klineedit.h
+
KLineEdit
KListWidget QListWidget -
klistwidget.h
+
KListWidget
diff --git a/pokemodr/gui/tile.ui b/pokemodr/gui/tile.ui index 9d55d8ed..f8f654c7 100644 --- a/pokemodr/gui/tile.ui +++ b/pokemodr/gui/tile.ui @@ -119,17 +119,17 @@ KLineEdit QLineEdit -
klineedit.h
+
KLineEdit
KListWidget QListWidget -
klistwidget.h
+
KListWidget
KPushButton QPushButton -
kpushbutton.h
+
KPushButton
ScriptWidget diff --git a/pokemodr/gui/time.ui b/pokemodr/gui/time.ui index e8761143..0ea13ae0 100644 --- a/pokemodr/gui/time.ui +++ b/pokemodr/gui/time.ui @@ -62,7 +62,7 @@ KLineEdit QLineEdit -
klineedit.h
+
KLineEdit
diff --git a/pokemodr/gui/trainer.ui b/pokemodr/gui/trainer.ui index a2ba99f8..dedd7565 100644 --- a/pokemodr/gui/trainer.ui +++ b/pokemodr/gui/trainer.ui @@ -101,17 +101,17 @@ KIntNumInput QWidget -
knuminput.h
+
KIntNumInput
KLineEdit QLineEdit -
klineedit.h
+
KLineEdit
KPushButton QPushButton -
kpushbutton.h
+
KPushButton
diff --git a/pokemodr/gui/type.ui b/pokemodr/gui/type.ui index ff8cfdb2..8b712978 100644 --- a/pokemodr/gui/type.ui +++ b/pokemodr/gui/type.ui @@ -59,7 +59,7 @@ KLineEdit QLineEdit -
klineedit.h
+
KLineEdit
FractionWidget diff --git a/pokemodr/gui/weather.ui b/pokemodr/gui/weather.ui index 2525b0aa..8cc59eb8 100644 --- a/pokemodr/gui/weather.ui +++ b/pokemodr/gui/weather.ui @@ -52,7 +52,7 @@ KLineEdit QLineEdit -
klineedit.h
+
KLineEdit
ScriptWidget -- cgit