NW Scening and Multiplayer Compatibility Questions

Users who are viewing this thread

Hello

I’m a newbie scener/modder and I have three specific questions to ask:
1. If you open your module folder, you will find a scenes.txt file that contains many scenes. For the multiplayer scene “Ambush” you have this code
Code:
scn_mp_ambush mp_ambush 256 none none 0.000000 0.000000 100.000000 100.000000 -100.000000 0x000000023002a1ba0004210900003ca000006a8900007a7b
0
0
outer_terrain_plain

Quoting a different thread there is "outer_terrain_plain", "outer_terrain_steppe", "outer_terrain_desert", "outer_terrain_snow", "outer_terrain_beach" and “0”.
What I want to know is how to change the outer terrain of a scene? Solved.

2. I want to set the preview picture (that shows on the admin panel) of my custom map to be an in-game screenshot. I believe that, for that, you have to create a mesh file with that screenshot, have the game recognize that mesh and then assign it to the custom map. Is that feasible? How would you do that? How does that work?

dvbTVj.jpg

3.Following a previous question that I asked on Modding Q&A, I was able to create a new .sco file in SceneObj for my Modded Napoleonic Wars folder, name the new .sco file "Training_camp" and have the new scene and respective name be displayed in the map selection screen when hosting a server. Now I try to go online in Modded Napoleonic Wars to either join a server or host a dedicated server and it’s incompatible! The third question is: how do I export the new scene (.sco file, terrain code, display in the admin panel) to the regular Napoleonic Wars module so that I can join other servers or host a dedicated server with my custom map? Solved.
I tried copying the .sco file into NapoleonicWars/SceneObj and editing the scenes.txt in NapoleonicWars to have the scene text and terrain code but the scene doesn’t display in the admin panel nor am I able to play online).

This is the scene text and terrain code I edited in (though had no success with it)
Code:
scn_mp_training_camp mp_Training_camp 256 none none 0.000000 0.000000 100.000000 100.000000 -100.000000 0x0000000730000500000d074800000c960000750900003615
  0
  0
outer_terrain_plain

Thanks in advance. Answer whenever possible, I'll reply.

Best regards,
Fusilier
 
