Author Topic: Query encounters?  (Read 513 times)

Legacy_Eagles Talon

  • Full Member
  • ***
  • Posts: 192
  • Karma: +0/-0
Query encounters?
« on: September 17, 2011, 08:28:51 am »


               Is there a script function that could identify the challenge rating (avg) of encounters in an area?
               
               

               
            

Legacy_Lightfoot8

  • Hero Member
  • *****
  • Posts: 4797
  • Karma: +0/-0
Query encounters?
« Reply #1 on: September 18, 2011, 09:07:23 am »


               I do not think there is.  I do not even know if it could be done or not, since what the encounter spawns changes per the creature that triggers it.
               
               

               
            

Legacy_Shadooow

  • Hero Member
  • *****
  • Posts: 7698
  • Karma: +0/-0
Query encounters?
« Reply #2 on: September 18, 2011, 09:49:56 am »


               Rather tell us your intent maybe we can find a way how to do that you havent thought of.
               
               

               
            

Legacy_ffbj

  • Hero Member
  • *****
  • Posts: 1097
  • Karma: +0/-0
Query encounters?
« Reply #3 on: September 18, 2011, 07:23:40 pm »


               Well you could always set a local on the area with your own difficulty level, and then send a msg to PC when they enter.  Since you set the encounters as you wish you could determine the difficulty rating of the area.  Such as difficulty. 1,2,3, etc..and then send a msg to PC regarding the difficulty of the area. either  based on level "This area is for 4-8th level.' Or a generalized message like in ski slopes bunny hill, beginners, advanced, expert.
               
               

               
            

Legacy_Eagles Talon

  • Full Member
  • ***
  • Posts: 192
  • Karma: +0/-0
Query encounters?
« Reply #4 on: September 19, 2011, 11:06:36 am »


               Intent:  We have scripts, several of them, that are used on Area Enter that define the "level" of the area for treasure drops.  Was thinking that we could combine them into one script with the script checking the level of the encounters to define the drops.  The other thought was if a script could check placeables for a particular tagged invisible item that would define the area level.  Thoughts?
               
               

               
            

Legacy_Shadooow

  • Hero Member
  • *****
  • Posts: 7698
  • Karma: +0/-0
Query encounters?
« Reply #5 on: September 19, 2011, 11:50:12 am »


               

Eagles Talon wrote...

The other thought was if a script could check placeables for a particular tagged invisible item that would define the area level.  Thoughts?

This could be done of course.

You can use any invisible placeable, but they all should have same tag and then they should have some value inside, either as variable /int LEVEL number/ or lets say WillSave of the placeable. Then you would get the level like this:

(considering use in OnEnter of a placeable)
int nLevel = 1;
object oLevel = GetNearestObjectBy("level_plc");
 if(oLevel != OBJECT_INVALID)
 {
 nLevel = GetLocalInt(oLevel,"LEVEL"); //or GetWillSavingThrow(oLevel);
 }

This method would have some advantages and disadvantages.
+ it would save you time as you wouldnt have to set level on each loot placeable
- it wouldnt allowed you to have different loot level placeables in same area

The other way is to use the will save or variable of the loot placeable in question, that would have just opposite (dis)advantages.
It could be also combined together, so if the variable LEVEL or will save on loot placeable is 0, then it will look for invisible placeable to get level, its a bit time consuming but it will allow you better immersion.