OSP Kit Combat Combat Abilities

Users who are viewing this thread

gpang788 said:
No I did not. Where can I find the xp penalty script?

It's posted on the OP (Opening Post)
Check it out if you need more info. Hope you succeed.

Code:
("rage_exp_penalty",
    [(store_character_level,":level","trp_player"),
     (val_mul,":level",-8),
     (add_xp_to_troop,":level","trp_player"),
     (assign,reg1,":level"),
       (display_message, "@You spent {reg1} experience points.",0x6495ed),     
     ]),

    ("sprint_exp_penalty",
    [(store_character_level,":level","trp_player"),
     (val_mul,":level",-6),
     (add_xp_to_troop,":level","trp_player"),
     (assign,reg1,":level"),
       (display_message, "@You spent {reg1} experience points.",0x6495ed),     
     ]),

    ("focus_exp_penalty",
    [(store_character_level,":level","trp_player"),
     (val_mul,":level",-10),
     (add_xp_to_troop,":level","trp_player"),
     (assign,reg1,":level"),
       (display_message, "@You spent {reg1} experience points.",0x6495ed),     
     ]),
 
Have implemented the above script. Things seem to have improved but am still getting some errors:

Initializing...
Compiling all global variables...
Exporting strings...
Exporting skills...
Exporting tracks...
Exporting animations...
Exporting meshes...
Exporting sounds...
Exporting skins...
Exporting map icons...
Creating new tag_uses.txt file...
Creating new quick_strings.txt file...
Exporting faction data...
Exporting item data...
Exporting scene data...
Exporting troops data
Exporting particle data...
Exporting scene props...
Exporting tableau materials data...
Exporting presentations...
Exporting party_template data...
Exporting parties
Exporting quest data...
Exporting scripts...
Exporting mission_template data...
WARNING: Local variable never used: player_agent
WARNING: Local variable never used: player_agent
WARNING: Local variable never used: player_agent
WARNING: Local variable never used: player_agent
WARNING: Local variable never used: player_agent
WARNING: Local variable never used: player_agent
WARNING: Local variable never used: player_agent
WARNING: Local variable never used: player_agent
Exporting game menus data...
exporting simple triggers...
exporting triggers...
exporting dialogs...
Checking global variable usages...

______________________________

Script processing has ended.
Press any key to exit. . .

What else do I need to add ?
 
those errors are harmless, they just mean that one of the variables is never actually used, I changed the code but did not delete the line that defines it. but that is fine.
Everything should work now!

P.S.

Also sometimes (I'm not sure when and why) the bonuses from rage/focus/sprint do not go away and become permanent.
Adding this to module_triggers.py should fix this problem in most cases:

Code:
     (1, 0, 1, [(eq,"$ability",2)], [

                 (val_sub,"$iron","$ironnew"),
                 (val_sub,"$strike","$strikenew"),
                 (val_sub,"$draw","$drawnew"),
                 (val_sub,"$throw","$thrownew"),             

                 (troop_raise_skill,"trp_player","skl_ironflesh","$iron"),
                 (troop_raise_skill,"trp_player","skl_power_strike","$strike"),
                 (troop_raise_skill,"trp_player","skl_power_draw","$draw"),
                 (troop_raise_skill,"trp_player","skl_power_throw","$throw"),

#                 (troop_raise_attribute,"trp_player",0,-20),
                 (troop_raise_attribute,"trp_player",1,-5),                    

                 (display_message,"@Your rage dies down...",0x6495ed),
                 (call_script, "script_rage_exp_penalty"),       

                 (assign, "$ability", 1),

         ]),
		
(1, 0, 1, [(eq,"$ability",3)], [

                 (val_sub,"$athletics","$athleticsnew"),

                 (troop_raise_skill,"trp_player","skl_athletics","$athletics"),

                 (troop_raise_attribute,"trp_player",1,-15),                    

                 (display_message,"@You are out of breath... ",0x6495ed),
                 (call_script, "script_sprint_exp_penalty"),       

                 (assign, "$ability", 1),
         ]),      

      (1, 0, 1, [(eq,"$ability",4)], [

                 (val_mul,"$bonus",-1),

                (troop_raise_proficiency_linear,"trp_player",0,"$bonus"),
                (troop_raise_proficiency_linear,"trp_player",1,"$bonus"),
                (troop_raise_proficiency_linear,"trp_player",2,"$bonus"),
                (troop_raise_proficiency_linear,"trp_player",3,"$bonus"),
                (troop_raise_proficiency_linear,"trp_player",4,"$bonus"),
                (troop_raise_proficiency_linear,"trp_player",5,"$bonus"),           

                 (troop_raise_attribute,"trp_player",1,-5),                    

                 (display_message,"@Your lose your focus... ",0x6495ed),
                 (call_script, "script_focus_exp_penalty"),       

                 (assign, "$ability", 1),
         ]),     
 
I have a lot of error in module script.py  :???:
fcqr5x.jpg
 
Hi there,
I have a quite general question concerning the xp-penalty-script:
Can anyone confirm or decline that it actually does something with the player's experience?

I tried to implement a similar script this weekend, but as it seems my character is only able to gain but never to lose experience. (Maybe there is a difference between M&B and Warband?)

Any help would be appreciated.

Greets
Inarion
 
Wish it was possible to do this to agents instead of troops, so it could be used in Warband MP. Dang.
 
Hi all,

I ported your combat abilities to my warband mod (see banner eventually).

Thank you so, chel,  much for these amazing wors of arts, warcry rocks, all your soldiers shout with you, this is amazing, I LOVE it ^^.

 
Wow Crom, you ported it? That's pretty cool actually. Mind you to share the code for noobs like me to use?

Regards.
 
Einskaldir said:
Wow Crom, you ported it? That's pretty cool actually. Mind you to share the code for noobs like me to use?

Regards.

This script works got shouting but the sprint does not, at least as far as I know.
 
Specialist said:
Any ideas how to make this MP? I love the kit, but I need sprinting specifically for MP. :razz:
Should be the same code, only a lot simpler. You can do away with all the attribute values, since in MP it will be consistent with everybody. Worst case scenario you'll have to plug it into server-side and client-side operations, but then again I don't know how the **** MP works and I basically made this whole last sentence up.
 
Specialist said:
Any ideas how to make this MP? I love the kit, but I need sprinting specifically for MP. :razz:
You'd need to find a different way to increase agent-speed for MP (which, so far as I know, there isn't a way) since the current sprint code works by changing troop attributes and in MP troop templates are shared among players (so 1 player sprinting would make all sprint if this were used as-is).

Adding very heavy versions items to non-sprinting agents and then removing them when sprinting would be a possibility, I suppose...
 
or making a troop for each player and copying the stats from  the troop the player chooses, then it would be possible to change stats... evn tought it would be kind of hard-work
 
Good point. Well, would it be just as possible to detect an agent and use the agent_set_position operation every 1-3 frames?
 
Back
Top Bottom