NWN1 Blast from the ALFA past ... Level 4 Validation

This is a general open discussion for all ALFA, Neverwinter Nights, and Dungeons & Dragons topics.

Moderator: ALFA Administrators

Post Reply
User avatar
dergon darkhelm
Fionn In Disguise
Posts: 4258
Joined: Fri Jul 08, 2005 1:21 pm
Location: Cleveland, Ohio, United States

NWN1 Blast from the ALFA past ... Level 4 Validation

Post by dergon darkhelm »

Had forgotten all about that :)
PCs: NWN1: Trailyn "Wayfarer" Krast, Nashkel hayseed

NWN2: ??

gsid: merado_1
User avatar
Mick
Beholder
Posts: 1946
Joined: Mon May 30, 2005 2:19 am
Location: Why do you want to know?

Re: NWN1 Blast from the ALFA past ... Level 4 Validation

Post by Mick »

It was put in place to keep dirty PGers like you in check.

Also...congrats.
Talk less. Listen more.

Current PCs: ?
User avatar
ayergo
Penguin AKA Vile Sea Tiger
Posts: 3503
Joined: Sun Jan 11, 2004 8:50 pm
Location: Germany (But frequent world travels)

Re: NWN1 Blast from the ALFA past ... Level 4 Validation

Post by ayergo »

Dirtiest of the PGers!

I should have remembered about that because it messed with my testing a lot. I don't know at what point it changed but it used to only kick in at level 10 and I haven't been able to find the code for it.
There's a place I like to hide
A doorway that I run through in the night
Relax child, you were there
But only didn't realize and you were scared
It's a place where you will learn
To face your fears, retrace the years
And ride the whims of your mind
User avatar
Arianna
Tech Admin
Posts: 1660
Joined: Sat Jan 03, 2004 2:28 pm
Location: Idaho PST

Re: NWN1 Blast from the ALFA past ... Level 4 Validation

Post by Arianna »

ayergo wrote:Dirtiest of the PGers!

I should have remembered about that because it messed with my testing a lot. I don't know at what point it changed but it used to only kick in at level 10 and I haven't been able to find the code for it.
Its not in the onplayerlevelup part of the module scripts?
Current NWN2 PC: TSM- Lessa

HDM of Moonshae Server DM on BG
Builder Everywhere
DM times - 6:30-10 PM Saturdays PDT on MS . . other times as I show up
PM me on Discord if you want to be DMd on BG I have Monday nights available
Talk to me if you want to learn to build for NWN2

Tech Admin
User avatar
ayergo
Penguin AKA Vile Sea Tiger
Posts: 3503
Joined: Sun Jan 11, 2004 8:50 pm
Location: Germany (But frequent world travels)

Re: NWN1 Blast from the ALFA past ... Level 4 Validation

Post by ayergo »

Arianna wrote:
ayergo wrote:Dirtiest of the PGers!

I should have remembered about that because it messed with my testing a lot. I don't know at what point it changed but it used to only kick in at level 10 and I haven't been able to find the code for it.
Its not in the onplayerlevelup part of the module scripts?
Will dig in and see. Didn't expect to have such dedicated players!
There's a place I like to hide
A doorway that I run through in the night
Relax child, you were there
But only didn't realize and you were scared
It's a place where you will learn
To face your fears, retrace the years
And ride the whims of your mind
User avatar
Stormbringer
Owlbear
Posts: 587
Joined: Mon Jan 05, 2004 6:45 am
Location: USA GMT - 6

Re: NWN1 Blast from the ALFA past ... Level 4 Validation

Post by Stormbringer »

Need more areas to explore... The Rat hills are getting deadly with the super swarms and same with the sewers. Either more gold earned so we can better equip our toons or something needs to give. Would love to look into Daggerford server and see if it is worth hosting/fixing up. Maybe tie it into WD so peeps have other places to explore.
Current PC:
Former PC's
Saman Barb/Sorcerer
Kal Rogue/Ranger of Selune
Aiden Ketter Priest of Kelemvor
Kree (ubber not smart Barb)
Past PC: Jena Steel | Hamar Marrion (Marcus)and many other dead PC's
User avatar
ayergo
Penguin AKA Vile Sea Tiger
Posts: 3503
Joined: Sun Jan 11, 2004 8:50 pm
Location: Germany (But frequent world travels)

