• Welcome to the forums on our new hosting setup. Everything should be working the same, but if you run into any problems, please let us know over here.

OSP Code Campaign Wagon System - UPDATED 06/08/2011 - Final Version

Users who are viewing this thread

Ikaguia

Grandmaster Knight
WBWF&SNW
Wagon System

It is now complete, and hopefully without bugs.
  • What does it do?
    • It allows you to make wagons and carts that can be pulled by Bull, oxen, horse or prisioner.
  • Where are the screen shoots?
    • Nowhere, I didn't take any because I don't think it is really necessary, but if anybody take any, fell free to post them.

The code:
Code:
      ("go_to_camp_inventory",[],"Manage your party equipments.",
       [(assign, "$brc_camp_inv", 1),
	    (jump_to_menu, "mnu_camp_inventory"),]),
Code:
  ("camp_inventory",0,
   "What do you want to do?^^To acess your wagon or carts inventory,^talk with them on the map,^to make new ones the items must be on your inventory.",
   "none",
   [],
    [
#      ("info",[(disable_menu_option)],"To acess your wagon or carts inventory, talk with them on the map,^to make new ones the items must be on your inventory.^Only native horses can be used for this.",
#      []),
      ("make_wagon",[(eq, "$brc_camp_inv", 1),],"Make a new Wagon.",
       [(assign, "$brc_camp_inv", 2),]),
      ("make_2_ox_wagon", [(eq, "$brc_camp_inv", 2),],"Make a new Wagon(1 heavy wagon & 2 Oxes/Bulls).",
       [(assign, reg7, 1),
		(val_add, reg4, reg7),
		(val_sub, reg4, 1),
		(troop_clear_inventory,reg4),
		(try_begin),
		  (troop_slot_ge, reg4, slot_inventory_used, 1),
		  (str_store_string, s13, "@You already have a {s0}"),
		(else_try),
		  (jump_to_menu,"mnu_build_inventory"),
		(try_end),
        ]),
      ("make_1_horse_wagon",[(eq, "$brc_camp_inv", 2),],"Make a new Wagon(1 light wagon & 1 horse).",
       [(assign, reg7, 2),
		(val_add, reg4, reg7),
		(val_sub, reg4, 1),
		(troop_clear_inventory,reg4),
		(try_begin),
		  (troop_slot_ge, reg4, slot_inventory_used, 1),
		  (str_store_string, s13, "@You already have a {s0}"),
		(else_try),
		  (jump_to_menu,"mnu_build_inventory"),
		(try_end),
        ]),
      ("make_2_horse_wagon",[(eq, "$brc_camp_inv", 2),],"Make a new Wagon(1 wagon & 2 horses).",
       [(assign, reg7, 3),
		(val_add, reg4, reg7),
		(val_sub, reg4, 1),
		(troop_clear_inventory,reg4),
		(try_begin),
		  (troop_slot_ge, reg4, slot_inventory_used, 1),
		  (str_store_string, s13, "@You already have a {s0}"),
		(else_try),
		  (jump_to_menu,"mnu_build_inventory"),
		(try_end),
        ]),
      ("make_4_horse_wagon",[(eq, "$brc_camp_inv", 2),],"Make a new Wagon(1 heavy wagon & 4 horses).",
       [(assign, reg7, 4),
		(val_add, reg4, reg7),
		(val_sub, reg4, 1),
		(troop_clear_inventory,reg4),
		(try_begin),
		  (troop_slot_ge, reg4, slot_inventory_used, 1),
		  (str_store_string, s13, "@You already have a {s0}"),
		(else_try),
		  (jump_to_menu,"mnu_build_inventory"),
		(try_end),
        ]),
      ("make_cart",[(eq, "$brc_camp_inv", 1),],"Make a new  Cart.",
       [(assign, "$brc_camp_inv", 3),]),
      ("make_2_wheled_cart",[(eq, "$brc_camp_inv", 3),],"Make a new Cart(1 cart & 1 prisioner).",
       [(assign, reg7, 5),
		(val_add, reg4, reg7),
		(val_sub, reg4, 1),
		(troop_clear_inventory,reg4),
		(try_begin),
		  (troop_slot_ge, reg4, slot_inventory_used, 1),
		  (str_store_string, s13, "@You already have a {s0}"),
		(else_try),
		  (jump_to_menu,"mnu_build_inventory"),
		(try_end),
        ]),
      ("make_2_wheled_cart",[(eq, "$brc_camp_inv", 3),],"Make a new Cart(1 cart & 2 prisioners).",
       [(assign, reg7, 6),
		(val_add, reg4, reg7),
		(val_sub, reg4, 1),
		(troop_clear_inventory,reg4),
		(try_begin),
		  (troop_slot_ge, reg4, slot_inventory_used, 1),
		  (str_store_string, s13, "@You already have a {s0}"),
		(else_try),
		  (jump_to_menu,"mnu_build_inventory"),
		(try_end),
        ]),
      ("make_2_wheled_cart",[(eq, "$brc_camp_inv", 3),],"Make a new Cart(1 cart & 4 prisioners).",
       [(assign, reg7, 7),
		(val_add, reg4, reg7),
		(val_sub, reg4, 1),
		(troop_clear_inventory,reg4),
		(try_begin),
		  (troop_slot_ge, reg4, slot_inventory_used, 1),
		  (str_store_string, s13, "@You already have a {s0}"),
		(else_try),
		  (jump_to_menu,"mnu_build_inventory"),
		(try_end),
        ]),
	   
	   
      ("back_to_camp_menu",[(neq, "$brc_camp_inv", 1)],"Back to camp inventory menu.",
       [(assign, "$brc_camp_inv", 1),(jump_to_menu, "mnu_camp_inventory"),]),
      ("back_to_camp_menu",[(eq, "$brc_camp_inv", 1)],"Back to camp menu.",
       [(assign, "$brc_camp_inv", 1),(jump_to_menu, "mnu_camp"),]),
      ]
  ),
  
  ("build_inventory",0,
   "This shall not be displayed.",
   "none",
   [(try_begin),
		(eq, reg7, 1),
		(assign, reg1, 7),
		(assign, reg3, "pt_dual_ox_wagon"),
	(else_try),
		(eq, reg7, 2),
		(assign, reg1, 3),
		(assign, reg3, "pt_single_horse_wagon"),
	(else_try),
		(eq, reg7, 3),
		(assign, reg1, 4),
		(assign, reg3, "pt_double_horse_wagon"),
	(else_try),
		(eq, reg7, 4),
		(assign, reg1, 6),
		(assign, reg3, "pt_four_horse_wagon"),
	(else_try),
		(ge, reg7, 5),
		(assign, reg1, 2),
		(assign, reg3, "pt_double_wheled_cart"),
	(try_end),
	(assign, "$rest_time", reg1),
	(set_spawn_radius,0),
	(spawn_around_party,"p_main_party",reg3),
	(str_store_party_name, s0, reg0),
	(party_stack_get_troop_id, reg4, reg0,0),
	(party_remove_members, reg0, reg4, 1),
	(troop_clear_inventory, reg4),
	(party_add_leader,reg0,"trp_wagon_rider"),
	(try_begin),
		(troop_slot_eq, reg4, slot_inventory_used, 1),
		(assign, reg2, 1),
	(else_try),
		(assign, reg2, 0),
	(try_end),
	(jump_to_menu, "mnu_build_inventory2"),],
    [
      ("back",[],"Back.",[]),
      ]),
  
  ("build_inventory2",0,
   "Building a {s0} will take {reg1} {reg1?hours:hour}.",
   "none",
   [],
    [
      ("build",[(neq, reg2, 1),],"Give the necessary items.",[(change_screen_loot, "trp_temp_array_b"),]),
      ("build",[(neq, reg2, 1),
	            (ge, reg7, 5),],"Give the prisioners.",
		   [(party_get_num_prisoners,":slaves","p_main_party"),
			(try_begin),
			  (eq, reg7, 5),
			  (assign, reg6, 1),
			(else_try),
			  (eq, reg7, 6),
			  (assign, reg6, 2),
			(else_try),
			  (eq, reg7, 7),
			  (assign, reg6, 4),
			(try_end),
			(try_begin),
			  (ge, ":slaves", reg6),
			  (try_for_range, ":prisioner", 1, num_troops),
				(party_count_prisoners_of_type,":count","p_main_party",":prisioner"),
				(val_min, ":count", reg6),
				(party_remove_prisoners,"p_main_party",":prisioner",":count"),
				(party_force_add_prisoners,reg0,":prisioner",":count"),
				(val_sub, reg6, ":count"),
			  (try_end),
			(else_try),
			  (disable_menu_option),
			  (display_message,"@You don't have enought prisioners"),
			(try_end),
	   ]),
      ("build",[(neq, reg2, 1),
				(assign, ":horses", 0),
				(assign, ":bulls", 0),
				(assign, ":l_wagons", 0),
				(assign, ":m_wagons", 0),
				(assign, ":h_wagons", 0),
				(assign, ":carts", 0),
				(store_num_regular_prisoners,":slaves",reg0),
				(troop_get_inventory_capacity,":capacity","trp_temp_array_b"),
				(try_for_range,":slot",0,":capacity"),
				  (troop_get_inventory_slot,":cur_item","trp_temp_array_b",":slot"),
				  (try_begin),
				    (this_or_next|eq, ":cur_item", "itm_bull"),
				    (eq, ":cur_item", "itm_ox"),
				    (val_add,":bulls",1),
				  (else_try),
					(item_get_type, ":type", ":cur_item"),#v0.5
					(eq, ":type", itp_type_horse),#v0.5
				    (val_add,":horses",1),
				  (else_try),
				    (eq, ":cur_item", "itm_light_wagon"),
				    (val_add,":l_wagons",1),
				  (else_try),
				    (eq, ":cur_item", "itm_wagon"),
				    (val_add,":m_wagons",1),
				  (else_try),
				    (eq, ":cur_item", "itm_heavy_wagon"),
				    (val_add,":h_wagons",1),
				  (else_try),
				    (eq, ":cur_item", "itm_2wheeled_cart"),
					(val_add,":carts", 1),
				  (try_end),
				(try_end),
				(try_begin),
				  (eq, reg7, 1),
				  (ge, ":bulls", 2),
				  (ge, ":h_wagons", 1),
				(else_try),
				  (eq, reg7, 2),
				  (ge, ":horses", 2),
				  (ge, ":l_wagons", 1),
				(else_try),
				  (eq, reg7, 3),
				  (ge, ":horses", 2),
				  (ge, ":m_wagons", 1),
				(else_try),
				  (eq, reg7, 4),
				  (ge, ":horses", 2),
				  (ge, ":h_wagons", 1),
				(else_try),
				  (eq, reg7, 5),
				  (ge, ":slaves", 1),
				  (ge, ":carts", 1),
				(else_try),
				  (eq, reg7, 6),
				  (ge, ":slaves", 2),
				  (troop_raise_skill,reg4,"skl_inventory_management",1),
				  (ge, ":carts", 1),
				(else_try),
				  (eq, reg7, 7),
				  (ge, ":slaves", 4),
				  (ge, ":carts", 1),
				  (troop_raise_skill,reg4,"skl_inventory_management",2),
				(else_try),
				  (disable_menu_option),
				(try_end),
                  ],"Start building.",
       [(store_current_hours, ":hours"),
		(store_add, "$rest_time", ":hours", reg1),
		(assign, "$visit_after_rest", "mnu_builded_inventory"),
		(assign, "$atackable", 1),
		(troop_set_slot, reg4, slot_inventory_used, 1),
		(assign, "$currently_building", reg0),
		(call_script, "script_copy_inventory", "trp_temp_array_b", reg4),
		(party_set_slot, reg0, slot_party_inventory_troop, reg4),
	    (rest_for_hours, reg1, 5, 1), #rest while attackable
        (change_screen_map),
        ]),
      ("back",[],"Back.",
       [(troop_get_inventory_capacity,":capacity","trp_temp_array_b"),
		(assign, ":continue", 1),
		(try_for_range,":slot",0,":capacity"),
		  (troop_get_inventory_slot,":cur_item","trp_temp_array_b",":slot"),
		  (gt, ":cur_item", 0),
		  (assign, ":continue", 0),
		(try_end),
		(try_begin),
		  (eq, ":continue", 1),
		  (try_for_range, ":prisioner", 1, num_troops),
				(party_count_prisoners_of_type,":count",reg0,":prisioner"),
				(party_remove_prisoners,reg0,":prisioner",":count"),
				(party_force_add_prisoners,"p_main_party",":prisioner",":count"),
		  (try_end),
		  (remove_party,reg0),
		  (assign, "$brc_camp_inv", 1),
		  (troop_set_slot, reg4, slot_inventory_used, 0),
		  (assign, "$visit_after_rest", 0),
		  (jump_to_menu, "mnu_camp_inventory"),
		(else_try),
		  (display_message,"@Please, retrieve your items before leaving"),
		(try_end),]),
      ]),
  
  ("builded_inventory",0,"{s0}.","none",
	[(assign, reg0, "$currently_building"),
	(try_begin),
		(store_current_hours, ":hours"),
		(eq, "$rest_time", ":hours"),
		(party_get_slot, reg4, reg0, slot_party_inventory_troop),
		(troop_clear_inventory, reg4),
		(troop_set_slot, reg4, slot_inventory_used, 0),
		(remove_party, reg0),
		(str_store_string, s0, "@You haven't builded your {s0} and you have lost your items"),
	(else_try),
		(str_store_party_name, s0, reg0),
		(str_store_string, s0, "@You have builded a {s0}"),
	(try_end),],
	[
	  ("continue",[],"Continue.",[
		(assign, "$brc_camp_inv", 1),
		(party_set_ai_patrol_radius,reg0,1),
		(party_set_ai_behavior,reg0,ai_bhvr_escort_party),
		(party_set_ai_object,reg0,"p_main_party"),
		(jump_to_menu, "mnu_camp_inventory"),]),
	]
  ),
