Author Topic: Custom Tokens - Issues??  (Read 387 times)

Baaleos

  • Administrator
  • Hero Member
  • *****
  • Posts: 1916
  • Karma: +0/-0
Custom Tokens - Issues??
« on: December 22, 2010, 03:06:50 pm »


               In regards to custom tokens,
While I know a Custom Token is specific to the whole module, what I dont know is - if one person had the dialog open which had CustomTokens displayed, and another player initiated an event that changed the Token values, would these values update right before the eyes of person A.


I have created a custom level up system, which on certain levels, allows players to select a feat.
Instead of scripting for all feats individually, I scripted it to use Custom Tokens, and display all feats in the game from a database.
eg
Display 10 Custom Tokens, a next and a back dialog choice.
10 Feats per page, 1115 maximum feats = 115 pages potentially of feats to browse through.
The Feats will also display [LOCKED] if the player doesnt meet my level requirements, or if the feat itself is not implimented or allowed yet (defined in the database)
Next progresses to the next 10 values, and back to the previous 10 values.

The feat numbers etc and values are stored on the players themselves each time the page/dialog page displays, but what im worried about, is if
Player A is leveling up, and has the feat selection menu open,
and then
Player B opens the menu, and starts browsing for feats, would his browsing, change the Feat Names currently displayed on Person A's screen.

If not - then I am safe, because Person A would simply re-set the token values back to what 'he' needs them to be, when he browses forwards or backwards. Person B would be in the same safe boat, because he would also reset the token values back to what he needs because the page number/index is stored as a local variable on the player himself.

If Person B's actions cause the dialog to update on Person A's screen, without Person A changing page, then I have problems. Basically Person B would be driving Person A's dialog.
               
               

               
            

Legacy_NorthWolf

  • Full Member
  • ***
  • Posts: 143
  • Karma: +0/-0
Custom Tokens - Issues??
« Reply #1 on: December 22, 2010, 03:47:02 pm »


               No, it wouldn't update. The custom token is loaded when they enter that section of dialog and will remain as whatever text it was on entry, to my knowledge.
               
               

               


                     Modifié par NorthWolf, 22 décembre 2010 - 03:47 .
                     
                  


            

Baaleos

  • Administrator
  • Hero Member
  • *****
  • Posts: 1916
  • Karma: +0/-0
Custom Tokens - Issues??
« Reply #2 on: December 22, 2010, 04:27:18 pm »


               Cool,

Nice to know...

Last thing I wanted, was players to complain about their dialog choices changing, just because multiple players were leveling up at the same time.
               
               

               
            

Legacy_Lightfoot8

  • Hero Member
  • *****
  • Posts: 4797
  • Karma: +0/-0
Custom Tokens - Issues??
« Reply #3 on: December 22, 2010, 04:36:51 pm »


               IT still should not be a proble, As long as you update the token just befor it displays.



If more then one player is going to have the conversation open at a time.  Store all critical vars for the conversation on the player.  Just like you would do for a multi player quest.
               
               

               
            

Baaleos

  • Administrator
  • Hero Member
  • *****
  • Posts: 1916
  • Karma: +0/-0
Custom Tokens - Issues??
« Reply #4 on: December 22, 2010, 05:32:24 pm »


               Yeah, thats what im doing already.

The token values are actually set on the 'ActionsTaken' script, of the page that uses the tokens.



So each time the page refreshes, the value gets assigned. But the actually important values of the feats themselves, their numbers etc, are stored on the players, as int's which are named in relation to their custom token number.



eg

<CUSTOM6101>    = Ambidextry (or however you spell it)

so at the same time, it assigns  1  (think thats the feat number)  to a variable called FEAT_CUS_6101 on the player.



That way, when the player selects Ambidextry, from the conversation, the numerical value of the feat is retrieved from that locally stored int on the player.



I was surprised how easy it was to create this dynamically populating conversation for giving players the ability to choose feats in my custom level up system.

