login

Show Posts

You can view here all posts made by this member. Note that you can only see posts made in areas to which you currently have access.


Messages - KON_Air

Pages: [1] 2 3 ... 6
1
Discussion / Re: Has anyone experimented with a "blood loss" damage model?
« on: November 19, 2008, 08:04:28 PM »
Quote
If it's a fixed linear thing like 1pt of weapon damage = 1/3 point of bleed per second, then no checks need to take place at all. You just need to keep track of how much bleed damage you applied to the victim and deduct that from the current lack of health to get weapon-inflicted damage.

well,

every step/interval
-get agent current health
-get agent max health
--if wounded
-get max - current health
-div result to 3
-apply damage

vs

every step (doesn't even have to be every step, can match interval)
-get agent health
-get agnet max health
--if wounded (lt, agent health, max health)
--get damage from an index according to agent health
-mark agent with wound severity

regular interval
-get agent wound severity
-apply damage

2
Modding Knowledge Base / Re: Random Notes
« on: November 17, 2008, 05:46:00 PM »
Don't teach monkeys how to play poker and then cheat while gambling with them.

3
Discussion / Re: Any Work?
« on: November 17, 2008, 02:37:00 PM »
One metarial max per tent, they can share materials.

http://rapidshare.com/files/164765240/tents.wings

4
Discussion / Re: Has anyone experimented with a "blood loss" damage model?
« on: November 16, 2008, 09:53:47 AM »
Why don't you just do us a favour, learn python and just stop bothering us with impossible requests?

5
Discussion / Re: Has anyone experimented with a "blood loss" damage model?
« on: November 16, 2008, 08:07:19 AM »
Because it is a "game" not a simulation of "Ron Losey's bizzare world in which you can die due to blood loss by cutting your finger".

6
Discussion / Re: Has anyone experimented with a "blood loss" damage model?
« on: November 16, 2008, 07:12:51 AM »
Some times I wonder why do I even bother...

7
Discussion / Re: Has anyone experimented with a "blood loss" damage model?
« on: November 16, 2008, 05:10:16 AM »
It really doesn't need experimenting just tweaking, the sole problem is detecting "a critical hit" that would cause that serious bleeding to worth bleeding in gameplay mechanics,

work flow is like that;

hit detection: trickiest part as players may get themselves into positions that they can take damage in every step (ie. frame, milisecond). And there is no possibilty of detecting what kind of damage they are taking. The only way to do it, is to contiuniously compare their health to their health in previous check and store how much damage they took in between.What can be done as far as I know is making bleeding as a result of a "critical hit" and decide what to do according to the severity of the hit.

execution: if bleeding deliver blunt damage, if battle goes on longer then survival time limit kill that agent.

Or at least that's what I'm going to do Modplosion, only for player and won't kill anyone (that is expect player :P).

8
Modding Knowledge Base / Re: Random Notes
« on: November 04, 2008, 03:07:18 PM »
Town Cultures are just slot values incase you didn't notice :P Just look for the script that changes its faction and add it there.

9
in menu recruit_volunteers,

this will give the preset,
(party_get_slot, ":volunteer_troop", "$current_town", slot_center_volunteer_troop_type),

replace that line with this;
(store_faction_of_party, ":cur_faction", "$current_town"),
(faction_get_slot, ":volunteer_troop", ":cur_faction", slot_faction_tier_1_troop),

10
Modding Knowledge Base / Stationary Horses
« on: October 12, 2008, 11:35:01 PM »
Stationary Horses Without Riders In Battlefield

Mission Template
     (0.1, 0, 0,
      [
(try_for_agents, ":cur_agent"),
  (agent_is_alive, ":cur_agent"), #so we don't try dead agents
    (neg|agent_is_human,":cur_agent"), #agent is a horse
      (agent_get_rider,":cur_rider", ":cur_agent"),
        (lt, ":cur_rider", 0), #horse does not have a rider
  (agent_set_animation, ":cur_agent", "anim_unused_horse_anim_1"), #so the horse doesn't move, must include module_animations at the top
(try_end),
      ], []),


Animations
 ["unused_horse_anim_1", 0, [1.0, "anim_horse", 0, 1, 0]],

Kon_Air & HokieBT For Speeder Bikes in M&B Starwars Mod

11
Discussion / Re: Complicating Economy
« on: September 05, 2008, 08:13:21 AM »
AAAAAAAAAAAAAAAAAAAAAaaaaaaaaaaaa............... ALL CARAVANS GO TO THE SAME CITY...

The native script responsible
Code: [Select]
  #Troop AI: Merchants thinking
  (8,
   [
       (try_for_parties, ":party_no"),
         (party_slot_eq, ":party_no", slot_party_type, spt_kingdom_caravan),
         (party_is_in_any_town, ":party_no"),

         (store_faction_of_party, ":merchant_faction", ":party_no"),
         (faction_get_slot, ":num_towns", ":merchant_faction", slot_faction_num_towns),
         (try_begin),
           (le, ":num_towns", 0),
           (remove_party, ":party_no"),
         (else_try),
           (store_random_in_range, ":random_no", 0, 100),
           (lt, ":random_no", 35),
       
           (party_get_cur_town, ":cur_center", ":party_no"),

           (assign, ":can_leave", 1),
           (try_begin),
             (is_between, ":cur_center", walled_centers_begin, walled_centers_end),
             (neg|party_slot_eq, ":cur_center", slot_center_is_besieged_by, -1),
             (assign, ":can_leave", 0),
           (try_end),
           (eq, ":can_leave", 1),

           (assign, ":do_trade", 0),
           (try_begin),
             (party_get_slot, ":cur_ai_state", ":party_no", slot_party_ai_state),
             (eq, ":cur_ai_state", spai_trading_with_town),
             (party_get_slot, ":cur_ai_object", ":party_no", slot_party_ai_object),
             (eq, ":cur_center", ":cur_ai_object"),
             (assign, ":do_trade", 1),
           (try_end),

           (assign, ":target_center", -1),
           
           (try_begin), #Make sure escorted caravan continues to its original destination.
             (eq, "$caravan_escort_party_id", ":party_no"),
             (neg|party_is_in_town, ":party_no", "$caravan_escort_destination_town"),
             (assign, ":target_center", "$caravan_escort_destination_town"),
           (else_try),
             (call_script, "script_cf_select_random_town_at_peace_with_faction_in_trade_route", ":cur_center", ":merchant_faction"),
             (assign, ":target_center", reg0),
           (try_end),
           (is_between, ":target_center", towns_begin, towns_end),
           (neg|party_is_in_town, ":party_no", ":target_center"),
       
           (try_begin),
             (eq, ":do_trade", 1),
             (call_script, "script_do_merchant_town_trade", ":party_no", ":cur_center"),
           (try_end),
           (party_set_ai_behavior, ":party_no", ai_bhvr_travel_to_party),
           (party_set_ai_object, ":party_no", ":target_center"),
           (party_set_flags, ":party_no", pf_default_behavior, 0),
           (party_set_slot, ":party_no", slot_party_ai_state, spai_trading_with_town),
           (party_set_slot, ":party_no", slot_party_ai_object, ":target_center"),
         (try_end),
       (try_end),
    ]),


And that's all I had to do to make it work, it took about a day to figure out...
...
             (call_script, "script_cf_select_random_town_at_peace_with_faction_in_trade _route", ":cur_center", ":merchant_faction"),
         
           (neq, "$last_merc_target_center", ":target_center"),
              (assign, ":target_center", reg0),
...

      (assign, "$last_merc_target_center", ":target_center"),

That's it... f....k...

12
Discussion / Re: Complicating Economy
« on: September 04, 2008, 01:06:49 PM »
Done;

-Production Rate/Prosperity chaning events.
#Negative 1 Lord Captured, 2 Besieged, 3 A Village Is Infested/Looted, 4 No Caravans
#Positive Boosts after Negative ends  5 Lord Freed, 6 Siege End, 7 Village Freed, 8 Caravan Arrival
#No Switch, just happens 9 No Villager Trade, 10 Recovery, 11 Monthly Recovery 12 Collapse (30 Days without a caravan)

So depriving a town from its caravans will drive up the prices and reduces its prosperity periodically. Collapse doesn't cause a rebellion, I don't have the nerves to do that right now but it gives a nice -300 production rate -100 prosperity, good luck with recovering from that...

-Revamped Lord Wage system
Taxing system;
      #Get Prosperity, Divide it with contrubition rate ACCORDING TO THE FACTION and get total_prosperity
      #Average Numbers City 5 Castle 8 Village 18 Totals should be ~1500
      # Swadians City %125, Castle %50, Village %25 ---Trade Faction
      # Total 625 400 450 = 1475
      # Vaegirs City %75, Castle %25, Village %50 ---Balanced Faction
      # Total 375 200 900 = 1475
      # Khergit City %50 Castle %40 Village %50 ---Semi Nomadic Faction
      #Total 250 320 900 = 1470
      # Nord City %40 Castle %100 Village %25 ---Warrior Faction
      # Total 200 800 450 = 1450
      # Rhodok City %25 Castle %35 Village %75 ---Villager Faction
      # Total 125  280 1080 = 1485

Then does something... and adds it to wage as help from kingdom treasury... Afaik max is 830 for 100 total_prosperity and 320 for 50 total_prosperity, replaces the wage boost from troop level. Faction Leaders get this boost twice.

-War Time effects, the number of factions in war effects the party sizes and the amount of tariffs from caravans

TO DO;
-Add "A Caravan Last Visited x Days Ago" and "This town is the Prime Importer of X and Prime exporter of Y" stuff to info's_ and gossips.

-Player led/sent caravans, I guess this will be a dialouge option with merchants...


anything else?

13
Discussion / Re: Complicating Economy
« on: September 03, 2008, 12:35:29 PM »
Hmm, my system is far less complicated then, it simply works in "events" which alter production rate of items (I guess you can make use of that script) in towns. Which directly effects the inventory and prices of town merchant and prosperity of towns. Also each town has a "trade character" which changes the effects for specific events.

In next step the prosperity of town defines the reinforcements and party size of Lord Parties.

The basic idea is ways to weaken enemy towns (more can be added easily);
"Lack Of Caravans Arriving a Town"
"Bandit Infested/Raided/Deserted Villages"
"Captured Lord"
"Sieges"

It seems you have already covered everything and more since I have no intention of including town population, facilities and tracking the trade goods themselves.
Though, I'll add player led caravans and production boosting upgrades to towns.

I think you might find that useful, it simply assigns the probability of item depending on the production rate.

Code: [Select]
# Refresh Merchants
  (0.0, 0, 24.0, [], [
                      (reset_item_probabilities,100),
                      (set_merchandise_modifier_quality,150),


                      (reset_item_probabilities,100),(set_item_probability_in_merchandise,"itm_salt",700),
                      (troop_add_merchandise,"trp_salt_mine_merchant",itp_type_goods,num_merchandise_goods),

                      # Add trade goods to merchant inventories
#                      (store_sub, ":item_to_production_slot", slot_town_trade_good_productions_begin, trade_goods_begin),

                      (try_for_range,":cur_center",towns_begin,towns_end),
                        (party_get_slot,":cur_merchant",":cur_center",slot_town_merchant),
                        (reset_item_probabilities,100),
     (try_for_range, ":cur_goods", trade_goods_begin, trade_goods_end),
       (store_sub, ":cur_good_slot", ":cur_goods", trade_goods_begin),
       (val_add, ":cur_good_slot", slot_town_trade_good_productions_begin),
       (party_get_slot, ":production", ":cur_center", ":cur_good_slot"),
   (party_get_slot, ":is_export_item", ":cur_center", slot_center_primary_export),
   (try_begin),
   (eq, ":cur_goods", ":is_export_item"),
   (val_mul, ":production", 10),
   (else_try),
   (val_mul, ":production", 5),
   (try_end),
   (set_item_probability_in_merchandise,":cur_goods",":production"),
     (try_end),
 

                        (troop_add_merchandise,":cur_merchant",itp_type_goods,num_merchandise_goods),

                        (troop_ensure_inventory_space,":cur_merchant",merchant_inventory_space),
                        (store_troop_gold, ":cur_gold",":cur_merchant"),
                        (lt,":cur_gold",1500),
                        (store_random_in_range,":new_gold",500,1000),
                        (call_script, "script_troop_add_gold",":cur_merchant",":new_gold"),
                     (try_end),
                     ]),

14
Discussion / Re: Complicating Economy
« on: September 03, 2008, 05:50:31 AM »
Actually the economics part of the script is finalized, final implementations are simple get slot, do consequence... copy/paste job in other words.

Prosperity effects are also just modifying a script.

So it will be available soon and Fujiwara can do whatever he wants with it.

God I love being in depression, 8 hours straight coding spree with fine cuban cigar and coffe, I should get depressed more often. UTCS in a session, and this whole trade stuff in two...

15
Discussion / Re: Complicating Economy
« on: September 03, 2008, 05:09:36 AM »
Wow, you guys are really talkative nowadays.

Meanwhile I got myself a nice little system (besides UTCS),

#script_production_event_rate_change
#input: arg1, party_id arg2, event type
#output: none
#changes production rates every 48 hours. Positives called whenever the event happens, also twin script causes prosperity changes.
#Negative 1 Lord Captured, 2 Besieged, 3 A Village Is Infested/Looted, 4 No Caravans
#Positive Boosts after Negative ends  5 Lord Freed, 6 Siege End, 7 Village Freed, 8 Caravan Arrival
#No Switch, just happens 9 No Villager Trade, 10 Recovery, 11 Monthly Recovery 12 Collapse (30 Days without a caravan)

That system still needs implementing special rules for each city, stats of its Lord (trade, leadership, etc.), state of economy and a couple of events (harvest, festivities... etc). And maybe relating production to spawning caravans... but it may get the game into a deadlock, so I guess I'll be fine with assuming the center can always produce enough to create a caravan.

Already hacked merchant refresh trigger to stock items related to their production rate in town.

Last is the effects of prosperity to Lords...

Pages: [1] 2 3 ... 6