Code:
 ["light_wagon",		"Light Wagon",				[("ale_barrel",0)],		itp_merchandise|itp_type_goods,	0, 1500,weight(500)|abundance(10),imodbits_none],
 ["wagon",				"Wagon",					[("ale_barrel",0)],		itp_merchandise|itp_type_goods,	0, 2300,weight(630)|abundance(15),imodbits_none],
 ["heavy_wagon",		"Heavy Wagon",				[("ale_barrel",0)],		itp_merchandise|itp_type_goods,	0, 3000,weight(750)|abundance(8),imodbits_none],
 ["2wheeled_cart",		"Two Wheeled Cart",			[("ale_barrel",0)],		itp_merchandise|itp_type_goods,	0, 570,	weight(98)|abundance(70),imodbits_none],
 ["ox",					"Ox(wrong model yet)",		[("sumpter_horse",0)],	itp_merchandise|itp_type_horse,	0, 414,	abundance(50)|hit_points(450)|body_armor(14)|difficulty(1)|horse_speed(23)|horse_maneuver(17)|horse_charge(21)|horse_scale(120),0],
 ["bull",				"Bull(wrong model yet)",	[("sumpter_horse",0)],	itp_merchandise|itp_type_horse,	0, 434,	abundance(45)|hit_points(500)|body_armor(14)|difficulty(3)|horse_speed(27)|horse_maneuver(13)|horse_charge(29)|horse_scale(120),0],