Re: NWN1 Blast from the ALFA past ... Level 4 Validation

Post by ayergo »

Stormbringer wrote:Need more areas to explore... The Rat hills are getting deadly with the super swarms and same with the sewers. Either more gold earned so we can better equip our toons or something needs to give. Would love to look into Daggerford server and see if it is worth hosting/fixing up. Maybe tie it into WD so peeps have other places to explore.
Agree 150% on that and I'm working on it. Give me until July 9th and I'll have some more content up and the sewers a bit more reasonable.

Am interested in wealth levels though, I have a few PCs that have done pretty well with the rat hills and not much has changed there recently. Can you post your experiences with rewards in the thread on the WD forums?
There's a place I like to hide
A doorway that I run through in the night
Relax child, you were there
But only didn't realize and you were scared
It's a place where you will learn
To face your fears, retrace the years
And ride the whims of your mind
User avatar
Arianna
Tech Admin
Posts: 1660
Joined: Sat Jan 03, 2004 2:28 pm
Location: Idaho PST

Re: NWN1 Blast from the ALFA past ... Level 4 Validation

Post by Arianna »

the script that controls the level validation is csm_onlvlup, unfortunately it is in the ahp_3.0_2da.hak

You may be able to override it by-

open your script editor , click all resources, find csm_onlelvlup , open it change line 25

from

if ( nLevel < 3 )

to

if ( nLevel < 10 )

save and compile, save mod. This places the script in the mod itself.

Removing the script would cause other scripts to fail

I think mod scripts overide hak scripts but not 100% certain on this
Ideally the hak script should be changed to conserve resources
Current NWN2 PC: TSM- Lessa

HDM of Moonshae Server DM on BG
Builder Everywhere
DM times - 6:30-10 PM Saturdays PDT on MS . . other times as I show up
PM me on Discord if you want to be DMd on BG I have Monday nights available
Talk to me if you want to learn to build for NWN2

Tech Admin
User avatar
ayergo
Penguin AKA Vile Sea Tiger
Posts: 3503
Joined: Sun Jan 11, 2004 8:50 pm
Location: Germany (But frequent world travels)

Re: NWN1 Blast from the ALFA past ... Level 4 Validation

Post by ayergo »

Arianna wrote:the script that controls the level validation is csm_onlvlup, unfortunately it is in the ahp_3.0_2da.hak

You may be able to override it by-

open your script editor , click all resources, find csm_onlelvlup , open it change line 25

from

if ( nLevel < 3 )

to

if ( nLevel < 10 )

save and compile, save mod. This places the script in the mod itself.

Removing the script would cause other scripts to fail

I think mod scripts overide hak scripts but not 100% certain on this
Ideally the hak script should be changed to conserve resources

Yeah, agreed. Definitely something in the ACR. I might just modify the ACR script to be back at 10 where it is supposed to be. Code is below:

Code: Select all

#include "csm_include"

void main()
{
    object oPC = GetPCLevellingUp();
    object oModule = GetModule();
    string sID = GetName( oPC ) + GetPCPublicCDKey( oPC );
    int nExp = GetXP( oPC );
    int nLevel = GetHitDice( oPC );
    int nNewExp = CSM_GetXPForLevel( nLevel ) - 1;
    int nFlag = GetLocalInt( oModule, ALFA_ALLOW_LEVELUP+sID );

    if ( nLevel < 3 )
        return;

    // If the player has been granted XP by a DM, the player's good to go
    if ( nFlag )
    {
        SetLocalInt( oModule, ALFA_ALLOW_LEVELUP+sID, FALSE );
        return;
    }

    // Drop the player to within 1 xp of the level he just made
    SetXP( oPC, nNewExp );
    SendMessageToPC( oPC, "Congratulations, adventurer! Please see a DM to proceed to the next level of power." );
    SendMessageToPC( oPC, sID + ", your level has been calculated at " + IntToString( nLevel ) + "." );
}
There's a place I like to hide
A doorway that I run through in the night
Relax child, you were there
But only didn't realize and you were scared
It's a place where you will learn
To face your fears, retrace the years
And ride the whims of your mind
User avatar
Arianna
Tech Admin
Posts: 1660
Joined: Sat Jan 03, 2004 2:28 pm
Location: Idaho PST

