Aller au contenu

Photo

Is there a decent tutorial on how to implemen the MoTB Rest System Tutorial


  • Veuillez vous connecter pour répondre
32 réponses à ce sujet

#1
ColorsFade

ColorsFade
  • Members
  • 1 267 messages
I tried searching this forum, but wow this search function sucks. 

I figure someone has to have done this already...

#2
kevL

kevL
  • Members
  • 4 056 messages

ColorsFade wrote...

I tried searching this forum, but wow this search function sucks.

yeh.. use this instead: Google search social.bioware

I figure someone has to have done this already...

I recall someone doing it recently but can't find it. Personally i'd start with any of the MotB module's onRest script and follow it through ..... I haven't sorted the module-level events yet, so can't help much; but if you go to the install->Campaign_X2 folder, look for 'k_mod_player_rest' and in Data\\scripts_x1, 'ginc_restsys' i guess. I don't think there's a doc like Tchos' SoZ Loot System tho,

#3
ColorsFade

ColorsFade
  • Members
  • 1 267 messages
Sounds like a guide is in order.

Maybe I'll post one after I get it working.

#4
Shallina

Shallina
  • Members
  • 1 011 messages
All the secrets are in MOTB module rest_script.

Open a MOTB module, check the module property, and open the script referenced in the rest field.

#5
MokahTGS

MokahTGS
  • Members
  • 946 messages

ColorsFade wrote...

Sounds like a guide is in order.

Maybe I'll post one after I get it working.


Please do, and when you do, please also upload a PDF version to the Vault and Nexus.  Forum posts are only good if you can find them, and Bioware has a nasty habit/history of destroying community work on the forums.

#6
ColorsFade

ColorsFade
  • Members
  • 1 267 messages

MokahTGS wrote...

Please do, and when you do, please also upload a PDF version to the Vault and Nexus.  Forum posts are only good if you can find them, and Bioware has a nasty habit/history of destroying community work on the forums.


I intend to (if I can figure out how to make a PDF - never done that actually). 

Should be later this week or the weekend. Depends on workload. 

#7
Tchos

Tchos
  • Members
  • 5 042 messages
If you use OpenOffice to create or open the document, it's a matter of choosing File>Export as PDF.

The MotB resting system was one of the first things I implemented, and I regret that I didn't document the process at the time. If I were to do it again, I would have to look through the files again to see which ones were necessary, and I don't expect I'll need to do it again since I would just use a stripped-down template shell of my current campaign for future campaigns. I did explain about the 2DA, though (make one with your own creatures in it, because most of the ones in the existing 2DA are blueprints from MotB).

#8
MokahTGS

MokahTGS
  • Members
  • 946 messages

ColorsFade wrote...

MokahTGS wrote...

Please do, and when you do, please also upload a PDF version to the Vault and Nexus.  Forum posts are only good if you can find them, and Bioware has a nasty habit/history of destroying community work on the forums.


I intend to (if I can figure out how to make a PDF - never done that actually). 

Should be later this week or the weekend. Depends on workload. 


This is what I use: CutePDF Maker

It works by "printing" the document as a PDF.  Works for anything you can print.

Modifié par MokahTGS, 16 avril 2013 - 01:41 .


#9
Morbane

Morbane
  • Members
  • 1 883 messages
Word 2010 does it afaik . . . or maybe it was the latest version of acrobat :blink:


Edit: Just checked - it is Adobe Reader X :wizard:

Modifié par Morbane, 16 avril 2013 - 02:00 .


#10
ColorsFade

ColorsFade
  • Members
  • 1 267 messages

Tchos wrote...

If you use OpenOffice to create or open the document, it's a matter of choosing File>Export as PDF.

The MotB resting system was one of the first things I implemented, and I regret that I didn't document the process at the time. If I were to do it again, I would have to look through the files again to see which ones were necessary, and I don't expect I'll need to do it again since I would just use a stripped-down template shell of my current campaign for future campaigns. I did explain about the 2DA, though (make one with your own creatures in it, because most of the ones in the existing 2DA are blueprints from MotB).


Thanks Tchos. I'll look that part up in your diary. 

This will be good because I'll be able to give something back to the community :D

#11
ColorsFade

ColorsFade
  • Members
  • 1 267 messages
Decided to take a crack at it this morning. It's almost done.

Guide will be up later.

#12
ColorsFade

ColorsFade
  • Members
  • 1 267 messages
Well, the resting part is easy. Two lines and the gui pops up and the time passes. But that's where the easy part ends.

The wandering monster part is not easy.... Holy suck-it Batman...

Part of what is making this difficult is that I have SoZ installed, and they changed things, it looks like.

I can't get the system to read my 2da file. I can rest - and I can get interrupted and get the interruption message, but no monsters spawn. Which is really frustrating, because tracing through the files, I can't see how creatures are ever spawned. This is a lesson in how indirection can screw you when trying to debug.

When I run x2_restsys_dbg, it gives me an invalid row id for the 2da and the values for chances do not match the 2da. So clearly it is not reading the file. I thought maybe it was because I had the file open with Excel and perhaps Excel locked the file handle. But closing Excel and running the game still produces the same thing.

Frustrating. Seems like this should be straight forward. I can't figure why it's not reading the 2da and I don't quite feel like editing and recompiling all the dependencies just so I can write some debug statements... This is failing somewhere though. Clearly.

#13
Tchos

Tchos
  • Members
  • 5 042 messages
