diff --git a/classes.cpp b/classes.cpp index ba87f453..b3d19540 100644 --- a/classes.cpp +++ b/classes.cpp @@ -479,6 +479,7 @@ static constexpr flagtype CF_FACE_UP = Flag(49); static constexpr flagtype CF_FACE_SIDE = Flag(50); static constexpr flagtype CF_HIGH_THREAT = Flag(51); static constexpr flagtype CF_SPAM = Flag(52); +static constexpr flagtype CF_FROG = Flag(53); enum eMonster { #define MONSTER(a,b,c,d,e,f,g,h) d, diff --git a/content.cpp b/content.cpp index 68d50310..852f5c9d 100644 --- a/content.cpp +++ b/content.cpp @@ -1616,17 +1616,17 @@ WALL( '#', 0x00C000, "shrub", waShrub, WF_WALL | WF_HIGHWALL | WF_STDTREE | WF_ "A strange small tree that cannot be attacked with mundane weapons nor phased though. " "It can be vaulted over, though." ) -MONSTER('F', 0x60A060, "Giant Frog", moFrog, CF_HIGH_THREAT, RESERVED, moFrog, +MONSTER('F', 0x60A060, "Giant Frog", moFrog, CF_HIGH_THREAT | CF_FROG, RESERVED, moFrog, "At first, you are shocked by the agility of this frog. Such a large creature " "should not be able to jump that quickly!\n\n" "Then, you notice the green glow around its legs. This frog must be magical... " "it has sacrificed its swimming abilities for superfrog jumping powers." ) -MONSTER('F', 0xFFFF80, "Yellow Frog", moPhaser, CF_HIGH_THREAT, RESERVED, moPhaser, +MONSTER('F', 0xFFFF80, "Yellow Frog", moPhaser, CF_HIGH_THREAT | CF_FROG, RESERVED, moPhaser, "A slightly transparent yellow frog. It has mastered the magical power of phasing through solid " "obstacles such as rock." ) -MONSTER('F', 0x8080FF, "Blue Frog", moVaulter, CF_HIGH_THREAT, RESERVED, moVaulter, +MONSTER('F', 0x8080FF, "Blue Frog", moVaulter, CF_HIGH_THREAT | CF_FROG, RESERVED, moVaulter, "This frog is able to vault over the shrubs in the Frog Park, destroying the shrub in the process. " "While it can also vault over monsters, it will never hurt the other frogs!" ) diff --git a/flags.cpp b/flags.cpp index 72c4c028..9a67b271 100644 --- a/flags.cpp +++ b/flags.cpp @@ -112,6 +112,7 @@ MONFLAGCHECK(isRatling, flag & CF_RATLING) MONFLAGCHECK(isGhostMover, flag & CF_GHOSTMOVER) MONFLAGCHECK(isPowerMonster, flag & CF_POWER) MONFLAGCHECK(hasFacing, flag & CF_FACING) +MONFLAGCHECK(isFrog, flag & CF_FROG) ITEMFLAGCHECK(isElementalShard, flag & IF_SHARD) ITEMFLAGCHECK(itemBurns, !(flag & IF_FIREPROOF)) diff --git a/help.cpp b/help.cpp index 1e36aa35..e5deaa90 100644 --- a/help.cpp +++ b/help.cpp @@ -705,8 +705,11 @@ EX string generateHelpForMonster(eMonster m) { } eItem it = frog_power(m); - if(it) + if(it) { s += XLAT("\n\nThis Frog uses the power of %the1. You get 5 charges yourself for killing it.", it); + + s += XLAT("\n\nFrogs move first, and after they use their jumping power, they stun adjacent non-frog monsters which are not friendly to the player for 2 turns."); + } if(m == moBat || m == moEagle) s += XLAT("\n\nFast flying creatures may attack or go against gravity only in their first move.", m); diff --git a/monstermove.cpp b/monstermove.cpp index 107b10f7..b37bd197 100644 --- a/monstermove.cpp +++ b/monstermove.cpp @@ -103,6 +103,13 @@ EX void moveEffect(const movei& mi, eMonster m) { animateMovement(mi.rev(), LAYER_BOAT); tortoise::move_baby(cf, ct); } + + if(isFrog(m) && !isNeighbor(cf, ct)) { + forCellEx(c1, ct) if(c1->monst && !isFrog(c1->monst) && !isFriendly(c1->monst)) { + c1->stuntime = min(c1->stuntime + 2, 7); + checkStunKill(c1); + } + } #if CAP_COMPLEX2 if(isDie(m) && mi.proper()) @@ -2050,6 +2057,13 @@ EX void movemonsters() { specialMoves(); + DEBB(DF_TURN, ("jumpers")); + if(havewhat & HF_JUMP) { + groupmove(moFrog, 0); + groupmove(moVaulter, 0); + groupmove(moPhaser, 0); + } + DEBB(DF_TURN, ("ghosts")); moveghosts(); @@ -2075,12 +2089,6 @@ EX void movemonsters() { if(havewhat & HF_EAGLES) groupmove(moEagle, MF_NOATTACKS | MF_ONLYEAGLE); DEBB(DF_TURN, ("eagles")); if(havewhat & HF_REPTILE) groupmove(moReptile, 0); - DEBB(DF_TURN, ("jumpers")); - if(havewhat & HF_JUMP) { - groupmove(moFrog, 0); - groupmove(moVaulter, 0); - groupmove(moPhaser, 0); - } DEBB(DF_TURN, ("air")); if(havewhat & HF_AIR) { airmap.clear();