From 9bfb1ecddf0274cc23b27b16ef800cf6cca47ed2 Mon Sep 17 00:00:00 2001 From: Zeno Rogue Date: Thu, 4 Jan 2018 15:46:06 +0100 Subject: [PATCH] graphics/theming for Jelly/Ruins --- classes.cpp | 10 +++++----- graph.cpp | 55 +++++++++++++++++++++++++++------------------------- polygons.cpp | 15 +++++++++++--- 3 files changed, 46 insertions(+), 34 deletions(-) diff --git a/classes.cpp b/classes.cpp index 98767353..0022e8e9 100644 --- a/classes.cpp +++ b/classes.cpp @@ -764,8 +764,8 @@ monstertype minf[motypes] = { { 'A', 0x80B080, "Green Raider", NODESCYET}, { 'M', 0x904000, "Brown Raider", NODESCYET}, { 'C', 0x0060E0, "Blue Raider", NODESCYET}, - { '@', 0xC00000, "Switcher A", NODESCYET}, - { '@', 0x0000C0, "Switcher B", NODESCYET}, + { '@', 0xC00000, "Red Jelly", NODESCYET}, + { '@', 0x0000C0, "Blue Jelly", NODESCYET}, // shmup specials { '@', 0xC0C0C0, "Rogue", "In the Shoot'em Up mode, you are armed with thrown Knives."}, @@ -1212,11 +1212,11 @@ itemtype iinf[ittypes] = { "Does not affect multi-tile monsters."}, { '!', 0x80FF00, "Glowing Crystal", crystaldesc}, { '!', 0x80FF80, "Snake Oil", NODESCYET}, - { '*', 0x80FF80, "Sea Glass", NODESCYET}, + { '!', 0x80FF80, "Sea Glass", NODESCYET}, { '*', 0xBBCC99, "Chrysoberyl", NODESCYET}, // { '*', 0xD0D8ED, "Chalcedony", NODESCYET}, { '*', 0x80FF80, "Monopole", NODESCYET}, - { '*', 0xFF00FF, "Agate", NODESCYET}, + { '!', 0xFF00FF, "Tasty Jelly", NODESCYET}, { 'o', 0x80FF80, "Orb of Phasing", NODESCYET}, { 'o', 0xFFFF80, "Orb of Magnetism", NODESCYET}, { 'o', 0x202020, "Orb of Slaying", NODESCYET}, @@ -1590,7 +1590,7 @@ const landtype linf[landtypes] = { { 0x80FF00, "Docks", NODESCYET}, { 0x306030, "Ruined City", NODESCYET}, { 0x306030, "Magnetosphere", NODESCYET}, - { 0x306030, "Switch", NODESCYET}, + { 0x306030, "Jelly Kingdom", NODESCYET}, }; struct landtacinfo { eLand l; int tries, multiplier; }; diff --git a/graph.cpp b/graph.cpp index 13b7bd3b..986c4d4e 100644 --- a/graph.cpp +++ b/graph.cpp @@ -664,7 +664,7 @@ bool drawItemType(eItem it, cell *c, const transmatrix& V, int icol, int ticks, if(it == itZebra) icol = 0xFFFFFF; if(it == itLotus) icol = 0x101010; - if(it == itSwitch) icol = minf[passive_switch].color; + if(it == itSwitch) icol = minf[active_switch()].color; transmatrix V2 = V * spin(ticks / 1500.); @@ -679,8 +679,8 @@ bool drawItemType(eItem it, cell *c, const transmatrix& V, int icol, int ticks, if(it == itZebra) queuepolyat(V * spin(ticks / 1500. + M_PI/(ct6+6)), *xsh, darkena(0x202020, 0, hidden ? 0x40 : 0xF0), PPR_ITEMb); - if(it == itSwitch) - queuepolyat(V * spin(ticks / 1500. + M_PI/(ct6+6)), *xsh, darkena(minf[active_switch()].color, 0, hidden ? 0x40 : 0xF0), PPR_ITEMb); + /* if(it == itSwitch) + queuepolyat(V * spin(ticks / 1500. + M_PI/S3), *xsh, darkena(minf[active_switch()].color, 0, hidden ? 0x40 : 0xF0), PPR_ITEMb); */ } else if(xch == 'o' || it == itInventory) { @@ -1220,32 +1220,30 @@ bool drawMonsterType(eMonster m, cell *where, const transmatrix& V, int col, dou if(!peace::on) queuepoly(VBODY, shPSword, 0xFFFF00FF); queuepoly(VHEAD, shHood, 0xD0D000C0); } - else if(isSwitch(m)) { + /* else if(isSwitch(m)) { otherbodyparts(V, darkena(col, 0, 0xC0), m, footphase); ShadowV(V, shPBody); queuepoly(VBODY, shPBody, darkena(col, 0, 0xC0)); if(!peace::on) queuepoly(VBODY, shPSword, 0xFFFF00FF); queuepoly(VHEAD, shHood, darkena(col, 0, 0xFF)); - } + } */ else if(m == moMonk) { otherbodyparts(V, darkena(col, 0, 0xC0), m, footphase); - ShadowV(V, shPBody); - queuepoly(VBODY, shPBody, darkena(col, 0, 0xC0)); + ShadowV(V, shRaiderBody); + queuepoly(VBODY, shRaiderBody, darkena(col, 0, 0xFF)); + queuepoly(VBODY, shRaiderShirt, darkena(col, 2, 0xFF)); if(!peace::on) queuepoly(VBODY, shPKnife, 0xFFC0C0C0); - queuepoly(VBODY, shTerraArmor1, darkena(col, 1, 0xFF)); - queuepoly(VBODY, shTerraArmor2, darkena(col, 0, 0xFF)); - queuepoly(VBODY, shTerraArmor3, darkena(col, 1, 0xFF)); + queuepoly(VBODY, shRaiderArmor, darkena(col, 1, 0xFF)); queuepolyat(VBODY, shRatCape2, darkena(col, 2, 0xFF), PPR_MONSTER_ARMOR0); queuepoly(VHEAD, shRaiderHelmet, darkena(col, 0, 0XFF)); queuepoly(VHEAD, shPFace, darkena(0xC0C0A0, 0, 0XFF)); } else if(m == moCrusher) { otherbodyparts(V, darkena(col, 1, 0xFF), m, footphase); - ShadowV(V, shPBody); - queuepoly(VBODY, shPBody, darkena(col, 0, 0xFF)); - queuepoly(VBODY, shTerraArmor1, darkena(col, 1, 0xFF)); - queuepoly(VBODY, shTerraArmor2, darkena(col, 0, 0xFF)); - queuepoly(VBODY, shTerraArmor3, darkena(col, 1, 0xFF)); + ShadowV(V, shRaiderBody); + queuepoly(VBODY, shRaiderBody, darkena(col, 0, 0xFF)); + queuepoly(VBODY, shRaiderShirt, darkena(col, 2, 0xFF)); + queuepoly(VBODY, shRaiderArmor, darkena(col, 1, 0xFF)); queuepoly(VBODY, shFlailTrunk, darkena(col, 1, 0XFF)); queuepoly(VBODY, shHammerHead, darkena(col, 0, 0XFF)); queuepoly(VHEAD, shRaiderHelmet, darkena(col, 0, 0XFF)); @@ -1253,22 +1251,20 @@ bool drawMonsterType(eMonster m, cell *where, const transmatrix& V, int col, dou } else if(m == moPair) { otherbodyparts(V, darkena(col, 1, 0xFF), m, footphase); - ShadowV(V, shPBody); - queuepoly(VBODY, shPBody, darkena(col, 0, 0xC0)); - queuepoly(VBODY, shTerraArmor1, darkena(col, 1, 0xFF)); - queuepoly(VBODY, shTerraArmor2, darkena(col, 0, 0xFF)); - queuepoly(VBODY, shTerraArmor3, darkena(col, 1, 0xFF)); + ShadowV(V, shRaiderBody); + queuepoly(VBODY, shRaiderBody, darkena(col, 0, 0xFF)); + queuepoly(VBODY, shRaiderShirt, darkena(col, 2, 0xFF)); + queuepoly(VBODY, shRaiderArmor, darkena(col, 1, 0xFF)); queuepoly(VBODY, shPickAxe, darkena(0xA0A0A0, 0, 0XFF)); queuepoly(VHEAD, shRaiderHelmet, darkena(col, 0, 0XFF)); queuepoly(VHEAD, shPFace, darkena(0xC0C0A0, 0, 0XFF)); } else if(m == moAltDemon || m == moHexDemon) { otherbodyparts(V, darkena(col, 0, 0xC0), m, footphase); - ShadowV(V, shPBody); - queuepoly(VBODY, shPBody, darkena(col, 0, 0xC0)); - queuepoly(VBODY, shTerraArmor1, darkena(col, 1, 0xFF)); - queuepoly(VBODY, shTerraArmor2, darkena(col, 0, 0xFF)); - queuepoly(VBODY, shTerraArmor3, darkena(col, 1, 0xFF)); + ShadowV(V, shRaiderBody); + queuepoly(VBODY, shRaiderBody, darkena(col, 0, 0xFF)); + queuepoly(VBODY, shRaiderShirt, darkena(col, 2, 0xFF)); + queuepoly(VBODY, shRaiderArmor, darkena(col, 1, 0xFF)); if(!peace::on) queuepoly(VBODY, shPSword, 0xFFD0D0D0); queuepoly(VHEAD, shRaiderHelmet, darkena(col, 0, 0XFF)); queuepoly(VHEAD, shPFace, darkena(0xC0C0A0, 0, 0XFF)); @@ -1418,6 +1414,12 @@ bool drawMonsterType(eMonster m, cell *where, const transmatrix& V, int col, dou queuepoly(VFISH, shSlime, darkena(col, 0, 0x80)); queuepoly(VSLIMEEYE, shEyes, 0xFF); } + else if(isSwitch(m)) { + queuepoly(VFISH, shJelly, darkena(col, 0, 0xD0)); + queuepolyat(VBODY, shJelly, darkena(col, 0, 0xD0), PPR_MONSTER_BODY); + queuepolyat(VHEAD, shJelly, darkena(col, 0, 0xD0), PPR_MONSTER_HEAD); + queuepolyat(VHEAD, shEyes, 0xFF, PPR_MONSTER_HEAD); + } else if(m == moKrakenH) { queuepoly(VFISH, shKrakenHead, darkena(col, 0, 0xD0)); queuepoly(VFISH, shKrakenEye, 0xFFFFFFC0); @@ -1983,9 +1985,10 @@ bool drawMonster(const transmatrix& Vparam, int ct, cell *c, int col) { // also whatever in the lineview mode else if(isFriendly(c) || isBug(c) || (c->monst && conformal::on) || c->monst == moKrakenH || (isBull(c->monst) && c->mondir != NODIR) || c->monst == moButterfly || isMagneticPole(c->monst) || - isSwitch(c->monst)) { + isSwitch(c->monst) || c->monst == moPair) { if(c->monst == moKrakenH) Vs = Vb, nospins = nospinb; if(!nospins) Vs = Vs * ddspin(c, c->mondir, S42); + if(c->monst == moPair) Vs = Vs * xpush(-.12); if(isFriendly(c)) drawPlayerEffects(Vs, c, false); return drawMonsterTypeDH(m, c, Vs, col, darkhistory, footphase); } diff --git a/polygons.cpp b/polygons.cpp index ef81df37..c3c7ff08 100644 --- a/polygons.cpp +++ b/polygons.cpp @@ -1009,10 +1009,10 @@ hpcshape shArrow, shPHead, shPFace, shGolemhead, shHood, shArmor, shAztecHead, shAztecCap, - shSabre, shTurban1, shTurban2, shVikingHelmet, shRaiderHelmet, + shSabre, shTurban1, shTurban2, shVikingHelmet, shRaiderHelmet, shRaiderArmor, shRaiderBody, shRaiderShirt, shWestHat1, shWestHat2, shGunInHand, shKnightArmor, shKnightCloak, shWightCloak, - shGhost, shEyes, shSlime, shJoint, shWormHead, shTentHead, shShark, + shGhost, shEyes, shSlime, shJelly, shJoint, shWormHead, shTentHead, shShark, shHedgehogBlade, shHedgehogBladePlayer, shWolfBody, shWolfHead, shWolfLegs, shWolfEyes, shWolfFrontLeg, shWolfRearLeg, shWolfFrontPaw, shWolfRearPaw, @@ -1745,6 +1745,10 @@ void buildpolys() { for(int i=0; i<=S84; i++) hpcpush(ddi(i, crossf * (0.7 + .2 * sin(i * M_PI * 2 / S84 * 9))) * C0); + bshape(shJelly, 33); + for(int i=0; i<=S84; i++) + hpcpush(ddi(i, crossf * (0.4 + .03 * sin(i * M_PI * 2 / S84 * 7))) * C0); + bshape(shHeptaMarker, PPR_HEPTAMARK); for(int t=0; t<=S7; t++) hpcpush(ddi(t*S12, shexf*.2) * C0); @@ -2130,6 +2134,9 @@ void buildpolys() { bshape(shGunInHand, PPR_MONSTER_WPN, scalef, 121); bshape(shVikingHelmet, PPR_MONSTER_HAT0, scalef, 122); bshape(shRaiderHelmet, PPR_MONSTER_HAT0, scalef, 375); + bshape(shRaiderArmor, PPR_MONSTER_BODY, scalef, 380); + bshape(shRaiderBody, PPR_MONSTER_BODY, scalef, 381); + bshape(shRaiderShirt, PPR_MONSTER_BODY, scalef, 382); bshape(shHood, PPR_MONSTER_HAT0, scalef, 123); bshape(shPirateHood, PPR_MONSTER_HAT0, scalef, 125); bshape(shEyepatch, PPR_MONSTER_HAT1, scalef, 126); @@ -3441,7 +3448,9 @@ NEWSHAPE, 376, 1, 1, 0.202167,-0.134605, 0.204591,-0.145446, 0.192856,-0.139999, NEWSHAPE, 377, 6, 1, -0.206510,0.223410, 0.017622,0.231073, 0.048705,0.240382, 0.069206,0.259727, NEWSHAPE, 378, 7, 1, 0.349494,-0.088062, 0.159923,-0.228824, 0.145483,-0.260010, 0.142821,-0.290692, NEWSHAPE, 379, 7, 1, 0.649585,0.084560, 0.623391,0.075842, 0.599921,0.058309, 0.572892,0.035489, 0.552783,-0.024612, - +NEWSHAPE, 380, 1, 2, -0.157063,0.003936, -0.151414,0.044436, -0.065427,0.009052, -0.151414,0.044436, -0.151129,0.067964, -0.072440,0.024229, -0.150301,0.069258, -0.113069,0.110826, -0.037964,0.039249, -0.110463,0.109185, -0.011307,0.146227, -0.108855,0.111771, -0.113069,0.110826, -0.110452,0.155897, -0.007227,0.165082, -0.111749,0.156720, -0.114514,0.196200, 0.003252,0.188966, -0.009486,0.143350, 0.043508,0.083540, 0.057523,0.000604, +NEWSHAPE, 381, 1, 2, -0.128015,0.002500, -0.121343,0.106487, -0.104134,0.121999, -0.063293,0.274181, 0.038783,0.286293, 0.071085,0.292868, 0.087907,0.266956, 0.077475,0.243894, 0.083000,0.234337, 0.068629,0.220991, 0.042226,0.206757, 0.023044,0.227068, -0.009573,0.218873, -0.027348,0.140245, -0.005432,-0.096462, 0.020544,-0.030837, +NEWSHAPE, 382, 1, 2, 0.024784,0.028900, -0.009988,0.111744, -0.018320,0.147991, -0.006519,0.215354, 0.020083,0.223620, 0.029811,0.291799, -0.066579,0.278718, -0.136927,0.082023, -0.147101,-0.050084, NEWSHAPE };