Heraldic Armor (Need assistance)

正在查看此主题的用户

Leopold DK

Regular
Hello guys and the few girls.

I'm trying to change the original "Cuir Bouili" into a "Heraldic Cuir Bouili" in the mod called Mercenaries. But the problem is, that it shows like this ingame:

fRPd3.png


Do any of you know the solution to this problem, then please tell me! :smile:



Regards Leopold
 
What shader are you using? I might want to make ghosts sometime soon. so I'm curious :grin:
 
I'm using those;

simple_shader
specular_shader_skin
iron_shader


And do you have any experience with Heraldic armor? :p
 
8Leopold8 说:
I'm using those;

simple_shader
specular_shader_skin
iron_shader


And do you have any experience with Heraldic armor? :p

I'm not exactly experienced at it, but i have some that work in front of me.

They use weird shaders it looks like. Here are the flags on the material:
https://i.gyazo.com/3993f7957a136b7df48d2629b64ccc9e.png

Some sort of weird blending.

also it uses
simple_shader_no_mip

Can you share more about what you have? It will help use tell you how to fix it.
 
Ramaraunt 说:

Turns out he was trying to do it all with text files. Might be possible, but its hard that way. I got him set up with a module system now, so at least he has a chance of figuring this out. But I really don't understand tableaus that well, can't find a tutorial. Anyone?
 
There is a nice guilde that helped me in the past, but it's in Russian:
http://rusmnb.ru/index.php?topic=13838.msg532361#msg532361
 
Leonion 说:
There is a nice guilde that helped me in the past, but it's in Russian:
http://rusmnb.ru/index.php?topic=13838.msg532361#msg532361

I tried to understand the translate, but didn't get anything out of it. :smile: Do you know any other guides?
 
You need to first add the tableau and associated meshes (at the bottom), then find the actual offset values and generate the tableau code as well as the item's trigger code based off the existing heraldic item in
插入代码块:
item_kinds1.txt
Normal code looks like this
插入代码块:
 itm_cuir_bouilli Cuir_Bouilli Cuir_Bouilli 1  cuir_bouilli_a 0  16842765 0 3100 704643236 24.000000 100 0 50 15 8 0 0 0 0 0 0 0
 0
0
Whereas heraldic items have a trigger (notice the 1 on the 3rd line) and look like
插入代码块:
 itm_heraldic_mail_with_tabard Heraldic_Mail_with_Tabard Heraldic_Mail_with_Tabard 1  heraldic_armor_new_d 0  16842765 0 3654 704643236 21.000000 100 0 51 15 7 0 0 0 0 0 0 0
 0
1
-50.000000  3 2071 1 1224979098644774912 2072 1 1224979098644774913 1 4 936748722493063582 1729382256910270491 1224979098644774912 1224979098644774913
The actual heraldic code looks something like this
def heraldic(item_tableau):
  return (ti_on_init_item, [(store_trigger_param_1, ":agent_no"),(store_trigger_param_2, ":troop_no"),(call_script, "script_shield_item_set_banner", item_tableau, ":agent_no", ":troop_no")])
Which corresponds to these numbers in particular in the above example
936748722493063582 1729382256910270491
So you need to open up the itemkinds and calculate it yourself, since the script will be the same for all heraldic items whereas the tableau reference will be different. This allows you to get the item to apply a tableau, but you still need to add the right tableau into the game.
Native has example code which all heraldic items use (more or less)
插入代码块:
  ("heraldic_armor_d", 0, "sample_heraldic_armor_d", 512, 512, 0, 0, 0, 0,
   [
       (store_script_param, ":banner_mesh", 1),

       (set_fixed_point_multiplier, 100),
       (store_sub, ":background_slot", ":banner_mesh", arms_meshes_begin), #banner_meshes_begin),
       (troop_get_slot, ":background_color", "trp_banner_background_color_array", ":background_slot"),
       (cur_tableau_set_background_color, ":background_color"),

       (init_position, pos1),
       (cur_tableau_add_mesh_with_vertex_color, "mesh_heraldic_armor_bg", pos1, 200, 100, ":background_color"),
       (init_position, pos1),
       (position_set_z, pos1, 10),
       (position_set_x, pos1, -0),
       (position_set_y, pos1, 130),
       (cur_tableau_add_mesh, ":banner_mesh", pos1, 113, 0),
#       (cur_tableau_add_mesh, "mesh_banner_a01", pos1, 116, 0),
       (init_position, pos1),
       (position_set_z, pos1, 100),
       (cur_tableau_add_mesh, "mesh_tableau_mesh_heraldic_armor_d", pos1, 0, 0),
       (cur_tableau_set_camera_parameters, 0, 200, 200, 0, 100000),
       ]),
Using the same principles, find the actual values for setting pos1's coordinates (because it will be different for every armor) and where "mesh_tableau_mesh_heraldic_armor_d" is called in
插入代码块:
 tableau_materials.txt
. You need to now open up
插入代码块:
meshes.txt
and add the cuir bouilli stuff at the bottom, then calculate the offset (like you did for the tableau reference).
 
后退
顶部 底部