Jump to content

Blades of Nethergate


Recommended Posts

I am working on a Scenario Editor for Nethergate: Resurrection. It will enable the creation of BoA-style scenarios for N:R. As the two games use the same engine it will be relatively simple. Jeff has given his blessing for these sorts of endeavors. (What I really need is his Editor.)

So far I can open the SharedData.dat file and examine its contents, ditto the other data files.

Certain things are hard-coded, written into the N:R program itself. A separate program will be needed for this. It will be a nuisance if there is no BoA-style scenario script, that sort of stuff seems to be hard-coded too. May need to use journal entries as a replacement for notes/books that can be used.

Edited by Ishad Nha
Link to comment
Share on other sites

Blades of Nethergate - How it could be done

 

Stuff that occurs in BoA but not N:R would need to be cut out:

Variable Town Entry, Item Placement Shortcuts, Scenario Intro text, Scenario Boat/Horse records, Hidden Towns...

Instead of Bas files, Blades of Nethergate would have Celt Data.dat, Roman Data.dat and Shared Data.dat files. Outdoor.dat may not be needed for all I know, it does nothing?

Alint would need to be updated for the Nethergate world, that would be straightforward as there are no more than eight new calls.

 

Definitions

Data folders: these are the Celt Data, Outdoor Data, Roman Data and Shared Data folders.

Objects: these are floor, terrain, creature or item types.

Celt/Roman towns: each town has one version for a Celt party and another for a Roman party.

Shared towns: these towns occur in the Shared Data folder, there is only one version of each town.

 

Game Plan:

(1) There is a Blades of Nethergate Scenarios folder, found at:

C:\Program Files\Spiderweb Software\Nethergate\Nethergate Res\Blades of Nethergate Scenarios

(2) All scenarios are stored in scenario folders which are sub-folders of the above.

(3) There is one scenario per scenario folder.

(4) Each scenario folder contains three Data folders: Celt Data, Roman Data and Shared Data.

Outdoor Data may contain the outdoor fight "towns". It seems that "fl_out_fight_town_used" or "te_out_fight_town_used" is simply 1,000 + the town number in Outdoor Data.dat

If there are any custom graphics, they are found in the scenario folder.

Ditto if there are custom objects (floor, terrain, creature or item) the altered corescendata.txt or corescendata2.txt files are found here.

(5) To be played, a scenario must be installed, only one can be installed at a time.

 

(6) When a scenario is installed:

[a] Existing custom graphics are deleted. They can have distinctive numbers.

If there are any custom graphics, they are copied to C:\Program Files\Spiderweb Software\Nethergate\Nethergate Res\Data.

Existing core scenario data scripts are deleted.

If there are custom objects (floor, terrain, creature or item), the altered corescendata.txt and/or corescendata2.txt files are copied to the same folder.

If there are no custom objects, default scenario data scripts are copied in from a storage folder. Said default scripts would be permamently stored someplace.

[c] Existing Data Folders are deleted. New folders are copied in from the scenario folder of the newly installed scenario.

 

(7) A scenario may not have distinctly Celt or Roman versions, in which case the Celt Data and Roman Data folders would both be empty.

 

It is quite easy to convert BoA scenarios to the Nethergate: Resurrection game. You only need to alter the scenario header. Also:

(1) remove any instances of the call "set_creature_type_level"

(2) there are currently no graphics for PCs riding horses.

(3) using boats outdoors may not work, if you leave the boat it may return to its town of origin.

 

Instead of a scenario data script you would alter the core data scripts directly.

Edited by Ishad Nha
Link to comment
Share on other sites

I worked out a functioning Editor then I tried to alter it to use the N:R graphics not the BoA ones it had been using. Now it is not functional, it cannot open any files at all. Now I am trying to get back to where I was.

Latest Beta is found at:

http://www.freewebs.com/ishadnha/BNEditor.zip

In the long run, someone will need to write a program that enables alteration of the stuff written into the Nethergate program.

 

Terrain Item Shortcuts can be made an unofficial function, the shortcuts themselves can no longer be stored in the Scenario file. But I don't think anyone uses this in practice?

Boats and Horses can possibly be given unofficial treatment too.

 

Edit:

Now the Editor can use the N:R graphics. It is still being run from the BoA Data folder.

I am looking at porting Of Good and Evil into the Nethergate game, to see how mods would work in practice.

 

My Celtic party has just entered the Northern Outpost, starting town in Of Good and Evil.

 

Now I am trying to understand the town entrances, exactly how they work.

100:149 seems to be Celt/Roman and 150:199 seems to be Outdoor.

200+ is not clear.

Edited by Ishad Nha
Link to comment
Share on other sites

