by Ultimate Freedoomer » Mon May 07, 2018 9:11 pm
Hi. I am here to propose a new thing special for DECORATE: "ArmorThing". Basically, this would function like HealThing, but with armor instead of health. A good use of this would be to create custom inventory items that use their own armor values without having to propose a new armor class just to allow such an item to give armor without interfering with armor class DeHacked patches. It would work as follows, in the following order:
- string "icon": the HUD icon to use for this actor's provided armor. Defaults to "arm1a0"
- percentage "savepercent": The percentage of dealt damage that the provided armor absorbs is specified as a floating point value between 0.0 and 100.0. Defaults to "33.335"
- amount "maxsaveamount": Sets the maximum amount of armor you can reach by picking up an item using this thing special. Defaults to "200"
- amount "saveamount": The amount of armor that an item using this thing special gives. Defaults to "1".
- amount "maxbonus": The amount of armor you obtain additionally to your save amount value. Defaults to "0"
- amount "maxbonusmax": The maximum additional save amount you can obtain with the armor. Defaults to "0".
- amount "MaxFullAbsorb": The amount of damage that the provided armor will fully absorb per tic. Defaults to "0".
- amount "MaxAbsorb": The maximum amount of damage (after adjustment) that the armor provided by an item using this thing special will absorb per tic. defaults to "0".
As an example, here's the Megasphere itself recreated using this setup to replace the custom blue armor token, as well as using HealThing to replace the special health token:
Code: Select all
Actor MegasphereCustom : CustomInventory replaces Megasphere 83
{
spawnid 132
+COUNTITEM
+INVENTORY.ALWAYSPICKUP
Inventory.Pickupmessage "$GOTMSPHERE"
Inventory.PickupSound "misc/p_pkup"
States
{
Spawn:
MEGA ABCD 6 Bright
loop
Pickup:
TNT1 A 0
{
ArmorThing("arm2a0",50,200,200,0,0,0,0);
HealThing(200,200);
}
stop
}
}
Another example: this item recreates the
Doom 3 incarnation of the backpack redone using ArmorThing:
Code: Select all
Actor PowerBackpack : CustomInventory
{
Inventory.PickupMessage "Picked up a Power backpack."
inventory.pickupsound "pickups/powerbackpack"
+INVENTORY.ALWAYSPICKUP
height 26
States
{
Spawn:
PBPK A -1
stop
Pickup:
TNT1 A 0
{
ArmorThing("arm2a0",33.33333,200,5,0,0,0,0);
HealThing(5,200);
A_GiveInventory("backpackitem", 1, AAPTR_DEFAULT);
}
stop
}
}
The Damage factors for custom damage (in the event the modder wishes to use such with ArmorThing) would be determined by the calling actor's "DamageFactor" property.
Hi. I am here to propose a new thing special for DECORATE: "ArmorThing". Basically, this would function like HealThing, but with armor instead of health. A good use of this would be to create custom inventory items that use their own armor values without having to propose a new armor class just to allow such an item to give armor without interfering with armor class DeHacked patches. It would work as follows, in the following order:[list][*]string "icon": the HUD icon to use for this actor's provided armor. Defaults to "arm1a0"[*]percentage "savepercent": The percentage of dealt damage that the provided armor absorbs is specified as a floating point value between 0.0 and 100.0. Defaults to "33.335"[*]amount "maxsaveamount": Sets the maximum amount of armor you can reach by picking up an item using this thing special. Defaults to "200"[*]amount "saveamount": The amount of armor that an item using this thing special gives. Defaults to "1".[*]amount "maxbonus": The amount of armor you obtain additionally to your save amount value. Defaults to "0"[*]amount "maxbonusmax": The maximum additional save amount you can obtain with the armor. Defaults to "0".[*]amount "MaxFullAbsorb": The amount of damage that the provided armor will fully absorb per tic. Defaults to "0".[*]amount "MaxAbsorb": The maximum amount of damage (after adjustment) that the armor provided by an item using this thing special will absorb per tic. defaults to "0".[/list]As an example, here's the Megasphere itself recreated using this setup to replace the custom blue armor token, as well as using HealThing to replace the special health token:[code]Actor MegasphereCustom : CustomInventory replaces Megasphere 83
{
spawnid 132
+COUNTITEM
+INVENTORY.ALWAYSPICKUP
Inventory.Pickupmessage "$GOTMSPHERE"
Inventory.PickupSound "misc/p_pkup"
States
{
Spawn:
MEGA ABCD 6 Bright
loop
Pickup:
TNT1 A 0
{
ArmorThing("arm2a0",50,200,200,0,0,0,0);
HealThing(200,200);
}
stop
}
}[/code]Another example: this item recreates the [i]Doom 3[/i] incarnation of the backpack redone using ArmorThing:[code]Actor PowerBackpack : CustomInventory
{
Inventory.PickupMessage "Picked up a Power backpack."
inventory.pickupsound "pickups/powerbackpack"
+INVENTORY.ALWAYSPICKUP
height 26
States
{
Spawn:
PBPK A -1
stop
Pickup:
TNT1 A 0
{
ArmorThing("arm2a0",33.33333,200,5,0,0,0,0);
HealThing(5,200);
A_GiveInventory("backpackitem", 1, AAPTR_DEFAULT);
}
stop
}
}[/code]The Damage factors for custom damage (in the event the modder wishes to use such with ArmorThing) would be determined by the calling actor's "DamageFactor" property.