Code:
  ("dual_ox_wagon",				"Dual Ox Wagon",			icon_mule,			0,fac_commoners,courage_15|aggressiveness_0,[(trp_dual_ox_wagon,1,1),(trp_wagon_rider,2,4),]),
  ("single_horse_wagon",		"Single Horse Wagon",		icon_mule,			0,fac_commoners,courage_15|aggressiveness_0,[(trp_1_horse_wagon,1,1),(trp_wagon_rider,1,2),]),
  ("double_horse_wagon",		"Double Horse Wagon",		icon_mule,			0,fac_commoners,courage_15|aggressiveness_0,[(trp_2_horse_wagon,1,1),(trp_wagon_rider,1,3),]),
  ("four_horse_wagon",			"Four Horse Wagon",			icon_mule,			0,fac_commoners,courage_15|aggressiveness_0,[(trp_4_horse_wagon,1,1),(trp_wagon_rider,2,4),]),
  ("double_wheled_cart",		"Double Wheled Cart",		icon_mule,			0,fac_commoners,courage_15|aggressiveness_0,[(trp_2_wheled_cart,1,1),(trp_wagon_rider,1,2),]),
  ("wagon_system_end","End",0,0,0,0,[]),
Code:
slot_party_inventory_troop = 1
slot_inventory_used = 1
no                             = 0
yes                            = 1
from module_troops import *
num_troops = len(troops)
Code:
  (0,  [(ge, "$visit_after_rest", 1),
		(try_begin),
			(neg|map_free), #jump to menu after rest
			(assign, reg1, "$rest_time"),
			(assign, reg2, "$atackable"),
			(store_current_hours, ":hours"),
			(try_begin),
				(eq, "$rest_time", ":hours"),
				(assign, ":menu", "$visit_after_rest"),
				(assign, "$visit_after_rest", 0),
				(jump_to_menu, ":menu"),
			(else_try),
				(rest_for_hours, reg1, 5, reg2),
			(try_end),
		(else_try),
			(assign, ":menu", "$visit_after_rest"),
			(assign, "$visit_after_rest", 0),
			(jump_to_menu, ":menu"),
		(try_end),
		]),