Re: NWN1 Blast from the ALFA past ... Level 4 Validation

Post by Arianna »

Just remember any alteration to stuff inside the haks requires peeps to reaquire that hak
Current NWN2 PC: TSM- Lessa

HDM of Moonshae Server DM on BG
Builder Everywhere
DM times - 6:30-10 PM Saturdays PDT on MS . . other times as I show up
PM me on Discord if you want to be DMd on BG I have Monday nights available
Talk to me if you want to learn to build for NWN2

Tech Admin
User avatar
ayergo
Penguin AKA Vile Sea Tiger
Posts: 3503
Joined: Sun Jan 11, 2004 8:50 pm
Location: Germany (But frequent world travels)

Re: NWN1 Blast from the ALFA past ... Level 4 Validation

Post by ayergo »

Fixable without changing haks. Do the following in alfa_include (notice Execute script change):

Code: Select all

void ALFA_OnPlayerLevelUp()
{
  object oPC = GetPCLevellingUp();

  /* Force DM assistance on levels 11+ */
  ExecuteScript( "csm_onlvlupaay", OBJECT_SELF );

  /* Subraces */
  ExecuteScript( "sei_subracelvlup", OBJECT_SELF );

  /* Animal Companions */
  AC_OnLevelUp(oPC);

  /* Familiar adjustment */
  FamiliarCheckOnLevelUp(oPC);

  /* User Defined */
  SignalEvent( OBJECT_SELF, EventUserDefined(ALFA_EVENT_MODULE_ON_LEVEL_UP) );
}
Then make a copy of csm_onlvlup and change the number to your level preference. Done.
There's a place I like to hide
A doorway that I run through in the night
Relax child, you were there
But only didn't realize and you were scared
It's a place where you will learn
To face your fears, retrace the years
And ride the whims of your mind
User avatar
Stormbringer
Owlbear
Posts: 587
Joined: Mon Jan 05, 2004 6:45 am
Location: USA GMT - 6

Re: NWN1 Blast from the ALFA past ... Level 4 Validation

Post by Stormbringer »

For some reason it did not compile.. not sure what I did wrong but when I opened the alfa_include it was blank
Current PC:
Former PC's
Saman Barb/Sorcerer
Kal Rogue/Ranger of Selune
Aiden Ketter Priest of Kelemvor
Kree (ubber not smart Barb)
Past PC: Jena Steel | Hamar Marrion (Marcus)and many other dead PC's
User avatar
ayergo
Penguin AKA Vile Sea Tiger
Posts: 3503
Joined: Sun Jan 11, 2004 8:50 pm
Location: Germany (But frequent world travels)

Re: NWN1 Blast from the ALFA past ... Level 4 Validation

Post by ayergo »

Possible you have a different setup. If you need a hand post up your "OnLevelUp" code and will see what I can do.
There's a place I like to hide
A doorway that I run through in the night
Relax child, you were there
But only didn't realize and you were scared
It's a place where you will learn
To face your fears, retrace the years
And ride the whims of your mind
User avatar
Stormbringer
Owlbear
Posts: 587
Joined: Mon Jan 05, 2004 6:45 am
Location: USA GMT - 6

Re: NWN1 Blast from the ALFA past ... Level 4 Validation

Post by Stormbringer »

Arianna helped me with it. and I got it fixed I hope. Have not tested it yet but I will cross my fingers.
Current PC:
Former PC's
Saman Barb/Sorcerer
Kal Rogue/Ranger of Selune
Aiden Ketter Priest of Kelemvor
Kree (ubber not smart Barb)
Past PC: Jena Steel | Hamar Marrion (Marcus)and many other dead PC's
Post Reply