Editing EDF item effects and inventory
From Eternity Wiki
Jump to navigationJump to search
The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then publish the changes below to finish undoing the edit.
Latest revision | Your text | ||
Line 1: | Line 1: | ||
Define what happens when an item is picked up and used (and eventually, dropped from the inventory - this is not complete yet). A tutorial on defining each of these can be found at [[Creating a pickup]]. | Define what happens when an item is picked up and used (and eventually, dropped from the inventory - this is not complete yet). A tutorial on defining each of these can be found at [[Creating a pickup]]. | ||
== | ==Sprite-triggered pick-ups== | ||
===pickupeffect=== | ===pickupeffect=== | ||
Defines what happens when player picks up an item with the '''SPECIAL''' [[Thing type flags|flag]]. Commonly in DOOM and Heretic, pick-up effects are associated with the visual sprites of the things, instead of being mapped directly to the thing class. | Defines what happens when player picks up an item with the '''SPECIAL''' [[Thing type flags|flag]]. Commonly in DOOM and Heretic, pick-up effects are associated with the visual sprites of the things, instead of being mapped directly to the thing class. | ||
Line 28: | Line 8: | ||
pickupeffect <name> | pickupeffect <name> | ||
{ | { | ||
sprite < | sprite <str> | ||
effects < | effects <str>, ... | ||
flags < | flags <str> | ||
changeweapon < | changeweapon <str> | ||
message < | message <str> | ||
sound < | sound <str> | ||
} | } | ||
====Explanation of fields==== | ====Explanation of fields==== | ||
*'''sprite''' | *'''sprite''' | ||
:Default: | :Default: do not use sprite. | ||
:If set as a four-character sprite name, this will associate any [[thingtype]] with the '''SPECIAL''' [[Thing type flags|flag]] whose current sprite shows as this value to trigger this '''pickupeffect'''. | :If set as a four-character sprite name, this will associate any [[thingtype]] with the '''SPECIAL''' [[Thing type flags|flag]] whose current sprite shows as this value to trigger this '''pickupeffect'''. | ||
:Example: <code>sprite BON1</code> | :Example: <code>sprite BON1</code> | ||
Line 55: | Line 35: | ||
*'''changeweapon''' | *'''changeweapon''' | ||
:Default: nothing. | :Default: nothing. | ||
:If set, causes the item to change player's current weapon to the designated one whenever picked up | :If set, causes the item to change player's current weapon to the designated one whenever picked up. This is based on how the [[Doom Wiki:Berserk|Berserk pack]] acts in DOOM. | ||
:Example: <code>changeweapon Fist</code> | :Example: <code>changeweapon Fist</code> | ||
*'''message''' | *'''message''' | ||
Line 71: | Line 51: | ||
From a '''pickupeffect''''s '''effects''' field, one can add from many different types of item effect definitions: | From a '''pickupeffect''''s '''effects''' field, one can add from many different types of item effect definitions: | ||
===artifact=== | |||
An artifact is an item which, when collected, goes into the player's inventory. | An artifact is an item which, when collected, goes into the player's inventory. | ||
Line 105: | Line 83: | ||
ammo.backpackmaxamount <int> // max amount after collecting a Backpack | ammo.backpackmaxamount <int> // max amount after collecting a Backpack | ||
} | } | ||
===healtheffect=== | |||
A health effect gives the player health in one of many possible ways. | A health effect gives the player health in one of many possible ways. | ||
healtheffect <name> | healtheffect <name> | ||
Line 118: | Line 96: | ||
} | } | ||
===armoreffect=== | |||
An armor effect defines the properties of player armor | An armor effect defines the properties of player armor | ||
armoreffect <name> | armoreffect <name> | ||
Line 132: | Line 110: | ||
[+-]setabsorption // if +, sets absorption values (savefactor & savedivisor) | [+-]setabsorption // if +, sets absorption values (savefactor & savedivisor) | ||
} | } | ||
===ammoeffect=== | |||
Ammo givers give an Ammo type artifact to the player. | Ammo givers give an Ammo type artifact to the player. | ||
ammoeffect <name> | ammoeffect <name> | ||
Line 142: | Line 120: | ||
[+-]ignoreskill // if +, does not double on skills that give double ammo | [+-]ignoreskill // if +, does not double on skills that give double ammo | ||
} | } | ||
Power givers | ===powereffect=== | ||
Power givers give a power to the player. | |||
powereffect <name> | powereffect <name> | ||
{ | { | ||
Line 153: | Line 132: | ||
[+-]overridesself // if +, getting the power again while still under its influence is allowed | [+-]overridesself // if +, getting the power again while still under its influence is allowed | ||
} | } | ||
===weapongiver=== | |||
Weapon givers give a Weapon type artifact to the player, and optionally any number of Ammo artifact types. | Weapon givers give a Weapon type artifact to the player, and optionally any number of Ammo artifact types. | ||
weapongiver <name> | weapongiver <name> | ||
Line 179: | Line 143: | ||
} | } | ||
==Delta structures== | |||
The following can be used to replace already defined effects. They can be cascaded (i.e. any number of loaded mods can change the previous definition and all its deltas). For each of them, the '''name''' field represents the name of the base to modify. They are the following: | The following can be used to replace already defined effects. They can be cascaded (i.e. any number of loaded mods can change the previous definition and all its deltas). For each of them, the '''name''' field represents the name of the base to modify. They are the following: | ||
healthdelta | healthdelta |