Code:
  ["wagon_rider",						"Wagon Rider",						"Wagon Riders",						tf_guarantee_all_wo_ranged|tf_mounted,0,0,fac_commoners,[itm_sword_medieval_c,itm_fur_coat,itm_hide_boots,itm_leather_jacket, itm_leather_cap],def_attrib|level(9),wp(100),knows_common|knows_riding_4|knows_ironflesh_3,man_face_young_3, man_face_old_4],
  ["dual_ox_wagon",						"Dual Oxen Wagon",					"Dual Oxen Wagon",					tf_hero|tf_inactive, 0,reserved,  fac_commoners,[],def_attrib|level(18),wp(60),knows_inventory_management_10, 0],
  ["1_horse_wagon",						"One Horse Wagon",					"Dual Horse Wagon",					tf_hero|tf_inactive, 0,reserved,  fac_commoners,[],def_attrib|level(18),wp(60),knows_inventory_management_5, 0],
  ["2_horse_wagon",						"Two Horses Wagon",					"Two Horses Wagon",					tf_hero|tf_inactive, 0,reserved,  fac_commoners,[],def_attrib|level(18),wp(60),knows_inventory_management_6, 0],
  ["4_horse_wagon",						"Four Horses Wagon",				"Four Horses Wagon",				tf_hero|tf_inactive, 0,reserved,  fac_commoners,[],def_attrib|level(18),wp(60),knows_inventory_management_8, 0],
  ["2_wheled_cart",						"Two Wheled Cart",					"Two Wheled Cart",					tf_hero|tf_inactive, 0,reserved,  fac_commoners,[],def_attrib|level(18),wp(60),knows_inventory_management_2, 0],
