I don't know what you're using, but the only compete reference (though complete for original DK, not including KeeperFX extensions) is here:
http://keeper.lubiki.pl/dk1_docs/dk_scripting_ref.htm
I don't know what you're using, but the only compete reference (though complete for original DK, not including KeeperFX extensions) is here:
http://keeper.lubiki.pl/dk1_docs/dk_scripting_ref.htm
That's exactly what i'm using, v1.3 and all. Somehow I only saw TOTAL_CREATURES_LEFT and not TOTAL_CREATURES. That + it came with Adikted so the thought it may have been outdated was sitting at the back of my mind the entire time. My mistake.
Originally the lost tentacles were in derelict prisons with collapsed roofs/walls and skeleton guards. It was supposed to show they had been gone for some time. Once the player rescued all the tentacles, the keeper would become an ally and help the player.
I've had to make some adjustments;
- Skeletons changed to regular humans. 'Story' changed to reflect that.
- Base has been repaired.
- Neutral Tentacles changed to imprisoned Keeper(AI) Tentacles.
- Allied Keeper portal removed.
My issue now is, how do I check if the player has rescued the tentacles? There's nothing that looks at 'Imprisoned' creatures, and they start off as the Keeper's(AI) so I can't use TOTAL_CREATURES.
I'm thinking i'll have to bottleneck the keeper base and add an action point that counts the number of times a Tentacle walks over it. Tentacles already in the base won't really wander around, they should just sleep most of the time, so it should only count the tentacles that are released from Prison and making their way back home.
But.. what if an enemy keeper instigates a fight and pulls a bunch of tentacles over the action point.
Or the friendly Keeper picks up a Tentacle that's been released from prison before it goes over the action point.
uh
I need to think about this.
------------------------
Well that was quick.
I'll just use;
since it can be assumed all tentacles have been rescued if all prisons have been claimed.Code:IF(PLAYER_GOOD,PRISON == 0)
Last edited by Woudo; June 18th, 2014 at 04:03.
Actually, you can.
I doubt it was like this from original DK, but in current KeeperFX, TOTAL_CREATURES counts only the creatures a player controls. Creatures kept by enemy (either in prison or torture chamber) are substracted from the amount.
Also - I don't think you could imprison a creature by putting it into a room at start in original DK. I fixed that just a few days ago.
Well i'm going through final testing of the level right now.
I originally had some archers on guard posts out by the river-side. Normally heroes with a direct path to a dungeon heart will attack it, but those archers stayed on the guard posts... somewhat. I had to remove them because any creature that got close enough for them to aggro no, 'woke them up'. I'm not sure if it was seeing the creature that woke them up or if it was them stepping off the guard post, but after that happened they'd stop guarding and seek out the player heart.
I'll quickly bum-rush the checking regarding the imprisoned tentacles.
---------------------------
Definitely worked. They were even making the adorable neck-waving motions from being imprisoned.
You said "A few days ago". I'm not using the nightly builds of Keeper FX which I guess would be why.
---------------------------
And uh, while you're here. There's a SET_ALLY option to make keepers friends. How do I undo that? For the most part the map is done, but I don't know how to unally one keeper from the other.
Last edited by Woudo; June 18th, 2014 at 18:34.
Have a look here for instructions in switching alliances on & off:
https://code.google.com/p/keeperfx/w...ScriptCommands
Dayo
Okay so what I have is;
P1,P2,P3 are all allied.Code:ALLY_PLAYERS(PLAYER1,PLAYER2) ALLY_PLAYERS(PLAYER1,PLAYER3) ALLY_PLAYERS(PLAYER2,PLAYER3) ALLY_PLAYERS(PLAYER0,PLAYER2)
P1,P2 are allied.
But I should be writing;
Code:REM ## Initial Alliance ## ALLY_PLAYERS(PLAYER1,PLAYER2,1) ALLY_PLAYERS(PLAYER1,PLAYER3,1) ALLY_PLAYERS(PLAYER2,PLAYER3,1) ALLY_PLAYERS(PLAYER0,PLAYER2,1)Solves the problem, thanks m8.Code:REM ## War was declared ## IF(WATER == WET) ALLY_PLAYERS(PLAYER3,PLAYER1,0) ALLY_PLAYERS(PLAYER3,PLAYER2,0) ENDIF