OSP Kit Campaign Sea Battles Mk. II & Misc Scenes

Users who are viewing this thread

It's a fantastic piece of work alright. I started to AI mesh it, have gotten as far as having the town walkers make it from the upper city to the gate in the lower city, but I suspect it'll all go to hell when I test out battles in there. First time I've done any scene work too, so I expect that when I test the battles, I'll have to rip the whole mesh out and re-apply what I learned. For example, is there any reason not to have street-long pieces of AI mesh? Looking at the native cities, they look a lot different than my splintered glass effect.  :razz:

Also, I am a bit worried about lag with something this size.

Anyway, going on holiday tomorrow so won't be working on this for some time.
 
Malik Faris said:
("join_attack",[((party_get_current_terrain,":terrain","p_main_party"),

i think this parenthesis is extra, build module was giving me problems until i deleted it.
Yeah, probably.

Also, I'm not explaining the second part with the Hello Kitty Island Adventure stuff. I might be more inclined to post the codes if I hadn't just deleted everything to do with M&B from my comp. So... Enjoy!
 
Josef_the_Pretender said:
... is there any reason not to have street-long pieces of AI mesh? Looking at the native cities, they look a lot different than my splintered glass effect.  :razz:

Also, I am a bit worried about lag with something this size.

The only problem with street-length slices of AI mesh is that the NPCs can sometimes get confused if the individual mesh "boxes" are too big.  For getting them from one end of the street to another, though, it shouldn't be much of a problem.  The only other consideration is that the NPCs will always choose the shortest route to where they want to go, so you might end up with every single one of them taking the same direction every time, rather than loads of them swarming up multiple streets at once - which would be very cool, and possibly more realistic.

I'm not sure if a big AI mesh will cause any lag, especially compared to the size of the city and the number of scene props in it.  There might be a short pause at the start of battle, but once they've calculated where they're going, the battle will go as normal.  Hopefully.  :grin:
 
This is fantastic!
I have two questions:
One is:
You think it is possible that the two sides start with the boats away at the start of the battle.
And during the approaching battle. In this way would use ranged weapons first and then fight in melee?

The other is:
You plan to make the lords and caravans also sail?
It would be great!

You can even add to the coastal cities and an icon representing a port and from there they were connected maritime trade routes in cities.

Anyway: GREAT JOB! THIS IS GREAT!

See ya!
 
Digging this up to mention that the AI mesh for the city has been applied and the file is at:

All standard entry points have been created, and just grouped inside the gate, so you can rearrange them as you wish. That also means that if you swap this file with any city centre scene in Warband (and rename as scn_town_6_center for example), you can access it through the 'Take a Walk around the Streets' option.

Player entry points are at the gate (1) and in the 'parade ground'* (0). There's a town walker who starts up at the citadel too, and makes his way down to the gate. I've tested some battles as well, with the defenders spawning at the citadel and the player at the gate, and they make their way down there all right.

I didn't mesh the rooftops, nor did I add any merchant stalls etc.

*lol
wbparadeoverview1.jpg
 
Last edited by a moderator:
No worries  :smile:

Also, I forgot, if you're using this scene as a standard city template as I described, you'll have to generate a bigger terrain to plonk it down in. The one I used (which is far too big, takes a while to load) is a substitute for Praven and is (module_scenes.py) :

Code:
# Normal Praven commented out
  # ("town_6_center",sf_generate,"none", "none", (0,0),(100,100),-100,"0x00000002300491830004a529000036230000312a00003653",
    # [],[],"outer_terrain_plain"),

# New city + terrain
  ("town_6_center",sf_generate,"none", "none",(0,0),(240,240),-0.5,"0x00000000d0104500000d1748000029a800002b7800002eca",
    [],[],"outer_terrain_desert"),

By the way, I remember someone mentioning line of sight. Ideally in a scene like this you would have enemy troops lurking around corners, and only moving into alarmed status when the player strays into their line of sight. Is this now possible?
 
Hey there I just used your code on a WIP experimental mod I am making and I can't find for the life of me how to make the loot screen appear after the sea battles.
Some help would be appreciated.
 
You need add code to mision templates.
By example, I copy here code I use for help you:

Code:
    (
    "ship_battle",mtf_battle_mode,-1,
    "You close in and board the enemy ships",
    [(0,mtef_attackers|mtef_team_1,af_override_horse,aif_start_alarmed,4,[]),
    (1,mtef_attackers|mtef_team_1,af_override_horse,aif_start_alarmed,4,[]),
    (2,mtef_attackers|mtef_team_1,af_override_horse,aif_start_alarmed,4,[]),
    (3,mtef_attackers|mtef_team_1,af_override_horse,aif_start_alarmed,4,[]),
    (4,mtef_attackers|mtef_team_1,af_override_horse,aif_start_alarmed,4,[]),
    (5,mtef_attackers|mtef_team_1,af_override_horse,aif_start_alarmed,4,[]),
    (6,mtef_attackers|mtef_team_1,af_override_horse,aif_start_alarmed,4,[]),     
    (7,mtef_attackers|mtef_team_1,af_override_horse,aif_start_alarmed,4,[]),
    (10,mtef_defenders|mtef_team_0,af_override_horse,aif_start_alarmed,4,[]),
    (11,mtef_defenders|mtef_team_0,af_override_horse,aif_start_alarmed,4,[]),
    (8,mtef_defenders|mtef_team_0,af_override_horse,aif_start_alarmed,4,[]),
    (9,mtef_defenders|mtef_team_0,af_override_horse,aif_start_alarmed,4,[]),
    (12,mtef_defenders|mtef_team_0,af_override_horse,aif_start_alarmed,4,[]),
    (13,mtef_defenders|mtef_team_0,af_override_horse,aif_start_alarmed,4,[]),
    (14,mtef_defenders|mtef_team_0,af_override_horse,aif_start_alarmed,4,[]),
    (15,mtef_defenders|mtef_team_0,af_override_horse,aif_start_alarmed,4,[]),
     ],
    [
      (ti_on_agent_spawn, 0, 0, [],
       [
         (store_trigger_param_1, ":agent_no"),
         (call_script, "script_agent_reassign_team", ":agent_no"),
         ]),
   
      common_battle_init_banner, #sets heraldry on shields and armor

     (ti_on_agent_killed_or_wounded, 0, 0, [],
       [
        (store_trigger_param_1, ":dead_agent_no"),
        (store_trigger_param_2, ":killer_agent_no"),
        (store_trigger_param_3, ":is_wounded"),

        (try_begin),
          (ge, ":dead_agent_no", 0),
          (neg|agent_is_ally, ":dead_agent_no"),
          (agent_is_human, ":dead_agent_no"),
          (agent_get_troop_id, ":dead_agent_troop_id", ":dead_agent_no"),
          (str_store_troop_name, s6, ":dead_agent_troop_id"),
          (assign, reg0, ":dead_agent_no"),
          (assign, reg1, ":killer_agent_no"),
          (assign, reg2, ":is_wounded"),
          (agent_get_team, reg3, ":dead_agent_no"),         
          #(display_message, "@{!}dead agent no : {reg0} ; killer agent no : {reg1} ; is_wounded : {reg2} ; dead agent team : {reg3} ; {s6} is added"),
          (party_add_members, "p_total_enemy_casualties", ":dead_agent_troop_id", 1), #addition_to_p_total_enemy_casualties
          (eq, ":is_wounded", 1),
          (party_wound_members, "p_total_enemy_casualties", ":dead_agent_troop_id", 1),
        (try_end),
       ]),
     
      (0, 0, ti_once, [], [
          (assign,"$g_battle_won",0),
                           (assign,"$defender_reinforcement_stage",0),
                           (assign,"$attacker_reinforcement_stage",0),
#                           (assign,"$g_presentation_battle_active", 0),
                           (call_script, "script_place_player_banner_near_inventory"),
                           (call_script, "script_combat_music_set_situation_with_culture"),
                           ]),
      common_music_situation_update,
      common_battle_check_friendly_kills,

      (1, 0, 5, [(lt,"$defender_reinforcement_stage",2),
                 (store_mission_timer_a,":mission_time"),
                 (ge,":mission_time",10),
                 (store_normalized_team_count,":num_defenders", 0),
                 (lt,":num_defenders",6),
#                 (assign, reg2, ":num_defenders"),
#                 (display_message,"@num_defenders = {reg2}")
                 ],
           [(add_reinforcements_to_entry,0,7),(val_add,"$defender_reinforcement_stage",1)]),
     
      (1, 0, 5, [(lt,"$attacker_reinforcement_stage",2),
                 (store_mission_timer_a,":mission_time"),
                 (ge,":mission_time",10),
                 (store_normalized_team_count,":num_attackers", 1),
                 (lt,":num_attackers",6),
#                 (assign, reg2, ":num_attackers"),
#                 (display_message,"@num_attackers = {reg2}")
                 ],
           [(add_reinforcements_to_entry,3,7),(val_add,"$attacker_reinforcement_stage",1)]),
     
      common_battle_check_victory_condition,
      common_battle_victory_display,
      common_battle_tab_press,
	  common_drowning,
      
(ti_question_answered, 0, 0, [],
       [(store_trigger_param_1,":answer"),
        (eq,":answer",0),
        (assign, "$pin_player_fallen", 0),
        (try_begin),
          (store_mission_timer_a, ":elapsed_time"),
          (gt, ":elapsed_time", 20),
          (str_store_string, s5, "str_retreat"),
          (call_script, "script_simulate_retreat", 10, 20, 1),
        (try_end),
        (call_script, "script_count_mission_casualties_from_agents"),
        (finish_mission,0),]),

      (1, 4, ti_once, [(main_hero_fallen)],
          [
              (assign, "$pin_player_fallen", 1),
              (str_store_string, s5, "str_retreat"),
              (call_script, "script_simulate_retreat", 10, 20),
              (assign, "$g_battle_result", -1),
              (set_mission_result,-1),
              (call_script, "script_count_mission_casualties_from_agents"),
              (finish_mission,0)]),
#Wulf end
      ],
    ),
 
Ok - uhm.. :???:  2 Questions. Why's it not working? And do I need to put the rest of those scenes in, the island and Sarranid scenes? haha thanks man
 
There is a problem, i am getting an error about a line 4112 which is ")," and whenever i delete it, this time other ones keep giving error and so it continues...is there something wrong with this tutorial or can someone send me the module_file which is inserted already?

regards,
 
now all we need is ships in Mount and Musket, for some epic fun

and wouldnt there be a possibility regardless to make a script thatd disallow horsemen, much like there are some maps that dont allow archers. I'm sure there is a way
 
Back
Top Bottom