Code:
#Wagon party
  [party_tpl|pt_dual_ox_wagon,"start", [], "Good day to you {sir/my lady}, what are your orders?.", "wagon_orders",[(store_encountered_party,reg0)]],
  [party_tpl|pt_single_horse_wagon,"start", [], "Good day to you {sir/my lady}, what are your orders?.", "wagon_orders",[(store_encountered_party,reg0)]],
  [party_tpl|pt_double_horse_wagon,"start", [], "Good day to you {sir/my lady}, what are your orders?.", "wagon_orders",[(store_encountered_party,reg0)]],
  [party_tpl|pt_four_horse_wagon,"start", [], "Good day to you {sir/my lady}, what are your orders?.", "wagon_orders",[(store_encountered_party,reg0)]],
  [party_tpl|pt_double_wheled_cart,"start", [], "Good day to you {sir/my lady}, what are your orders?.", "wagon_orders",[(store_encountered_party,reg0)]],
  [anyone,"wagon_preorders", [], "Anything else?", "wagon_orders",[]],
  [anyone|plyr,"wagon_orders", [], "I want you to follow me.", "wagon_orders_follow",[]],
  [anyone|plyr,"wagon_orders_follow", [], "Alright, we'll be right after you {sir/my lady}.", "wagon_preorders",[(party_set_ai_patrol_radius,reg0,1),(party_set_ai_behavior,reg0,ai_bhvr_escort_party),(party_set_ai_object,reg0,"p_main_party"),]],
  [anyone|plyr,"wagon_orders", [], "I want you to stay here.", "wagon_orders_stay",[]],
  [anyone|plyr,"wagon_orders_stay", [], "Alright, we'll wait for you right here {sir/my lady}.", "wagon_preorders",[(party_set_ai_behavior,reg0,ai_bhvr_hold),]],
  [anyone|plyr,"wagon_orders", [], "I want to acess the Inventory.", "wagon_inventory",[]],
  [anyone|plyr,"wagon_inventory", [], "Alright, it's all there {sir/my lady}.", "wagon_preorders",[(party_get_slot, reg4, reg0, slot_party_inventory_troop),(change_screen_loot, reg4)]],
  [anyone|plyr,"wagon_orders", [], "I want to exchange members.", "wagon_members",[]],
  [anyone|plyr,"wagon_members", [], "Alright {sir/my lady}.", "wagon_preorders",[(change_screen_exchange_members, 1, reg0),]],
  [anyone|plyr,"wagon_orders", [], "Farewell.", "close_window",[(assign, "$g_leave_encounter",1),(leave_encounter),]],
Code:
#this is not my code, it is from Floris Mod Pack
                        ("copy_inventory",
                          [
                            (store_script_param_1, ":source"),
                            (store_script_param_2, ":target"),
                            
                            (troop_clear_inventory, ":target"),
                            (troop_get_inventory_capacity, ":inv_cap", ":source"),
                            (try_for_range, ":i_slot", 0, ":inv_cap"),
                              (troop_get_inventory_slot, ":item", ":source", ":i_slot"),
                              (troop_set_inventory_slot, ":target", ":i_slot", ":item"),
                              (troop_get_inventory_slot_modifier, ":imod", ":source", ":i_slot"),
                              (troop_set_inventory_slot_modifier, ":target", ":i_slot", ":imod"),
                              (troop_inventory_slot_get_item_amount, ":amount", ":source", ":i_slot"),
                              (gt, ":amount", 0),
                              (troop_inventory_slot_set_item_amount, ":target", ":i_slot", ":amount"),
                            (try_end),
                        ]),

