OSP Kit Optimisation Warband Module System 1.166 (with tweaks and giggles)

Users who are viewing this thread

I found in Viking Conquest more something interesting, two new mapped script. Replace hardcoded presentations?

Code:
("game_troop_upgrades_button_clicked",
  [
    (store_script_param, reg0, 1),
    (start_presentation, "prsnt_game_troop_tree"),
  ]),

Code:
("game_character_screen_requested",
  [
    (try_begin),
      (eq, "$on_map", 1),
      (set_trigger_result, 1),
      (start_presentation, "prsnt_character_screen_main"),
    (else_try),
      (set_trigger_result, 0),
    (try_end),
  ]),
 
Okay, a brief test demonstrated that "script_game_character_screen_requested" does indeed work, though the operation (map_free) apparently always fails within the script (which probably explains why VC version of the script is using a global instead, with it's value initialized from outside of script).

However I can't make "script_game_troop_upgrades_button_clicked" to fire - not sure what I'm supposed to do to fire it, but clicking on upgrade buttons on the party screen doesn't seem to work.
 
Lav said:
Okay, a brief test demonstrated that "script_game_character_screen_requested" does indeed work, though the operation (map_free) apparently always fails within the script (which probably explains why VC version of the script is using a global instead, with it's value initialized from outside of script).

However I can't make "script_game_troop_upgrades_button_clicked" to fire - not sure what I'm supposed to do to fire it, but clicking on upgrade buttons on the party screen doesn't seem to work.
I believe that is a button not present in native, but only in VC. See here:
0Gn94.jpg
Of course, this means that either they made a new presentation for the party screen, which is easily doable, or the party screen is now moddable, which might mean also that garrison management modding might be possible without losing the xp-information. But I am not holding my breath. The garrison management/troop exchange screen still looks pretty native with regards to the features.
 
Can you PM me module.ini and game_variables.txt files from VC module folder? I strongly suspect the button is governed by one of them. Or maybe presentation is the key. I'll have to test it some more tomorrow it seems...
 
K700 said:
Trigger param 4 for ti_on_agent_hit - hit bone. Viking Conquest decompiled script http://prntscr.com/63h97j
The names of the bones can be taken from WSE.

#Human bones
hb_abdomen = 0
hb_thigh_l = 1
hb_calf_l = 2
hb_foot_l = 3
hb_thigh_r = 4
hb_calf_r = 5
hb_foot_r = 6
hb_spine = 7
hb_thorax = 8
hb_head = 9
hb_shoulder_l = 10
hb_upperarm_l = 11
hb_forearm_l = 12
hb_hand_l = 13
hb_item_l = 14
hb_shoulder_r = 15
hb_upperarm_r = 16
hb_forearm_r = 17
hb_hand_r = 18
hb_item_r = 19

#Horse bones
hrsb_pelvis = 0
hrsb_spine_1 = 1
hrsb_spine_2 = 2
hrsb_spine_3 = 3
hrsb_neck_1 = 4
hrsb_neck_2 = 5
hrsb_neck_3 = 6
hrsb_head = 7
hrsb_l_clavicle = 8
hrsb_l_upper_arm = 9
hrsb_l_forearm = 10
hrsb_l_hand = 11
hrsb_l_front_hoof = 12
hrsb_r_clavicle = 13
hrsb_r_upper_arm = 14
hrsb_r_forearm = 15
hrsb_r_hand = 16
hrsb_r_front_hoof = 17
hrsb_l_thigh = 18
hrsb_l_calf = 19
hrsb_l_foot = 20
hrsb_l_back_hoof = 21
hrsb_r_thigh = 22
hrsb_r_calf = 23
hrsb_r_foot = 24
hrsb_r_back_hoof = 25
hrsb_tail_1 = 26
hrsb_tail_2 = 27

This is just what I need most from WSE. It's nice to have it on native MS.
 
Okay, thanks to DerGrief:

Code:
show_troop_upgrades_button = 1
Voila!

And some more new options:

Code:
operation_set_version = 1165
So the operations set version is defined in module.ini? I fail to see how it makes sense - module.ini is part of the module, not engine. So if you install a module with 1.182 operations set on 1.165 engine, the code will happily "detect" that the current engine supports 1.182 ops and proceeds to generate tons of errors? Either I'm missing something, or this new feature is a big failure.

Code:
supports_directx_7 = 0
Nice.

Code:
reduce_texture_loader_memory_usage = 1
Interesting and potentially critical.

Code:
use_case_insensitive_mesh_searches = 1
Well, useful, I guess.

Code:
use_texture_degration_cache = 1
Very interesting and worth some testing.

Code:
use_scene_unloading = 1
Memory saving? Always useful.

Code:
map_min_elevation = 0.5  #maximum zoom
# map_max_elevation = 1.0  #minimum zoom
Nice!

Code:
auto_compute_party_radius = 1 #helps space, select if mod has large icons
Meh. Stuff for lazy modders.

Code:
disable_disband_on_terrain_type = 0
Wut? Something to do with zero-sized parties on specific terrain type? Ships perhaps?

Code:
use_strict_pathfinding_for_ships = 1 #keeps ships at sea for sea-to-sea routes
Fantastic!

Code:
disable_force_leaving_conversations = 1 #no TAB end in conversations.
Er... you could? :oops:

Code:
#New leveling system
skill_points_per_level = 2
attribute_points_per_level = 0.195 #0.125
weapon_points_per_level = 5
level_boundary_multiplier = 2.0
attribute_required_per_skill_level = 2
We already know and love these.

Code:
#scenes
far_plane_distance = 2000 #Default is 1250 cm
Great for scene modelers, though they probably already know about this one.

Code:
battle_size_min = 150
battle_size_max = 750
Again, we already know this one.

Code:
blood_multiplier = 6.0 #chief aumentado
Cue evil laughter...

Code:
consider_weapon_length_for_weapon_quality = 1 #weapon selection
Very interesting. Makes NPCs select weapons more intelligently? I definitely want to check this one.

Code:
#use_explicit_couch_flag = 1
Not sure what it does, but I have an educated guess it somehow affects couching. :cool:
 
Lav said:
Code:
disable_disband_on_terrain_type = 0
Wut? Something to do with zero-sized parties on specific terrain type? Ships perhaps?

I believe this is so that you cant disband troops in the middle of the sea, not a party :razz:
 
Ikaguia said:
I believe this is so that you cant disband troops in the middle of the sea, not a party :razz:
Ah. So to preserve the historical accuracy, the option should be set to zero. Got it. :grin:
 
Lav said:
Code:
auto_compute_party_radius = 1 #helps space, select if mod has large icons
Meh. Stuff for lazy modders.

I think this one recomputes the party's mouse selection hitbot based on the icon's bounding box,
instead of using a predefined smallish cube for detecting selection clicks deep in its center.

TLD and SWC also have much bigger map icons than Native's and finding a place to click them is still a problem.

--

Thanks for publishing all that exclusive modding wealth, by the way.
Seems like we can now do stuff that years ago would be beyond impossible.

And I'm well aware that things like Iron Launcher and WSE contributed to get modder features into the game.
 
Trigger Param 3 for ti_on_scene_prop_hit - attacker agent id. It's serverside only. For client side can still use "Position Register 2: x holds attacker agent id"
 
Thanks!

You're doing a great job researching that obscure stuff!

UPD: updated the starting post with your intel. I guess I'll be waiting for some time before updating the archive itself, as hopefully you'll find a few more tidbits. :smile:
 
I experiment and found that the ti_on_scene_prop_hit  trigger from 1166 is fully consistent version of WSE

ti_on_scene_prop_hit = -42.0 #can only be used in module_scene_props triggers
# Trigger Param 1: prop instance no
# Trigger Param 2: inflicted damage (server only)
# Trigger Param 3: dealer agent no (server only)
# Trigger Param 4: item kind no (server only)
# Trigger Param 5: item modifier (server only)
# Trigger Param 6: missile item kind no (server only)
# Trigger Param 7: missile item modifier (server only)
# Position Register 1: Hit Position
# Position Register 2: x holds dealer agent no
 
Back
Top Bottom