Crossfire Server, Trunk
|
#include <Qt>
#include <QtWidgets>
#include <CREMainWindow.h>
#include <CREResourcesWindow.h>
#include "CREMapInformationManager.h"
#include "CREExperienceWindow.h"
#include "MessageManager.h"
#include "CREReportDisplay.h"
#include "CREPixmap.h"
#include "CRESmoothFaceMaker.h"
#include "CREHPBarMaker.h"
#include "ResourcesManager.h"
#include "CRECombatSimulator.h"
#include "scripts/ScriptFileManager.h"
#include "FaceMakerDialog.h"
#include "EditMonstersDialog.h"
#include "random_maps/RandomMap.h"
#include "global.h"
#include "sproto.h"
#include "image.h"
#include "assets.h"
#include "AssetsManager.h"
#include "CRESettings.h"
#include "LicenseManager.h"
#include "AllAssets.h"
#include "assets/AssetModel.h"
#include "ChangesDock.h"
#include "HelpManager.h"
#include "MonsterResistances.h"
Go to the source code of this file.
Functions | |
static QString | alchemyTable (const QString &skill, QStringList &noChance, std::vector< std::pair< QString, int >> &allIngredients) |
static QString | buildShopReport (const QString &title, const QStringList &types, const QList< CREMapInformation * > &maps, QStringList &items) |
static void | doIngredients (const std::vector< std::pair< QString, int >> &allIngredients, const QString &criteria, QString &report) |
static QString | monsterFight (archetype *monster, archetype *skill) |
static int | monsterFight (archetype *monster, archetype *skill, int level) |
static int | monsterFight (archetype *monster, archetype *skill, int level, int count) |
static QString | monsterTable (archetype *monster, QList< archetype * > skills) |
void | readDirectory (const QString &path, QHash< QString, QHash< QString, bool > > &states) |
static QString | reportSummon (const archetype *summon, const object *other, QString name) |
static QString | spellsTable (const QString &skill) |
|
static |
Definition at line 647 of file CREMainWindow.cpp.
References archininventory::arch, recipestruct::arch_name, recipestruct::arch_names, recipestruct::chance, disinfect::count, recipestruct::diff, recipestruct::exp, find_archetype(), get_formulalist(), recipestruct::ingred, recipestruct::ingred_count, is_valid_types_gen::line, guildoracle::list, give::name, recipestruct::next, linked_char::next, report::report(), recipestruct::skill, and recipestruct::title.
Referenced by CREMainWindow::onReportAlchemy().
|
static |
Definition at line 1344 of file CREMainWindow.cpp.
References say::item, is_valid_types_gen::line, disinfect::map, maps, report::report(), and types.
Referenced by CREMainWindow::onReportShops().
|
static |
Definition at line 734 of file CREMainWindow.cpp.
Referenced by CREMainWindow::onReportAlchemy().
Generate a report cell for player versus monster fight. Cell will contain the first level the player could defeat the monster. This level is determined via a kind of dichotomic search, trying levels and using the middle ground for next iteration.
monster | monster being fighted. |
skill | what the player uses to fight the monster. |
Definition at line 1070 of file CREMainWindow.cpp.
References archt::clone, disinfect::count, delete_map(), has_been_loaded(), mapdef::in_memory, level, MAP_IN_MEMORY, say::max, Settings::max_level, monsterFight(), obj::name, mapdef::reset_time, and settings.
Simulates a fight between a player and a monster. Player is a dwarf, with low statistics, no equipment. A maximum of 50 rounds are fighted (can be changed by modifying 'limit').
monster | evil guy being fighted. |
skill | what the player attacks the monster with. |
level | what skill level to use. |
Definition at line 939 of file CREMainWindow.cpp.
References attack_ob(), pl::bed_x, pl::bed_y, archt::clone, obj::contr, obj::count, delete_map(), do_some_living(), FABS, socket_struct::faces_sent, find_archetype(), fix_object(), FLAG_APPLIED, FREE_OBJ_FREE_INVENTORY, get_empty_map(), get_faces_count(), liv::hp, obj::level, level, obj::map, MAX_BUF, liv::maxhp, monster_do_living(), move_player(), pl::ob, object_create_arch(), object_free(), object_insert_in_map_at(), object_insert_in_ob(), object_remove(), object_was_destroyed, altar_valkyrie::pl, rotate-tower::result, pl::savebed_map, SET_FLAG, SK_TWO_HANDED_WEAPON, pl::socket, obj::speed, obj::speed_left, obj::stats, obj::subtype, archt::tail_x, archt::tail_y, test_map, obj::weapon_speed, and obj::weapon_speed_left.
Referenced by monsterFight(), and monsterTable().
Simulates a fight between a player and a monster. Player is a dwarf, with low statistics, no equipment. A maximum of 50 rounds are fighted per round.
monster | evil guy being fighted. |
skill | what the player attacks the monster with. |
level | what skill level to use. |
count | how many fights to simulate. |
Definition at line 1052 of file CREMainWindow.cpp.
References disinfect::count, and monsterFight().
Generate an HTML table line for a player versus monster fight statistics.
monster | what is being attacked. |
skills | list of skills to fight with. |
Definition at line 1130 of file CREMainWindow.cpp.
References liv::ac, archt::clone, liv::Con, liv::dam, liv::hp, obj::level, is_valid_types_gen::line, monsterFight(), obj::name, obj::speed, obj::stats, and liv::wc.
void readDirectory | ( | const QString & | path, |
QHash< QString, QHash< QString, bool > > & | states | ||
) |
Definition at line 1448 of file CREMainWindow.cpp.
References mad_mage_user::file, is_valid_types_gen::line, give::name, python_init::path, and quests.
Referenced by CREMainWindow::onReportQuests().
Definition at line 1227 of file CREMainWindow.cpp.
References curse_on_apply::ac, liv::ac, archt::clone, liv::dam, obj::dam_modifier, obj::duration, obj::duration_modifier, FABS, liv::hp, obj::level, level, MIN, give::name, object_get_value(), obj::range_modifier, report::report(), obj::speed, sstring, obj::stats, and liv::wc.
Referenced by CREMainWindow::onReportSummon().
|
static |
Definition at line 874 of file CREMainWindow.cpp.
References AssetsManager::archetypes(), archt::clone, AssetsCollection< T, Key >::each(), getManager(), level, levels, report::report(), obj::skill, SPELL, spell_arrow::spells, and obj::type.
Referenced by CREMainWindow::onReportSpells().