Author Topic: Skill Check XP  (Read 344 times)

Legacy_AstoundingArcaneArcher

  • Jr. Member
  • **
  • Posts: 64
  • Karma: +0/-0
Skill Check XP
« on: September 17, 2011, 07:42:35 pm »


               Riiiight. After a hearty supper of homemade chicken and mushroom pie, I had a thought: can there be a script that awards XP for sucessful skill checks on the OnUserDefined script slot on the module properities. I've tried Scarface's XP/GP System V2.1 but the it only affects XP awarded for killing enemies.

So, any suggestions?

Thanks, as always,

AstoundingArcaneArcher
               
               

               
            

Legacy_Shadooow

  • Hero Member
  • *****
  • Posts: 7698
  • Karma: +0/-0
Skill Check XP
« Reply #1 on: September 17, 2011, 08:13:45 pm »


               SkillCheck by default doesnt trigger module user defined, also since you want this for player you would have to store player on module before calling userdefined anyway therefore is better not use user defined at all in this case and create a custom skill check function that will give a XP to the player doing this skill check

show me one script where is skill check and tell me either exact ammount of XP or some global formula and I will make it for you
               
               

               
            

Legacy__Guile

  • Hero Member
  • *****
  • Posts: 1308
  • Karma: +0/-0
Skill Check XP
« Reply #2 on: September 17, 2011, 08:20:12 pm »


               XP would be awarded in the OnUnlock / OnDisarm (for traps) Event for doors/chest/etc..

In conversation you would just do a skillcheck as a starting conditional script, if they pass, they would recieve the XP you desired to give for said skill check..
Example Conversation

[Use Skill] PC States they will attempt a skill
    []
    [] This line shows if they succeed (starting conditional script required, note you reward XP from this script!)
    [] This line shows if they failed (no reward, no scripts required)

Here is a basic Starting Conditional Skill Check (DC 15 for Persuade) w/ a 2d20 + 10 XP Award
------------------------
//////////////////////////////////////////////////////
//**Settings**

//Set this to the Consant of the skill you will be checking
int nSkill = SKILL_PERSUADE;

//Set this to the DC of the skill check
int nDC = 15;

//Set this to how much XP you wish to reward the PC if they succeed
int nXP = d20(2) + 10;   // (2d20 + 10 XP)

/////////////////////////////////////////////////////
//Main Script  (Do Not Alter!)
int StartingConditional()
{
    object oPC = GetPCSpeaker();
    if (  d20() + GetSkillRank(nSkill, oPC) < nDC )
    {    return FALSE;    }
     else
    {      GiveXPToCreature(oPC, nXP);
           return TRUE;    }
}
----------------------------------
Also you can use a tracks trigger to do specific skill checks, like search / spot etc, awarding them if successful..

Mostly rogues should get rewards for Picking Pockets / Opening Locks / Disarming Traps, finding hidden objects etc....  You would probably have to make a special script to check picking pockets, that's going to be tough to do, don't know if I can help you there..

The others are so easy you can use the script generator to make them.
               
               

               


                     Modifié par _Guile, 17 septembre 2011 - 11:03 .