Larian Banner: Baldur's Gate Patch 9
Previous Thread
Next Thread
Print Thread
#638253 03/12/17 10:54 AM
Joined: Nov 2017
Location: Ukraine
apprentice
OP Offline
apprentice
Joined: Nov 2017
Location: Ukraine
TASK: Make character deflect projectiles with a %chance.

Since i haven't found any possible way to do it with editor (could miss smth, but doubt it), dicided to try with scripting.

1 - Tried to find "Flags" param info from editor (immunities there mostly, but has a "deflecting" as well), where it is stored. Wanted to put "deflecting" part in some %chance wrap, but can't find any info in files.

2 - After fail with #1 tried to recreate it. And... decided to ask for an advice.

The only thing i can imagine is smth like:


EVENT
OnCharacterUsedSkillOnMe(CHARACTER:character, SKILL_ID:skillID)
IF "c1& "
IsProjectileSkill(SKILL:skill)
.....
THEN
ShootLocalProjectileAt(skill,source,,target)


...for all projectile skills in the game, without any idea how to include ranged auto attacks here.

Thought about deflecting after block - easier with call,
OnBlock(CHARACTER:source, ITEM:source, CHARACTER:target, ITEM:target)
but have no idea how to define target, let alone projectile_skill for action.

Any advice? Or may be there is a simple way to do that? smile

Joined: Oct 2017
journeyman
Offline
journeyman
Joined: Oct 2017
I think your best bet won't be to try to intercept a projectile and run a chance on it, but rather to make it so that every time you get hit by a projectile it'll do a roll which if it passes will deflect the next projectile, and if it doesn't pass then it won't deflect the next projectile.

I'll look into it when I get time.

Joined: Nov 2017
Location: Ukraine
apprentice
OP Offline
apprentice
Joined: Nov 2017
Location: Ukraine
Hm, interesting solution, not the 1 I wanted but still. The only problem is i have alot of invisible projectiles on half of the skills (for statuses or script calls), can be a mess smile

But in such a situation reflection is dangerous anyway, gues I'll have to write it from scratch if i plan to use it... Still have hopes to make it work only after block though.
For now it is in the end of my list as the most "problematic", but if you have any ideas will be glad to discuss it!


Link Copied to Clipboard
Powered by UBB.threads™ PHP Forum Software 7.7.5