A N:R version of the HLPM will need to be created, this means altering all the item, spell, potion, trait and ability lists. Could be included as a town in any scenario. Currently the party is wandering around the N:R version of Good and Evil, avoiding fights because they are only a beginning party in the N:R game.

 

Town Numbering scheme used by the game:

Towns "0:49" are towns 0:49 in the Celt/Roman Data.dat files.

Towns "50:99" are towns 0:49 in the Shared Data.dat file.

Towns "100:149" seem to be Outdoors Data.dat file towns. Ditto towns "150:199".

 

Starting towns only have one thing fixed, their town number. Apart from that everything is variable. A call in the Init State can move the party to a more favorable starting position: "teleport_party(9,26,1);". For Celt parties, Celt town 30 is always the Starting Town, unless I can work something out. It will have a move_to_new_town call that takes you to the starting town for the current scenario. Latter town has change_outdoor_location included in all its exit states, thus the party will always arrive in the correct outdoor zone.

(I am assuming that town 30 will never be the starting town in future scenarios.)

 

In N:R West and East town entrances are switched around, by comparison with BoA.

The spell Sever Seal seems to be wholly hard-coded, it probably just calls a town state. Then after the spell is cast, it has a SDF that shuts off the rune or seal concerned.

(It should be possible to sever seals in town 13 of any scenario, at the locations used in N:R. I will need to check this.)

 

In Of Good and Evil,

Towns 0 through 49 are found in the Celt/Roman Data.dat files.

Towns 50 through 99 are found in the Shared Data.dat file.

"Foyer" towns can be added to the Outdoor Data.dat file, currently it only has 14 towns.

Now Outdoor Data towns can be used as regular towns with town entrances leading to them, but the townscript must be placed in the Shared Data folder, eg t114Recall.

 

Word of Recall is handled by the spell taking you to the usual outdoor section, X=4,Y=0. That zone contains a minimalist town, t114 Word of Recall, this town has a placed special that takes you back to the starting town of OGE: town 0 Northern Outpost.

 

Scenario states can be called indirectly via the scenario Start State. Maybe alter it so that a PC having two set items can bring up a list of options.

Edited by Ishad Nha
Link to comment
Share on other sites

Romans can apparently cast any spell, though Spirit Circle statistics won't show up in the Training/Information screen. Spirit Circle skills can be increased by this call: alter_stat(0,19,1);

 

Big picture, it probably won't be possible to go from scenario to scenario in the BoE/BoA style. This requires the ability to reset the save game, I don't know if this is possible.

Currently I expect that each scenario will feature a one-shot party created especially for that scenario.

 

Scenarios won't neatly end in the BoE/BoA way with a return to the Main Screen. End of scenario will be announced then it will be a matter of loading a new save game.

