Author Topic: No rest  (Read 415 times)

Legacy_Jerrus

  • Newbie
  • *
  • Posts: 30
  • Karma: +0/-0
No rest
« on: October 14, 2014, 08:40:52 pm »


               

Hey guys. 


How do I toggle the area no rest on and off?


Thanks!!



               
               

               
            

Legacy_henesua

  • Hero Member
  • *****
  • Posts: 6519
  • Karma: +0/-0
No rest
« Reply #1 on: October 14, 2014, 09:08:42 pm »


               

Are you looking for a scripted solution which cancels rest in specified areas?


 


If so, then you need to capture the rest event and clearallactions if the conditions should NOT allow resting.


See the rest event at the lexicon.



               
               

               
            

Legacy_Jerrus

  • Newbie
  • *
  • Posts: 30
  • Karma: +0/-0
No rest
« Reply #2 on: October 14, 2014, 10:20:38 pm »


               

Yes I am doing this with a script. What I'm thinking about doing is setting all areas to no rest. A pc can only rest if they have a bed roll. When the bed roll is activated in the inventory it toggles off the no rest and spawns a bed roll on the ground. Even if I don't use it I'd still like to know how to do it. LOL.



               
               

               
            

Legacy_henesua

  • Hero Member
  • *****
  • Posts: 6519
  • Karma: +0/-0
No rest
« Reply #3 on: October 14, 2014, 10:31:30 pm »


               

I started a thread when I created a customizable rest framework for someone else to use. It has a number of things it can check (including whther or not a bedroll is needed) when determining if rest is possible. You can configure it to check some of these depending on what you want to do. It can also work situationally. Particular restrictions can be in place in particular areas or within particular triggers or in reverse - everywhere but within particular triggers can have particular restrictions. Its all customizable.


 


If you are at all interested in figuring out how to make use of that framework let me know, ask questions etc… and I'll help you out. I also have developed it much further than the code uploaded to that link. If you are interested I'll look into digging out what I have done, and putting online for download.



               
               

               
            

Legacy_Jerrus

  • Newbie
  • *
  • Posts: 30
  • Karma: +0/-0
No rest
« Reply #4 on: October 14, 2014, 10:49:24 pm »


               

Thanks, I'll check that out. I don't think it's quite what I had in mind, but I may be able to use that.


If nothing else, I like studying peoples scripts. That's how I've learned most of what I know about scripting in NWN.


Thanks!



               
               

               
            

Legacy_henesua

  • Hero Member
  • *****
  • Posts: 6519
  • Karma: +0/-0
No rest
« Reply #5 on: October 14, 2014, 11:14:31 pm »


               

well, precisely what you need could be handled with two scripts fairly easily - one for the bedroll item and one for the onrest event.


 


so my system does far more than what you had in mind, but it can also do what you want. its a swiss army knife. if i get time i'll post the two scripts you want as well. but … heh.. time is a fleeting mistress who I chase after.



               
               

               
            

Legacy_Jerrus

  • Newbie
  • *
  • Posts: 30
  • Karma: +0/-0
No rest
« Reply #6 on: October 15, 2014, 12:53:55 am »


               

Thanks!!!