20 scripts for feats 1-10 - locked or not locked

2 scripts for progressing to the next page

1 script for generating the feat list on the conversation

and 1 include file to rule them all--- er... I mean, drive them all.
               
               

               
            

Legacy_FunkySwerve

  • Hero Member
  • *****
  • Posts: 2325
  • Karma: +0/-0
Custom Tokens - Issues??
« Reply #5 on: December 22, 2010, 08:12:12 pm »


               It's not a problem in many cases, but you may well see some glitchiness. You will probably want to use a full-on dynamic convo system. I'm in the middle of setting up HGLL for paragon levels, and retooling it at the same time to use a different (custom) dynamic convo system, mostly because the system has 20 different convos with 20 different sets of tokens, which prevents the aforementioned glitchiness when multiple players are using the system. If you're interested in dynamic convo systems, I would take a look at zz-dialogue on the vault - apparently it's an improved version of z-dialogue, which is what I used for HGLL.



Funky
               
               

               
            

Baaleos

  • Administrator
  • Hero Member
  • *****
  • Posts: 1916
  • Karma: +0/-0
Custom Tokens - Issues??
« Reply #6 on: December 23, 2010, 10:05:31 am »


               Lol,

As if Legendary Levels wasnt enough, you need Paragon Levels? :-)



I will have a look at zzdialogue, I have known about it for a while, but havent got round to looking into it.



My module is still pretty fresh, so it would be best to look at it sooner rather than later, while I currently only have 6 dialogues present.



Also -

Paragon Levels - what level limit does that add?



My vampire leveling system is a little more 'niche' than a bioware/D&D level up system, but it allows for

about on average, 22 Pseudo levels, for each of the 40 Bioware levels.

(Note - Its a new system, and I have only just reached beyond 23 on my own character, moving onto the 2nd Bioware level, so I dont actually know what the upper limit is - As the player gets higher, the amount of Pseudo levels per real level may diminish)



Basically, the only limiting factor at the minute, is the upper hp limit imposed by the bic files.

255 hp per physical character level. and so far, my own character has reached Vampire Level 23, and only just needed to go onto the 2nd Bioware Physical Level. (Raising to the next physical level is actually required to prevent server crashes - attempting to raise hp higher than 255 for the current hitdice = roll over to 0, and attempting to set hp for levels that have not been attained, will result in server crashes (via nwnx_funcs))

I have it set up to work with Pseudo levels, granting feat, and skill bonuses, as well as hp, but when it detects that the hp of the player is about to breech the <maxhp>/255 >= current physical level mark, it on that level up, decides to raise the players physical bioware level, granting another potential 255 hp attainable via pseudo-level-ups.



eg

if my character has

214 max hp

214/255 = 0.83  which is less than physical level of 1.

This means, it can keep me on physical level 1.



If however, it calculates my hp for this level up to be

267

267/255 = 1.04 - which is greater than our physical level of 1- the system then says, Increase their physical level by 1, and perform an auto level up using their current package.



On the next level up, it would say  284/255 = 1.113 - which is still less than physical level 2, so no additional phsyical levels are required at this point.



Sure you get the picture. hehe





               
               

               
            

Legacy_FunkySwerve

  • Hero Member
  • *****
  • Posts: 2325
  • Karma: +0/-0
Custom Tokens - Issues??
« Reply #7 on: December 23, 2010, 05:46:20 pm »


               Paragon levels will allow up to level 80. I briefly toyed with 100, but that would've forced either unacceptably slow leveling power increase (on the game theory notion that regular powerups/progress markers are required to maintain player interest) or too great a power gap (given dwindling population we want endgame characters able to party with 60s without making a mockery of their assistance). We were also forced to come up with an alteration to our Craft Armor ac bonus engine hack, to reduce the divide between dex and str acs, and another new hack to alter the treatment of base skills added above 63 (they can add them, but they offset penalties, instead of adding to base score, thus retaining some use while not allowing outright larger numbers.



Funky