Last edited:
Solution
2. For the modulesystem (ModSys, yes) side of things: in module_presentations.py search for ("game_multiplayer_admin_panel". That should lead you to the start of the admin panel presentation, and in the ti_on_presentation_load trigger of it there is a decently long try_begin/else_try/try_end block that assigns a reference to a mesh to a variable based on what scene is currently selected in the admin panel. You can extend this block with your own else_try to add scenes by yourself.
I'm afraid I can't really help you with actually getting your map screenshot into a mesh and adding it to the game, never done much myself in that area. I guess you could try looking around the files for a bit and try to figure it out yourself or wait...
1. Just replace the outer_terrain_x in the scenes.txt file with the one you want.

2. This is done using the module system - do you know how to use it?

3. To add new maps to the admin panel you once again need the module system.
Another option would be to replace an existing scene with your new one. I'm not very much into NW but looking at my files, your scenes.txt should have a few entries looking like this
Code:
scn_mp_custom_map_1 mp_custom_map_1 256 none none 0.000000 0.000000 100.000000 100.000000 -100.000000 0x00000001300040810005194a0000000000005ae800003c55
  0
  0
 outer_terrain_plain
To add your map, replace the scene code and outer_terrain of the entry with the ones of your scene. Then add your .sco file to the SceneObj folder and name it scn_mp_custom_map_1.sco. You can then start your map ingame by selecting Custom Map 1 in the adminpanel.
(Again, I'm not very into NW so if the custom maps don't show in the adminpanel, you might need to replace another map that does.)
 
Upvote 0
1. Just replace the outer_terrain_x in the scenes.txt file with the one you want.

2. This is done using the module system - do you know how to use it?

3. To add new maps to the admin panel you once again need the module system.
Another option would be to replace an existing scene with your new one. I'm not very much into NW but looking at my files, your scenes.txt should have a few entries looking like this
Code:
scn_mp_custom_map_1 mp_custom_map_1 256 none none 0.000000 0.000000 100.000000 100.000000 -100.000000 0x00000001300040810005194a0000000000005ae800003c55
  0
  0
outer_terrain_plain
To add your map, replace the scene code and outer_terrain of the entry with the ones of your scene. Then add your .sco file to the SceneObj folder and name it scn_mp_custom_map_1.sco. You can then start your map ingame by selecting Custom Map 1 in the adminpanel.
(Again, I'm not very into NW so if the custom maps don't show in the adminpanel, you might need to replace another map that does.)

First of all, hello Namakan :grin:

1. It was that simple. Thank you. I will mark that first question as solved in the original post.

2. Well this one is a bit more tricky. I've received some help and saw some tutorials on using the NW ModSys (that is the module system right?), but I'm no expert. What I believe is that whenever I made changes to the ModSys folder and I launched my now Modded Napoleonic Wars, it became incompatible with every vanilla NW server. I'm weary going that route since I want to be able to play online and host dedicated servers with my custom maps. My knowledge of working with OpenBrf is also very limited. I just think that It would involve Modelling and/or Texturing, neither of which I'm very qualified for. I can take a screenshot and try to assign it somewhere but that's it.

But for the sake of argument, how would you go about it?


3. About using the module system. Doesn't using the module system in conjunction with your module folder make that folder a Mod that is now incompatible with vanilla NW?

In Modules>Napoleonic Wars>scenes.txt I changed
Code:
scn_mp_ambush_fog mp_ambush_fog 256 none none 0.000000 0.000000 100.000000 100.000000 -100.000000 0x000000023002a1ba0004210900003ca000006a8900007a7b
  0
  0
 outer_terrain_plain

into
Code:
scn_mp_training_camp mp_Training_camp 256 none none 0.000000 0.000000 100.000000 100.000000 -100.000000 0x0000000730000500000d074800000c960000750900003615
  0
  0
 outer_terrain_plain

And the end result was that I managed to both open my custom map correctly as well as join multiplayer servers. The only if being that the scene name in the admin panel is "Ambush (Fog)" and the preview image is that of "Ambush (Fog)" - not the custom name and preview image I had created before.

I'd call that a success but tell me, is there a way to change the name "Ambush (Fog)" to something else and also alter the preview image without resorting to making the game a mod, rendering it incompatible for multiplayer purposes?

Thank you for your input.

I also welcome experienced sceners, server owners and moderators/admins to contribute to the discussion.

Best regards,
Fusilier
 
Upvote 0
2. For the modulesystem (ModSys, yes) side of things: in module_presentations.py search for ("game_multiplayer_admin_panel". That should lead you to the start of the admin panel presentation, and in the ti_on_presentation_load trigger of it there is a decently long try_begin/else_try/try_end block that assigns a reference to a mesh to a variable based on what scene is currently selected in the admin panel. You can extend this block with your own else_try to add scenes by yourself.
I'm afraid I can't really help you with actually getting your map screenshot into a mesh and adding it to the game, never done much myself in that area. I guess you could try looking around the files for a bit and try to figure it out yourself or wait for someone else to help out.

3. I'm not sure how NW detects changed modules, sorry.
As for changing the name in the admin panel, that is quite simple: Open strings.txt and search for the original name (make sure to replace all spaces in the name with underscores (_). You can then replace the name with your chosen one, like this:
Code:
#old
str_mp_ambush_fog Ambush_(Fog)
#new
str_mp_ambush_fog Training_Camp
As for the preview image, you should replace the one used for the map you are replacing (if there even is one). You can find the name of the mesh in the code I described regarding question 2, and then maybe you can figure it out from there - Again, I sadly can't really help you here.
That said, having a preview image for your map really isn't important - I don't think I've seen many scenes made by anyone but TaleWorlds that comes with a preview images.
 
Upvote 0
Solution
2. For the modulesystem (ModSys, yes) side of things: in module_presentations.py search for ("game_multiplayer_admin_panel". That should lead you to the start of the admin panel presentation, and in the ti_on_presentation_load trigger of it there is a decently long try_begin/else_try/try_end block that assigns a reference to a mesh to a variable based on what scene is currently selected in the admin panel. You can extend this block with your own else_try to add scenes by yourself.
I'm afraid I can't really help you with actually getting your map screenshot into a mesh and adding it to the game, never done much myself in that area. I guess you could try looking around the files for a bit and try to figure it out yourself or wait for someone else to help out.

3. I'm not sure how NW detects changed modules, sorry.
As for changing the name in the admin panel, that is quite simple: Open strings.txt and search for the original name (make sure to replace all spaces in the name with underscores (_). You can then replace the name with your chosen one, like this:
Code:
#old
str_mp_ambush_fog Ambush_(Fog)
#new
str_mp_ambush_fog Training_Camp
As for the preview image, you should replace the one used for the map you are replacing (if there even is one). You can find the name of the mesh in the code I described regarding question 2, and then maybe you can figure it out from there - Again, I sadly can't really help you here.
That said, having a preview image for your map really isn't important - I don't think I've seen many scenes made by anyone but TaleWorlds that comes with a preview images.

That's 2) dealt with and 3) solved.

Thank you very much Namakan you've been most helpfull.

Going to mark this question as solved now.

Kind regards,
Fusilier
 
Upvote 0
Back
Top Bottom