If I forgot any part, please, report it and I'll add it ASAP.
You can use it wherever you want, just give me credits(and tell me, I'm curious).

Edit: 07/08 Added the troops I forgot
Edit: 10/08 Added more things I forgot...
Edit: 11/08 Added yet more things I forgot...
UPDATED 06/08/2011
 

Idibil

Grandmaster Knight
module_party_templates:
Código: [Seleccionar]

## BRC v2.0
  ("double_wheled_cart","Double Wheled Cart", icon_vaegir_knight,0,fac_commoners,courage_15|aggressiveness_0,[]),
  ("single_horse_wagon","Single Horse Wagon", icon_vaegir_knight,0,fac_commoners,courage_15|aggressiveness_0,[]),
  ("double_horse_wagon","Double Horse Wagon", icon_vaegir_knight,0,fac_commoners,courage_15|aggressiveness_0,[]),
  ("four_horse_wagon","four Horse Wagon", icon_vaegir_knight,0,fac_commoners,courage_15|aggressiveness_0,[]),
  ("dual_bull_wagon", "Dual Bull Wagon", icon_vaegir_knight,0,fac_commoners,courage_15|aggressiveness_0,[]),
## BRC v2.0


It would be best caravan icon?  :mrgreen:

Nice work.
 

Ikaguia

Grandmaster Knight
WBWF&SNW
Idibil said:
module_party_templates:
Código: [Seleccionar]

## BRC v2.0
  ("double_wheled_cart","Double Wheled Cart", icon_vaegir_knight,0,fac_commoners,courage_15|aggressiveness_0,[]),
  ("single_horse_wagon","Single Horse Wagon", icon_vaegir_knight,0,fac_commoners,courage_15|aggressiveness_0,[]),
  ("double_horse_wagon","Double Horse Wagon", icon_vaegir_knight,0,fac_commoners,courage_15|aggressiveness_0,[]),
  ("four_horse_wagon","four Horse Wagon", icon_vaegir_knight,0,fac_commoners,courage_15|aggressiveness_0,[]),
  ("dual_bull_wagon", "Dual Bull Wagon", icon_vaegir_knight,0,fac_commoners,courage_15|aggressiveness_0,[]),
## BRC v2.0


It would be best caravan icon?  :mrgreen:

Nice work.

actually, it would be better custom-made icons but, i don't have them, so, good idea.
FrisianDude said:
Sounds cool! A minor suggestion however; replace "bulls" with "oxen."  Oxen are more often used in history as pulling animals because they are calmer. :grin:

Also; link related.
thanks, I didnt knew about that because I'm brazilian and I think Oxen and Bull means the same think here xD
oxen means oxen, bull means both oxen and bull(in brazilian portuguese)

edit:

just change the bull item to

  ["ox", "Ox(wrong model yet)", [("sumpter_horse",0)], itp_merchandise|itp_type_horse, 0, 414, abundance(50)|hit_points(450)|body_armor(14)|difficulty(1)|horse_speed(23)|horse_maneuver(17)|horse_charge(21)|horse_scale(120),0],
  ["bull", "Bull(wrong model yet)", [("sumpter_horse",0)], itp_merchandise|itp_type_horse, 0, 434, abundance(45)|hit_points(500)|body_armor(14)|difficulty(3)|horse_speed(27)|horse_maneuver(13)|horse_charge(29)|horse_scale(120),0],

and change some things in module_game_menus from
eq itm_bull
to
this_or_next|eq itm_bull
eq itm_ox

edit²:
first post updated
 

Caba`drin

Count
M&BWBWF&SNWVC
Just checking on this, the OP says "yes it is unfinished"...is it finished yet? Bug tested?
If yes, then it is ready to move to the resources/scripts section, if not it can develop here a bit more first...just doing more housekeeping.
 

Ikaguia

Grandmaster Knight
WBWF&SNW
well, this version doesn't work, you can't give the items.
the working version is in my crashed computer, once I fix it I'll fix this.
 

Ikaguia

Grandmaster Knight
WBWF&SNW
no it isn't, I'm still trying to fix a major bug, so... I'll update this soon, because I have already fixed 90% of the bugs I think.
 

Ikaguia

Grandmaster Knight
WBWF&SNW
Updated it, fixed that major bug... you can move it back Caba xD
edit: caba, there is no need for the (OSP) in the end because this it the "OSP Resources and Scripts" subboard
 

Caba`drin

Count
M&BWBWF&SNWVC
Ikaguia said:
Updated it, fixed that major bug... you can move it back Caba xD
edit: caba, there is no need for the (OSP) in the end because this it the "OSP Resources and Scripts" subboard
You're probably right...I leave them at the back for two reasons:
1) Most folks have it in the subject already, so I just re-arrange things rather than change what they have put in their own thread title.
2) I figure it might help if folks are using the search tool rather than looking where they should be looking.

Oh, and congrats on the bug-squashing.
 

Lav

Sergeant Knight at Arms
M&BWB
I'd suggest to change Bull and Oxen item type to itp_type_animal, so player can't ride them to battle.

As an extra bonus - you don't need a real model in this case, a plain square mesh with an alpha-transparent photo of a bull will suffice for trade and inventory screens. :smile:

Also, you can change "ale_barrel" mesh to "cart_b", it doesn't look exactly right but it looks much more like a real cart. :smile:
 

Ikaguia

Grandmaster Knight
WBWF&SNW
why not? I think that a bull could do quite some charge damage  :razz:

yeah, your second argument is much better :razz:
 

Lav

Sergeant Knight at Arms
M&BWB
This thread has given me some ideas. Ikaguia, do you mind if I tweak your code a bit?
 

ThaneWulfgharn

Master Knight
Got this problem:
Traceback (most recent call last):
  File "process_init.py", line 2, in <module>
    from process_operations import *
  File "C:\Program Files\Mount&Blade Warband\Modules\A Time for Wolves module sy
stem\process_operations.py", line 17, in <module>
    from module_party_templates import *
  File "C:\Program Files\Mount&Blade Warband\Modules\A Time for Wolves module sy
stem\module_party_templates.py", line 157, in <module>
    ("dual_ox_wagon",                          "Dual Ox Wagon",
        icon_mule,                      0,fac_commoners,courage_15|aggressivenes
s_0,[(trp_dual_ox_wagon,1,1),(trp_wagon_rider,2,4),]),
NameError: name 'trp_dual_ox_wagon' is not defined
Traceback (most recent call last):
  File "process_global_variables.py", line 6, in <module>
    from module_dialogs import *
  File "C:\Program Files\Mount&Blade Warband\Modules\A Time for Wolves module sy