You didn't mention the variables. Are you applying the necessary variables to the area?

#14
ColorsFade

ColorsFade
  • Members
  • 1 267 messages
I think so. They're the same variable set that MoTB uses in it's areas. At first, I just opened up a MoTB area and was going to export all the variables as a set. But then I noticed there's already a default set you can do to import that is just the same. The variables all begin WM_

SoZ has what looks like a completely separate system and all their variables start with a different prefix.

#15
Tchos

Tchos
  • Members
  • 5 042 messages
And, just to make sure, this is a custom 2DA containing creatures whose blueprints exist in the default toolset and/or your module?

#16
ColorsFade

ColorsFade
  • Members
  • 1 267 messages

Tchos wrote...

And, just to make sure, this is a custom 2DA containing creatures whose blueprints exist in the default toolset and/or your module?


Yes. 

I found the problem with it not reading the 2DA. There was a note buried in one of the scripts that said the 2da file name can't be longer than 16 characters. Once I shortended it, I started to see debug lines show up (I copied and recompiled most of the scripts involved with this and started printing statements to the Chat window). 

So, it reads the file now and caches the data. But I still don't get creatures when I rest and get "interrupted"... 

Trying to figure it out now. 

#17
ColorsFade

ColorsFade
  • Members
  • 1 267 messages
This is just painful.

So, I found gr_restsys_dbg, which appears to be the debug for MoTB Wandering Monsters. Apparently, the other stuff is a hold-over from Hoards of the Underdark for NWN1.

The debug prints everything correctly except the Table. For that it returns:

Table:INVALID_TABLE

I have looked at the 2da... It looks fine. I took the existing 2da and simply change one of the lines to make creatures appropriate to my area. I have the WM_ENC_TABLE_DAY and WM_ENC_TABLE_NIGHT values set to match the value in the Table column of the 2da. I've tried some of the other values in the 2da as well, like c_wyverns, hoping to see something show up... I get nothing.

This has to be a 2da issue somehow. Not sure what it is though. It just doesn't make any sense.

I can tell this 2da thing... is a bad idea. Like, I never want to have to edit these ever again. Wow, talk about a bad way to do something.

#18
Tchos

Tchos
  • Members
  • 5 042 messages
Are you using the name of the creature set you want the system to pick from, without quotes (not a number)? Example variable set for one of my areas:

WM_DISABLED: 0
WM_ENC_TABLE_DAY: Undead
WM_ENC_PROB_DAY: 45
WM_SPAWN_POINTS_DISABLED: 1

You also need a set of variables for night.

Edit: Never mind, you posted while I was writing.

Modifié par Tchos, 16 avril 2013 - 11:20 .


#19
ColorsFade

ColorsFade
  • Members
  • 1 267 messages
AND IT'S WORKING!

OMG... about time.

So... you gotta make damn sure you are ignoring anything having to do with the x2_inc_restsys...

I got the last piece of the puzzle working.

I'm going to start with a brand new module and do it again from scratch taking screenshots of the toolset along the way and document all of this. It's actually not bad.

But the holdover of the X2 system really can foul a guy up quick.

#20
rjshae

rjshae
  • Members
  • 4 485 messages
I made a modified version of the rest script that looks for the nearest marker of a specific type, then reads off the day/night risk factor as well as the monsters encountered from local variables on the marker. It allows me to 'tune' a dungeon for specific random encounter types in various areas. You might try experimenting with something like that. Once you have it set up, it's fairly scalable.

#21
ColorsFade

ColorsFade
  • Members
  • 1 267 messages

rjshae wrote...

I made a modified version of the rest script that looks for the nearest marker of a specific type, then reads off the day/night risk factor as well as the monsters encountered from local variables on the marker. It allows me to 'tune' a dungeon for specific random encounter types in various areas. You might try experimenting with something like that. Once you have it set up, it's fairly scalable.


Thanks. Not necessary though. I would have gone down a similar path if I wouldn't have been able to figure out the MotB system. It's actually really easy to use once it's setup. 

I just finished writing a guide for the MotB rest system. One of the options with it allows you to spawn monsters at designated waypoints (other options in inclue random in the area, or near doors, although doors don't seem to work very well).

The 2DA file allows you to setup three different types of encounters for a config/row and set probabilities for each encounter. You can setup separate rows in the 2DA for night and day encounters. The system is pretty darn flexible. 

The guide just went to NWN2 Vault and is pending approval. 

I didn't care so much about the random encounters, at first. I just wanted the 8-hour rest and the day/night clock. But having the wandering monster system at my disposal is a nice bonus. I intend to use it in dungeons, forests and the like. 

#22
Dann-J

Dann-J
  • Members
  • 3 161 messages
I've since given up on the vault, and now upload things to the Nexus site exclusively. There's no waiting for approval, and you can upload much larger files.

A google search I did a few minutes ago listed all nwvault.ign.com addresses as potentially containing malware.

#23
ColorsFade

ColorsFade
  • Members
  • 1 267 messages
Can't get uploads to work at Nexus. Says I need to contact an Admin.

Bummer.

#24
ColorsFade

ColorsFade
  • Members
  • 1 267 messages
Oh holy night... what a painful site. Wow. Nexus... you gotta do some work man. I can't even contact an admin.

Sad.

Guess I'll just wait for Vault to approve it.

#25
Dann-J

Dann-J
  • Members
  • 3 161 messages
The gods really are against you at the moment. What did you do, spit on a shrine of Tymora or something?