We're trying to make a weapon have a stun chance on melee attack, but cannot find the correct syntax for the component. For example:
{
class = "MeleeAttack",
name = "slash",
uiName = "Power Slash",
energyCost = 25,
pierce = 15,
attackPower = 32,
--stunChance = 80,
buildup = 2,
cooldown = 6,
swipe = "horizontal",
attackSound = "swipe_heavy",
gameEffect = "Buildup: 2 seconds",
},
stunChance = 80, of course, does nothing. What would be the correct code?
Stun in "Melee Attack"
- David Ward
- Posts: 103
- Joined: Wed Jan 07, 2015 11:44 pm
- Location: Vancouver, BC, Canada
Re: Stun in "Melee Attack"
causeCondition = "stunned",
conditionChance = 80,
conditionChance = 80,
Grimrock 1 dungeon
Grimrock 2 resources
I no longer answer scripting questions in private messages. Please ask in a forum topic or this Discord server.
Grimrock 2 resources
I no longer answer scripting questions in private messages. Please ask in a forum topic or this Discord server.
- David Ward
- Posts: 103
- Joined: Wed Jan 07, 2015 11:44 pm
- Location: Vancouver, BC, Canada
Re: Stun in "Melee Attack"
TY minmay.
Is there a way to change how long a stun effect will last?
Is there a way to change how long a stun effect will last?
Re: Stun in "Melee Attack"
using MonsterComponent:setCondition("stun",30) or whatever in the onHitMonster hook should work
Grimrock 1 dungeon
Grimrock 2 resources
I no longer answer scripting questions in private messages. Please ask in a forum topic or this Discord server.
Grimrock 2 resources
I no longer answer scripting questions in private messages. Please ask in a forum topic or this Discord server.
- David Ward
- Posts: 103
- Joined: Wed Jan 07, 2015 11:44 pm
- Location: Vancouver, BC, Canada
Re: Stun in "Melee Attack"
cheers