stem\module_dialogs.py", line 12669, in <module>
    [party_tpl|pt_dual_ox_wagon,"start", [], "Good day to you {sir/my lady}, wha
t are your orders?.", "wagon_orders",[(store_encountered_party,reg0)]],
NameError: name 'pt_dual_ox_wagon' is not defined
Exporting strings...
Exporting skills...
Exporting tracks...
Exporting animations...
Exporting meshes...
Exporting sounds...
Exporting skins...
Traceback (most recent call last):
  File "process_map_icons.py", line 6, in <module>
    from process_operations import *
  File "C:\Program Files\Mount&Blade Warband\Modules\A Time for Wolves module sy
stem\process_operations.py", line 17, in <module>
    from module_party_templates import *
  File "C:\Program Files\Mount&Blade Warband\Modules\A Time for Wolves module sy
stem\module_party_templates.py", line 157, in <module>
    ("dual_ox_wagon",                          "Dual Ox Wagon",
        icon_mule,                      0,fac_commoners,courage_15|aggressivenes
s_0,[(trp_dual_ox_wagon,1,1),(trp_wagon_rider,2,4),]),
NameError: name 'trp_dual_ox_wagon' is not defined
Exporting faction data...
Exporting item data...
Traceback (most recent call last):
  File "process_items.py", line 66, in <module>
    from process_operations import *
  File "C:\Program Files\Mount&Blade Warband\Modules\A Time for Wolves module sy
stem\process_operations.py", line 17, in <module>
    from module_party_templates import *
  File "C:\Program Files\Mount&Blade Warband\Modules\A Time for Wolves module sy
stem\module_party_templates.py", line 157, in <module>
    ("dual_ox_wagon",                          "Dual Ox Wagon",
        icon_mule,                      0,fac_commoners,courage_15|aggressivenes
s_0,[(trp_dual_ox_wagon,1,1),(trp_wagon_rider,2,4),]),
NameError: name 'trp_dual_ox_wagon' is not defined
Exporting scene data...
Traceback (most recent call last):
  File "process_scenes.py", line 15, in <module>
    from process_operations import *
  File "C:\Program Files\Mount&Blade Warband\Modules\A Time for Wolves module sy
stem\process_operations.py", line 17, in <module>
    from module_party_templates import *
  File "C:\Program Files\Mount&Blade Warband\Modules\A Time for Wolves module sy
stem\module_party_templates.py", line 157, in <module>
    ("dual_ox_wagon",                          "Dual Ox Wagon",
        icon_mule,                      0,fac_commoners,courage_15|aggressivenes
s_0,[(trp_dual_ox_wagon,1,1),(trp_wagon_rider,2,4),]),
NameError: name 'trp_dual_ox_wagon' is not defined
Exporting troops data
Exporting particle data...
Traceback (most recent call last):
  File "process_scene_props.py", line 7, in <module>
    from process_operations import *
  File "C:\Program Files\Mount&Blade Warband\Modules\A Time for Wolves module sy
stem\process_operations.py", line 17, in <module>
    from module_party_templates import *
  File "C:\Program Files\Mount&Blade Warband\Modules\A Time for Wolves module sy
stem\module_party_templates.py", line 157, in <module>
    ("dual_ox_wagon",                          "Dual Ox Wagon",
        icon_mule,                      0,fac_commoners,courage_15|aggressivenes
s_0,[(trp_dual_ox_wagon,1,1),(trp_wagon_rider,2,4),]),
NameError: name 'trp_dual_ox_wagon' is not defined
Traceback (most recent call last):
  File "process_tableau_materials.py", line 8, in <module>
    from process_operations import *
  File "C:\Program Files\Mount&Blade Warband\Modules\A Time for Wolves module sy
stem\process_operations.py", line 17, in <module>
    from module_party_templates import *
  File "C:\Program Files\Mount&Blade Warband\Modules\A Time for Wolves module sy
stem\module_party_templates.py", line 157, in <module>
    ("dual_ox_wagon",                          "Dual Ox Wagon",
        icon_mule,                      0,fac_commoners,courage_15|aggressivenes
s_0,[(trp_dual_ox_wagon,1,1),(trp_wagon_rider,2,4),]),
NameError: name 'trp_dual_ox_wagon' is not defined
Traceback (most recent call last):
  File "process_presentations.py", line 8, in <module>
    from process_operations import *
  File "C:\Program Files\Mount&Blade Warband\Modules\A Time for Wolves module sy
stem\process_operations.py", line 17, in <module>
    from module_party_templates import *
  File "C:\Program Files\Mount&Blade Warband\Modules\A Time for Wolves module sy
stem\module_party_templates.py", line 157, in <module>
    ("dual_ox_wagon",                          "Dual Ox Wagon",
        icon_mule,                      0,fac_commoners,courage_15|aggressivenes
s_0,[(trp_dual_ox_wagon,1,1),(trp_wagon_rider,2,4),]),
NameError: name 'trp_dual_ox_wagon' is not defined
Traceback (most recent call last):
  File "process_party_tmps.py", line 2, in <module>
    from module_party_templates import *
  File "C:\Program Files\Mount&Blade Warband\Modules\A Time for Wolves module sy
stem\module_party_templates.py", line 157, in <module>
    ("dual_ox_wagon",                          "Dual Ox Wagon",
        icon_mule,                      0,fac_commoners,courage_15|aggressivenes
s_0,[(trp_dual_ox_wagon,1,1),(trp_wagon_rider,2,4),]),
NameError: name 'trp_dual_ox_wagon' is not defined
Traceback (most recent call last):
  File "process_parties.py", line 4, in <module>
    from module_game_menus import *
  File "C:\Program Files\Mount&Blade Warband\Modules\A Time for Wolves module sy
stem\module_game_menus.py", line 14778, in <module>
    (troop_set_slot, fimp_variable, variable_currently_building, reg0),
NameError: name 'fimp_variable' is not defined
Exporting quest data...
Exporting info_page data...
Traceback (most recent call last):
  File "process_scripts.py", line 7, in <module>
    from process_operations import *
  File "C:\Program Files\Mount&Blade Warband\Modules\A Time for Wolves module sy
stem\process_operations.py", line 17, in <module>
    from module_party_templates import *
  File "C:\Program Files\Mount&Blade Warband\Modules\A Time for Wolves module sy
stem\module_party_templates.py", line 157, in <module>
    ("dual_ox_wagon",                          "Dual Ox Wagon",
        icon_mule,                      0,fac_commoners,courage_15|aggressivenes
s_0,[(trp_dual_ox_wagon,1,1),(trp_wagon_rider,2,4),]),
NameError: name 'trp_dual_ox_wagon' is not defined
Traceback (most recent call last):
  File "process_mission_tmps.py", line 8, in <module>
    from process_operations import *
  File "C:\Program Files\Mount&Blade Warband\Modules\A Time for Wolves module sy
stem\process_operations.py", line 17, in <module>
    from module_party_templates import *
  File "C:\Program Files\Mount&Blade Warband\Modules\A Time for Wolves module sy
stem\module_party_templates.py", line 157, in <module>
    ("dual_ox_wagon",                          "Dual Ox Wagon",
        icon_mule,                      0,fac_commoners,courage_15|aggressivenes
s_0,[(trp_dual_ox_wagon,1,1),(trp_wagon_rider,2,4),]),
NameError: name 'trp_dual_ox_wagon' is not defined
Traceback (most recent call last):
  File "process_game_menus.py", line 5, in <module>
    from module_game_menus import *
  File "C:\Program Files\Mount&Blade Warband\Modules\A Time for Wolves module sy
stem\module_game_menus.py", line 14778, in <module>
    (troop_set_slot, fimp_variable, variable_currently_building, reg0),
NameError: name 'fimp_variable' is not defined
Traceback (most recent call last):
  File "process_simple_triggers.py", line 2, in <module>
    from module_simple_triggers import *
  File "C:\Program Files\Mount&Blade Warband\Modules\A Time for Wolves module sy
stem\module_simple_triggers.py", line 4009, in <module>
    (troop_set_slot, fimp_variable, variable_entertainement_on, 0),
NameError: name 'fimp_variable' is not defined
Traceback (most recent call last):
  File "process_dialogs.py", line 6, in <module>
    from module_dialogs import *
  File "C:\Program Files\Mount&Blade Warband\Modules\A Time for Wolves module sy
stem\module_dialogs.py", line 12669, in <module>
    [party_tpl|pt_dual_ox_wagon,"start", [], "Good day to you {sir/my lady}, wha
t are your orders?.", "wagon_orders",[(store_encountered_party,reg0)]],
NameError: name 'pt_dual_ox_wagon' is not defined
Traceback (most recent call last):
  File "process_global_variables_unused.py", line 3, in <module>
    from process_operations import *
  File "C:\Program Files\Mount&Blade Warband\Modules\A Time for Wolves module sy
stem\process_operations.py", line 17, in <module>
    from module_party_templates import *
  File "C:\Program Files\Mount&Blade Warband\Modules\A Time for Wolves module sy
stem\module_party_templates.py", line 157, in <module>
    ("dual_ox_wagon",                          "Dual Ox Wagon",
        icon_mule,                      0,fac_commoners,courage_15|aggressivenes
s_0,[(trp_dual_ox_wagon,1,1),(trp_wagon_rider,2,4),]),
NameError: name 'trp_dual_ox_wagon' is not defined
Exporting postfx_params...

______________________________

Script processing has ended.
Press any key to exit. . .
Terminate batch job (Y/N)?
With trp_dual_ox_wagon and that fimp thingie...
 

Lav

Sergeant Knight at Arms
M&BWB
Sometimes the compile needs to be run twice, the first run will throw tons of errors but will compile the lists of object ID's so the second compile runs smoothly. This, or some references should have been quoted.
 
Top Bottom