X-Git-Url: http://git.localhorst.tv/?a=blobdiff_plain;f=src%2Fmain.cpp;h=daeb3c4e1441f219e4fa78a6907e95cf8a64681f;hb=215260d3f49f6bbeed7ee5f5f1da3a5ac4ecc111;hp=662e5b901974b2995720f27cfca4b4e2acb7d61f;hpb=85627d7f6d436d88de87c85530dbceeb0a9bf22a;p=l2e.git diff --git a/src/main.cpp b/src/main.cpp index 662e5b9..daeb3c4 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -74,8 +74,6 @@ int main(int argc, char **argv) { const int width = 800; const int height = 480; - const int framerate = 33; - // std::srand(std::time(0)); try { @@ -130,7 +128,7 @@ int main(int argc, char **argv) { battleRes.activeHeroTagFrame = intp.GetFrame("activeHeroTagFrame"); battleRes.smallHeroTagFrame = intp.GetFrame("smallHeroTagFrame"); battleRes.lastSmallHeroTagFrame = intp.GetFrame("lastSmallHeroTagFrame"); - battleRes.heroesBgColor = SDL_MapRGB(screen.Screen()->format, 0x18, 0x28, 0x31); + battleRes.heroesBgColor = intp.GetColor("heroesBgColor").MapRGB(screen.Screen()->format); battleRes.healthGauge = intp.GetGauge("healthGauge"); battleRes.manaGauge = intp.GetGauge("manaGauge"); @@ -185,10 +183,6 @@ int main(int argc, char **argv) { battleRes.itemMenuHeadline = intp.GetString("itemMenuHeadline"); battleRes.itemMenuPrototype = Menu(intp.GetFont("normalFont"), intp.GetFont("disabledFont"), intp.GetSprite("handCursor"), 15, 6, 8, 16, 1, 32, 2, ':'); - SDL_Surface *swordAttackImg(IMG_Load("test-data/attack-sword.png")); - Sprite swordAttackSprite(swordAttackImg, 96, 96); - SimpleAnimation swordAttackAnimation(&swordAttackSprite, 2 * framerate, 4); - maxim.SetWeapon(intp.GetItem("zircoSwordItem")); maxim.SetArmor(intp.GetItem("zirconArmorItem")); maxim.SetShield(intp.GetItem("holyShieldItem")); @@ -218,11 +212,10 @@ int main(int argc, char **argv) { dekar.SetRing(intp.GetItem("rocketRingItem")); dekar.SetJewel(intp.GetItem("krakenRockItem")); - battleRes.ikariMenuHeadline = "Please choose equipment."; - battleRes.noEquipmentText = "No equip"; + battleRes.ikariMenuHeadline = intp.GetString("ikariMenuHeadline"); + battleRes.noEquipmentText = intp.GetString("noEquipmentText"); battleRes.ikariMenuPrototype = Menu(intp.GetFont("normalFont"), intp.GetFont("disabledFont"), intp.GetSprite("handCursor"), 12, 6, intp.GetFont("normalFont")->CharHeight() / 2, intp.GetFont("normalFont")->CharWidth(), 1, intp.GetFont("normalFont")->CharWidth() * 2, 0, ':', 12, intp.GetFont("normalFont")->CharWidth()); - - battleRes.escapeText = "Escapes."; + battleRes.escapeText = intp.GetString("escapeText"); BattleState *battleState(new BattleState(bg, monstersLayout, heroesLayout, &battleRes)); battleState->AddMonster(monster);