popsiclestick的最近内容

  1. Modding Q&A [For Quick Questions and Answers]

    Lumos 说:
    I've done quite a bit of work with presentations, and from my experience, it's different for everything. I'm pretty sure it depends on the mesh of the overlay, maybe there's some internal size calculations or something...
    Hopefully someone else knows the specifics... I never managed to figure them out.

    Ah thank you, it's relieving to see that the common operation is a bit confusing for others as well. You helped me quite a bit, and if anyone else still has anymore input on the topic I'd love to hear it!  :razz:
  2. Modding Q&A [For Quick Questions and Answers]

    Hello!

    I'm not exactly used to Mount and Blade code and probably don't even fit into the criteria of a novice programmer. I didn't want to have to make this post, but after searching for at least 2 months on end about this certain topic; I believe it's time to finally ask. How exactly does the operation "overlay_set_size" work? I (hopefully)understand the syntax; however, the use of positional X and Y coordinates to effectively 'scale' a mesh allude me.

    For example, this fragment of code from Napoleonic War's artillery crosshair.
    插入代码块:
          #set_fixed_point_multiplier, 1000
    
    (create_mesh_overlay,reg0,"mesh_white_plane"),
          (overlay_set_color,reg0,0xFF0000),
          (overlay_set_alpha,reg0,0x48),
          (position_set_x,pos1,500),
          (position_set_y,pos1,335),
          (overlay_set_position,reg0,pos1),
    
          (position_set_x,pos1,80),        
          (position_set_y,pos1,2000),                           #2000? woah!
          (overlay_set_size,reg0,pos1),

    Could anyone explain the use of "overlay_set_size" in this circumstance?


    Thanks!

    Here's the rest of the code for reference:
    插入代码块:
      ("multiplayer_cannon_crosshair", prsntf_read_only|prsntf_manual_end_only, 0, [ #MM
        (ti_on_presentation_load,
         [(set_fixed_point_multiplier, 1000),
              
          (assign,"$g_close_crosshair",0),
       
          (create_mesh_overlay,reg0,"mesh_white_plane"),
          (overlay_set_color,reg0,0xFFFFFF),
          (overlay_set_alpha,reg0,0x48),
          (position_set_x,pos1,500),
          (position_set_y,pos1,335),
          (overlay_set_position,reg0,pos1),
          (position_set_x,pos1,80),
          (position_set_y,pos1,2000),
          (overlay_set_size,reg0,pos1),
       
          (create_mesh_overlay,reg0,"mesh_white_plane"),
          (overlay_set_color,reg0,0xFFFFFF),
          (overlay_set_alpha,reg0,0x48),
          (position_set_x,pos1,480),
          (position_set_y,pos1,375),
          (overlay_set_position,reg0,pos1),
          (position_set_x,pos1,2000),
          (position_set_y,pos1,80),
          (overlay_set_size,reg0,pos1),
       
          (create_mesh_overlay,reg0,"mesh_white_plane"),
          (overlay_set_color,reg0,0xFFFFFF),
          (overlay_set_alpha,reg0,0x48),
          (position_set_x,pos1,485),
          (position_set_y,pos1,360),
          (overlay_set_position,reg0,pos1),
          (position_set_x,pos1,1500),
          (position_set_y,pos1,90),
          (overlay_set_size,reg0,pos1),
       
          (create_mesh_overlay,reg0,"mesh_white_plane"),
          (overlay_set_color,reg0,0xFFFFFF),
          (overlay_set_alpha,reg0,0x48),
          (position_set_x,pos1,490),
          (position_set_y,pos1,345),
          (overlay_set_position,reg0,pos1),
          (position_set_x,pos1,1000),
          (position_set_y,pos1,80),
          (overlay_set_size,reg0,pos1),
          
          (presentation_set_duration, 999999),
          ]),
        (ti_on_presentation_run, [
          #(store_trigger_param_1,":cur_time"),
          
          (eq,"$g_close_crosshair",1),
          (presentation_set_duration, 0),
          ]),
        ]),
       
后退
顶部 底部