I decided to try to learn how to write Yankes scripts, at least at basic level, so here is my trial release (many thanks to ohartenstein23 for his invaluable help in understanding). This script allows you to set the weapon property (tag) to change the characteristics of the target, which hit the weapon. Stats will be changed to the end of the battle. For example, you can make a blinding gun, lowering Firing, or stim enjector, increasing TUs and, say, Bravery =)
all you need is to define tags in your item, like that:
items:
- type: STR_BUFFER
#categories: [STR_EQUIPMENT]
size: 0.2
costBuy: 10
costSell: 8925
weight: 9
bigSprite: 8585
floorSprite: 8586
bulletSprite: 31
fireSound: 15
power: 5 #there must be a hit event to act the script
damageType: 3
damageAlter:
ToHealth: 0.0
clipSize: -1
accuracyAimed: 110
tuAimed: 15
battleType: 1
twoHanded: false
invWidth: 1
invHeight: 2
recoveryPoints: 2
armor: 10
attraction: 4
listOrder: 39101
tags: #here buff values can be set
FTAG_BUFF_VALUE_TIMEUNITS: 20 #remember add renewable resources to damage alter if positive. this will only affect maximum value, not current
FTAG_BUFF_VALUE_STAMINA: 20
FTAG_BUFF_VALUE_HEALTH: 0
FTAG_BUFF_VALUE_BRAVERY: -20 #negative means debuff
FTAG_BUFF_VALUE_REACTIONS: 20
FTAG_BUFF_VALUE_FIRING: 20
FTAG_BUFF_VALUE_THROWING: 20
FTAG_BUFF_VALUE_MELEE: 20
FTAG_BUFF_VALUE_STRENGTH: 20
FTAG_BUFF_VALUE_PSISTRENGTH: 20
FTAG_BUFF_VALUE_PSISKILL: 20
I will be glad to know what do you think about it. Also any advice is very welcome