special items

Error message

Deprecated function: implode(): Passing glue string after array is deprecated. Swap the parameters in drupal_get_feeds() (line 394 of /var/www/pied-piper.ermarian.net/includes/common.inc).
AuthorTopic: special items
Shock Trooper
Member # 4180
Profile #0
The docs for special items seem pretty skimpy (to say the least). :confused: Is it possible for the party to find a special item in, say, a crate (after killing the monster guarding it)? Or does it have to be granted programmatically?

If the former will work, how? I can't figure out how to place anything but regular items in the editor.

--------------------
-spyderbytes
Posts: 200 | Registered: Wednesday, March 31 2004 08:00
Apprentice
Member # 412
Profile #1
You could, for example, have the monster drop a "crate" (or have it created when the monster dies) which is actually an item, and which when opened (used) grants the special item.
Posts: 33 | Registered: Monday, December 17 2001 08:00
Triad Mage
Member # 7
Profile Homepage #2
Well, you'd have to give it to the party in a script. Generally, putting special items in crates and barrels is a bad idea because they can be pushed around, which would mean that your special node would sometimes be on a space without the crate. Using a chest or some sort of terrain would be better.

--------------------
"At times discretion should be thrown aside, and with the foolish we should play the fool." - Menander
====
Drakefyre's Demesne - Happy Happy Joy Joy
Encyclopedia Ermariana - Trapped in the Closet
====
You can take my Mac when you pry my cold, dead fingers off the mouse!
Posts: 9436 | Registered: Wednesday, September 19 2001 07:00
Shock Trooper
Member # 4180
Profile #3
quote:
Originally written by Drakefyre:

Well, you'd have to give it to the party in a script.
I knew I didn't see any other way, but I thought (hoped?) I might have been missing something. :)

quote:
Generally, putting special items in crates and barrels is a bad idea because they can be pushed around, which would mean that your special node would sometimes be on a space without the crate. Using a chest or some sort of terrain would be better.
Hmm... good point. I'm actually accomplishing pretty much exactly what I want with a normal ol' item right now. The only reason I was thinking of making it a special item is that it's the item necessary to complete a quest, and it looks like junk (actually it is... the scenario I'm working on is a lampoon of the worser variety of homegrown CRPGs ;) ).

It's basically just the jug item. But I made mine with an icon color shift and gave it a slightly different name, so maybe that will be good enough. I just didn't want the player leaving it behind or throwing it out because s/he thought it was junk if s/he stumbled across it before receiving the quest to "FedEx" it to the NPC too lazy to get it himself. :D

-spyderbytes

(edited for grammar)

[ Monday, April 05, 2004 01:03: Message edited by: spyderbytes ]

--------------------
-spyderbytes
Posts: 200 | Registered: Wednesday, March 31 2004 08:00
Warrior
Member # 4202
Profile Homepage #4
A common way to give special items that a monster is guarding is give it when the monster dies (You find a interesting looking jug on the monster). This would require a custom creature script for it, though.

--------------------
Creator of the 3D Blades of Avernum Editor for Mac. Get it at Ingenious Isaac's Illusion, my web page. Better yet, get Battle for Wesnoth, a wonderful free TBS game.
Posts: 192 | Registered: Sunday, April 4 2004 08:00
Triad Mage
Member # 7
Profile Homepage #5
No it doesn't - you can call a state upon monster death.

--------------------
"At times discretion should be thrown aside, and with the foolish we should play the fool." - Menander
====
Drakefyre's Demesne - Happy Happy Joy Joy
Encyclopedia Ermariana - Trapped in the Closet
====
You can take my Mac when you pry my cold, dead fingers off the mouse!
Posts: 9436 | Registered: Wednesday, September 19 2001 07:00
Shock Trooper
Member # 4180
Profile #6
Actually, my jug-guardian spiders already have a custom script for some custom targeting AI, so that part isn't a problem. What was originally holding me up was trying to figure out how to give the special item when the last spider died, and not for each one (and that's why I wanted to place it in a nearby container, as I would a normal item).

But then I discovered friends_nearby, and now all's well with the world. :) I've changed it so I'm granting the special item when friends_nearby returns 0 (meaning all the others are already dead when this one dies). So, problem solved. :)

Thanks for the help!

-spyderbytes

--------------------
-spyderbytes
Posts: 200 | Registered: Wednesday, March 31 2004 08:00
Triad Mage
Member # 7
Profile Homepage #7
A safer way is to increment (or decrement) an SDF every time one dies, and when the flag reaches the number of monsters (or zero), then all are dead.

--------------------
"At times discretion should be thrown aside, and with the foolish we should play the fool." - Menander
====
Drakefyre's Demesne - Happy Happy Joy Joy
Encyclopedia Ermariana - Trapped in the Closet
====
You can take my Mac when you pry my cold, dead fingers off the mouse!
Posts: 9436 | Registered: Wednesday, September 19 2001 07:00
Shock Trooper
Member # 4180
Profile #8
I'm not sure I understand why that would be safer, at least as long as I'm sure (and I am) there's no chance of other hostiles nearby in this particular town. Am I missing something?

-spyderbytes

--------------------
-spyderbytes
Posts: 200 | Registered: Wednesday, March 31 2004 08:00
Triad Mage
Member # 7
Profile Homepage #9
When you get into the realm of summons, confusion, charming, etc. (and it can be items that do this, not just monsters), that call will not return the values that you intend it to. Also, when reusing the script, you'll want something that will work in all cases.

--------------------
"At times discretion should be thrown aside, and with the foolish we should play the fool." - Menander
====
Drakefyre's Demesne - Happy Happy Joy Joy
Encyclopedia Ermariana - Trapped in the Closet
====
You can take my Mac when you pry my cold, dead fingers off the mouse!
Posts: 9436 | Registered: Wednesday, September 19 2001 07:00
Shock Trooper
Member # 4180
Profile #10
Hmmm... good point, so I changed it. Thanks for the tip! :)

-spyderbytes

--------------------
-spyderbytes
Posts: 200 | Registered: Wednesday, March 31 2004 08:00