Depends on what you mean. However, it undoubtedly involves scripting.
To give a creature such an ability, you can hardcode it into the creature script. There are several examples of this in the 4 basic scenarios.
Read the code for abilnpc (any) and t7maestro (Diplomacy with the Dead).
Special abilities for characters are coded into the scenario script. You initialize them in LOAD_SCEN_STATE, then you have them call a state later on for the actual ability. I know there's an example in the Za-Khazi Run.
For an item, you'll have to use the special item abilities which let them call scenario states. Then you script the ability, give your characters the item, cross your fingers and start debugging it. Babysitting contains some examples of this.
I hope this helps. Otherwise, you may find yourself digging through the appendix to find the calls you need. Good Luck.
EDIT: And, while I'm at it, I should welcome you to the boards here, SmirfOfDoom. So, Welcome.