Checking a player's skill to preform task

For all talk about quests. Creating, testing, bugs, and development progress.
User avatar
Kamer
Posts: 282
Joined: Mon Mar 05, 2018 9:26 pm

Checking a player's skill to preform task

Post by Kamer » Thu May 31, 2018 2:14 am

Is there a way to do this yet? I'd like to implement a check of the pc's Orcish skill to determine whether a task will be preformed.

User avatar
Interkarma
Posts: 4433
Joined: Sun Mar 22, 2015 1:51 am

Re: Checking a player's skill to preform task

Post by Interkarma » Thu May 31, 2018 2:20 am

Hazelnut added the following trigger condition a little while back. It should work in current builds.

Code: Select all

when skill skillName is at least minSkillValue
Skill names are matched to DFCareer.Skills enum. So you can use one of the following (can ignore number, just use text name). I believe it will be case sensitive as well.

Code: Select all

        public enum Skills
        {
            None = -1,
            Medical = 0,
            Etiquette = 1,
            Streetwise = 2,
            Jumping = 3,
            Orcish = 4,
            Harpy = 5,
            Giantish = 6,
            Dragonish = 7,
            Nymph = 8,
            Daedric = 9,
            Spriggan = 10,
            Centaurian = 11,
            Impish = 12,
            Lockpicking = 13,
            Mercantile = 14,
            Pickpocket = 15,
            Stealth = 16,
            Swimming = 17,
            Climbing = 18,
            Backstabbing = 19,
            Dodging = 20,
            Running = 21,
            Destruction = 22,
            Restoration = 23,
            Illusion = 24,
            Alteration = 25,
            Thaumaturgy = 26,
            Mysticism = 27,
            ShortBlade = 28,
            LongBlade = 29,
            HandToHand = 30,
            Axe = 31,
            BluntWeapon = 32,
            Archery = 33,
            CriticalStrike = 34,
        }

User avatar
Jay_H
Posts: 2200
Joined: Tue Aug 25, 2015 1:54 am

Re: Checking a player's skill to preform task

Post by Jay_H » Thu May 31, 2018 4:35 am

I'm currently running it in a quest I made:

Code: Select all

_sneak_ task:
	when skill Stealth is at least 70

_safeentry_ task:
	when _ires_ and _sneak_ and _2place_
	say 1019

_nosafe_ task:
	when _ires_ and not _sneak_ and _2place_
	say 1020
	create foe _enemy2_ every 600 minutes indefinitely with 75% success
Hazelnut wrote the prime example of it for the Archaeologists mod:

Code: Select all

_S.02_ task:
	clicked item _text_ 
	_text_ used saying 1020 do _read_ 
	say 1040

variable _read_
_S.03_ task:
    when not _orcish_ and _read_
    say 1045
	create foe _imps_ every 1 minutes 1 times with 100% success

_safeRead_ task:
    when _orcish_ and _read_
    say 1041

_orcish_ task:
    when skill Orcish is at least 70
Come join the Unofficial Daggerfall Unity Discord.
Try the first Daggerfall Unity Quest Pack with roughly 200 all-new quests.
Progress on fixing classic quests here.

User avatar
Kamer
Posts: 282
Joined: Mon Mar 05, 2018 9:26 pm

Re: Checking a player's skill to preform task

Post by Kamer » Fri Mar 08, 2019 9:47 pm

This is a bump but is similar to my original question. However I was wondering if you could check stats as well like strength?

User avatar
Hazelnut
Posts: 1252
Joined: Sat Aug 26, 2017 2:46 pm
Contact:

Re: Checking a player's skill to preform task

Post by Hazelnut » Sun Mar 10, 2019 5:29 pm

I don't think you can do a stat check, JayH should know. If not it will be really easy to add a new action for it.

User avatar
Jay_H
Posts: 2200
Joined: Tue Aug 25, 2015 1:54 am

Re: Checking a player's skill to preform task

Post by Jay_H » Mon Mar 11, 2019 7:07 am

Indeed, attributes have no checking condition for now.
Come join the Unofficial Daggerfall Unity Discord.
Try the first Daggerfall Unity Quest Pack with roughly 200 all-new quests.
Progress on fixing classic quests here.

User avatar
Kamer
Posts: 282
Joined: Mon Mar 05, 2018 9:26 pm

Re: Checking a player's skill to preform task

Post by Kamer » Mon Mar 11, 2019 8:54 pm

If we could get those, that'd be sweet.

User avatar
Interkarma
Posts: 4433
Joined: Sun Mar 22, 2015 1:51 am

Re: Checking a player's skill to preform task

Post by Interkarma » Mon Mar 18, 2019 8:34 pm

I'm adding a skill and attribute check quest action ahead of next builds. :)

User avatar
Kamer
Posts: 282
Joined: Mon Mar 05, 2018 9:26 pm

Re: Checking a player's skill to preform task

Post by Kamer » Tue Mar 19, 2019 5:48 am

Interkarma wrote:
Mon Mar 18, 2019 8:34 pm
I'm adding a skill and attribute check quest action ahead of next builds. :)
We already have skill checks don't we?

User avatar
Interkarma
Posts: 4433
Joined: Sun Mar 22, 2015 1:51 am

Re: Checking a player's skill to preform task

Post by Interkarma » Tue Mar 19, 2019 6:43 am

Yes that was rather unclear. What I meant was I'm adding support for attribute checks similar to skill checks.

I've barely slept in two days, things can get a bit jumbled. :oops:

Post Reply