End_scenario(#) presumably triggers the N:R finale, not what is needed.

 

HLPM is best done in a minimalist fashion. No items to pick up and no monsters to fight, otherwise they will need to be reset. All flags will be reset to 0 when everything is done. It could be ensuite, made into a new town for the scenario, or it could be a stand-alone scenario in its own right. Both approaches have been used in the past.

Shop numbers could be problematic.

 

Game starts with the beginning party entering the HLPM, Roman town 1 for Romans, Celt town 30 for Celts.

 

Now to go from a stand-alone HLPM to another scenario means:

[a] going from one scenario to another

Game plan is to do the HLPM things, save the game, shut down N:R, install a new scenario, restart N:R and the reload the save game.

going from the HLPM version of town # to the scenario version town#.

If all else fails you can always import the starting town from the scenario into the HLPM.

 

Save game file seems to always contain the details of the current town, if you save in town# in the HLPM then reload in some other scenario, the town details will be those for the town in the HLPM...

Save games seem not to care about scenario name, which would be meaningless in N:R. Hence you could save a game in the N:R version of HLPM and re-open it in another scenario. Need to take care to arrive in the right part of the new scenario's starting town.

Link to comment
Share on other sites

Now I will need to create a list of N:R translations for BoA items.

You can use the BoA Editor to create Scenario Data files for N:R that list the names of all floor, terrain, creature and item types. There are only two new calls in the N:R core data scripts: "it_itemdesc" and "te_third_icon". They can be commented-out easily: just use Replace All to add "// " to the start of each occurence of the call concerned.

 

This is the list of skills that can be increased by paying trainers:

5000 Strength

5001 Dexterity

5002 Intelligence

5003 Endurance

5004 Melee Weapons

5005 Spears

5006 Javelins

5007 Slings

5008 Armor Use

5009 Berserker

5010 Hardiness

5011 Defense

5012 Roman Training

5013 Crystal Wand

5014 Druidism

5015 Health Circle

5016 War Circle

5017 Beast Circle

5018 Craft Circle

5019 Spirit Circle

5020 First Aid

5021 Herbcraft

5022 Tool Use

5023 Faerie Lore

5024 Woodscraft

5025 Barter

5026 Luck

 

Edit:

I have worked out a script for the Shopping area, now I am removing duplicate item entries from it.

Edited by Ishad Nha
Link to comment
Share on other sites

It is a "proof of concept" thing, it shows that it is possible to turn a stand-alone game into a scenario-based game. Nethergate: Resurrection is easier for me to understand than Geneforge 5. I am not the best programmer, here at Spiderweb there are better programmers than me.

It is very similar to BoA, until you actually try and make a Blades of Nethergate, then you spot all the subtle differences...

Experience gained with this will help in Blades of Geneforge or Blades of Avernum EFTP.

 

HLPM is now done. It is packed into two towns that can be added to the end of a scenario to give you an en-suite HLPM. If there are problems with town sizes in the HLPM clashing with those in the actual scenario, simply add the HLPM towns to the end of the scenario. Then adjust the destinations of both stairways in the downsized HLPM.

Arena was dropped, it could always be added back again.

I added 100 to all the HLPM shop numbers so they would not conflict with the regular scenario shop numbers.

 

Editor stopped writing report data files, like Scenario Data.txt when the scenario name got too long, I need to figure what has happened.

Edit: it was not the length of the scenario name, it was a colon being included in the name. Once the colon was removed, reports were printed normally.

 

A new version of the Editor has been uploaded. Also included are the graphics you will need to use boats.

Edited by Ishad Nha
Link to comment
Share on other sites

The call town_status only accepts one argument: -1, it does not even accept current_town().

 

Scenario states can be run from terrain scripts and town/outdoor placed specials. I can't get them to run from items as yet. Here the "Scenario Script" is Celt Data.txt, presumably it would work for the Roman script too.

Said stats can be run from the Start State but I can't reliably switch that state on and off.

 

Celts start at Celt town 30, that would seem to require that all scenarios have 31 towns minimum. Most BoA scenarios have less than that?

One workaround is to have a HLPM version of Celt Data.dat that has the 31+ towns. Raise the party then send them to Celt town 0. Save the game then quit. I am currently playing a N:R version of Magus of Cattalon, which only has 23 towns. In Windows Explorer switch the HLPM version of Celt Data.dat with a new Magus of Cattalon version that only has 23 towns.

Apparently the game does not notice that the scenario is now missing 8 towns.

 

Playing Magus of Cattalon, Celts have a maximum value for armor protection. This value applies to all types of armor: cloaks, boots, gauntlets and body armor. Strange Golems were massacring my warriors or forcing them to use Invulnerability potions. So I adapted the Cloak of Immortality from Kel's HLPM scenario. Now I can survive encounters with them.

begindefineitem 475;

import = 16;

it_full_name = "Cloak of Immortality";

it_icon_adjust = 64;

it_protection = 10;

it_bonus = 30;

it_value = 1000;

it_weight = 1;

it_identified = 1;

it_ability_1 = 82;

it_ability_str_1 = 5;

it_ability_2 = 83;

it_ability_str_2 = 5;

it_ability_3 = 85;

it_ability_str_3 = 25;

Edited by Ishad Nha
Link to comment
Share on other sites

NPC, Hathwisa from Galag Trav, joins party:

(add_char_to_party(55,5)

Flags may also be set at the time of joining:

set_flag(56,6,250);

Is NPC in party?

if (character_in_party(5649) >= 0)

add_char_to_party uses the town creature number, 4:119, not the Character number 0:19,999.

and it specifies a place in the party(55,5)

Currently Randall, in Magus of Cattalon, gets a small portrait of a dead PC in the party area at the upper left of the screen!

 

Rhian from town 17, Roman Vanarium, add_char_to_party(29,4), 1723, sf(17,17,1),18. With the Craft Circle increase coming from the relevant Scroll she can cast Word of Recall, back to outside the Shadow Valley Fort. Despite being a Druid she can't train in anything except War and Health Circles. \

 

I think the NPC portrait numbers may be hard-coded, so for now I have replaced the skull portrait in 906.bmp with the Boutell graphic, icon 6. This is the best that I can do, I thought the icon number might be stored in the save game file but that seems not to be the case.

 

In the N:R version of Magus of Cattalon item 454 is a Papyrus Scroll, it produces a steady stream of food because in N:R item 454 is Sylak's Nourishing Bowl. It seems that N:R would use a char_has_item(###) call.

 

I have customized the N:R core data scripts so they basically use the original items from the BoA version of MoC as much as possible. Item abilities needed to be translated for abilities 9 thru 27, BoA and N:R are different in that interval and also in the spell effect area of abilities 100 thru 149.

Edited by Ishad Nha
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...