Author Topic: [RELEASE] COLLECTION OF WARBAND SCRIPTS // MODDING  (Read 3691 times)

0 Members and 1 Guest are viewing this topic.

FriendsKnow

  • Guest
[RELEASE] COLLECTION OF WARBAND SCRIPTS // MODDING
« on: March 17, 2015, 05:38:41 pm »
stick the thread please/

#Auto Chambering bots  [SERVER-SIDE] (needs a bit more work to make it lethal)

Code: [Select]
(0.0, 0, 0, [],
       [
      (set_fixed_point_multiplier,1000),
   (get_max_players, ":maxp"),
      (try_for_range, ":ip", 1, ":maxp"),
   (player_is_active, ":ip"),
         (player_get_agent_id,":aid",":ip") ,
         (agent_is_active,":aid"),  
   (agent_get_attack_action,":att_dir",":aid"),    
   (eq,":att_dir",2),  
   (agent_get_position,pos10,":aid"),  
      (try_begin),
      (try_for_agents, ":agents"),
   (agent_is_non_player,":agents"),
      (agent_is_alive,":agents"),
   (agent_is_human,":agents"),  
   (agent_get_position,pos20,":agents"),    
         (get_distance_between_positions,":distance",pos10,pos20),
         (is_between,":distance",1,320),
         (agent_get_action_dir,":att_dir1",":aid"),
 (agent_set_damage_modifier,":agents",1000),
   (try_begin),
   (eq,":att_dir1",0),
   (agent_set_attack_action ,":agents",0,0),
   (else_try),
    (eq,":att_dir1",1),
   (agent_set_attack_action ,":agents",2,0),
   (else_try),
    (eq,":att_dir1",2),
   (agent_set_attack_action ,":agents",1,0),
   (else_try),
    (eq,":att_dir1",3),
   (agent_set_attack_action ,":agents",3,0),
   (eq,":att_dir1",-1),
   (agent_set_attack_action ,":agents",-2,0),
    (try_end),
     (try_end),
       (try_end),
    (try_end),

  ]),



#Ping kicker [SERVER-SIDE]

Code: [Select]

  (0.5, 0, 0, [],
[
    (multiplayer_is_server),

(get_max_players, ":max"),
(try_for_range, ":i", 0, ":max"),
   (player_is_active, ":i"),
(player_get_ping, ":ping", ":i"),
(gt, ":ping", 300),
(str_store_player_username, s3, ":i"),
(str_store_string, s4, "@[Server] {s3} kicked for high ping"),
(multiplayer_send_string_to_player, ":i", 111, s4),
(kick_player,":i"),
(server_add_message_to_log, s4),
(try_end),
]),
  



#Welcome Message [SERVER-SIDE]


Code: [Select]

    (ti_server_player_joined, 0, 0,
    [],
    [
       (try_begin),

        (store_trigger_param_1, ":var2"),
        (player_get_unique_id, ":var3", ":var2"),
        (assign, reg0, ":var3"),
        (str_store_player_username, s6, ":var2"),
        (str_store_string, s7, "@{s6} joined with ID: {reg0}"),
        (get_max_players, ":var4"),
        (try_for_range, ":var5", 0, ":var4"),
          (player_is_active, ":var5"),
          (multiplayer_send_string_to_player, ":var5", 111, s7),
        (try_end),
    ]),

#Custom message on keypress [CLIENT-SIDE]

Mission templates,strings neeeds to be copied as well.


Code: [Select]

(0, 0, 0,
    [
      (key_clicked, key_m),
    ],
    [
      (display_message, "@You pressed M", 4294945535),
    ]),


Admins by ID [MISSION TEMP - SERVER SIDE || SCRIPTS - CLIENT SIDE]


Code: [Select]

#Scripts.txt ,client events

 (else_try),
        (eq, ":var1", 120),
        (store_script_param, ":var60", 3),
        (multiplayer_get_my_player, ":var61"),
        (player_set_is_admin, ":var61", ":var60"),



Mission templates

Code: [Select]
(ti_server_player_joined, 0, 0,
    [],
    [
      (store_trigger_param_1, ":var0"),
      (player_is_active, ":var0"),
      (player_get_unique_id, ":var1", ":var0"),
      (try_begin),
        (this_or_next|eq, ":var1", your id),
        (this_or_next|eq, ":var1", nextguysid),
        (eq, ":var1",nextguysid),
        (multiplayer_send_int_to_player, ":var0", 120, 1),
        (player_set_is_admin, ":var0", 1),
      (try_end),
    ]),




#Module version checker (IDs in header common &  module constants should be changed)



Header common

Code: [Select]
player_update = 123
player_update1 = 124

Module constants

Code: [Select]
slot_player_has_has_this_module                        = 320
scripts

Code: [Select]
#validation
(eq, ":event_type",124),
(player_set_slot,":player_no",slot_player_has_has_this_module     ,1),
 (else_try),
        ###############
        #CLIENT EVENTS#
        ###############


  (eq, ":event_type",123),
 (multiplayer_send_message_to_server, 124),
        # MM
        (else_try),

#mission temp

Code: [Select]


(ti_server_player_joined, 0, 0, [],
       [
         (store_trigger_param_1, ":player_no"),
(player_is_active, ":player_no"),
 (str_store_string, s1, "@[Server] Welcome to blablabla"),
 (player_set_slot, ":player_no",slot_player_has_has_this_module ,0),
 (multiplayer_send_int_to_player ,":player_no",player_update,1),
  (multiplayer_send_string_to_player, ":player_no", 95, s1),
(str_store_string, s2, "@[Server] Checking if module is genuine"),
          (multiplayer_send_string_to_player, ":player_no", 95, s2),
         ]),


(3, 0, 0, [],
       [
       (multiplayer_is_server),
  (store_mission_timer_a, ":time"),
       (get_max_players, ":max_players"),
  (try_for_range, ":player_id", 1, ":max_players"),
       (player_is_active, ":player_id"),
       (player_slot_eq, ":player_id", slot_player_has_launcher,0),
       (player_get_slot, ":join_time", ":player_id", slot_player_join_time),
       (store_sub, ":time_since_join", ":time", ":join_time"),
 (gt, ":time_since_join", 4),
  (str_store_string, s2, "@[Server]Your module is out-of-date "),
     (multiplayer_send_string_to_player, ":player_id", 95, s2),
(gt, ":time_since_join", 12),
     (kick_player, ":player_id"),
 (str_store_string, s3, "@[Server] Game disconnected: you were kicked by the Server. Stated reason: Outdated module"),
     (multiplayer_send_string_to_player, ":player_id", 95, s3),
  (try_end),
         ]),
      

#healing weapon

mission temp.

Code: [Select]
(ti_on_agent_hit, 0, 0,
    [],
    [
      (store_trigger_param_1, ":var0"),
      (store_trigger_param_2, ":var1"),
      (agent_get_player_id, ":var2", ":var0"),
      (player_is_active, ":var2"),
      (agent_get_wielded_item, ":var3", ":var1"),
      (try_begin),
        (eq, ":var3", "itm_scalpel"),
        (store_agent_hit_points, ":var4", ":var0", 1),
        (val_add, ":var4", 10),
        (agent_set_hit_points, ":var0", ":var4", 1),
      (try_end),
    ]),

ENJOY
« Last Edit: May 06, 2015, 01:11:49 pm by FriendsKnow »

MrMedic

  • MasstKer
  • ********
  • Posts: 8900
  • programmer/dev/software engineer
    • View Profile
Re: Warband ultimate set of warband scripts
« Reply #1 on: March 17, 2015, 07:53:17 pm »
your really hung up on that auto chamber , you really still haven't sussed it out ?

do you want me to help you with it?
EnCoded Message: i3iy9yl8kr2xf3g2Txs3pr6ye3ya7jg5ty2z

https://www.youtube.com/watch?v=62_7-AYfdkQ
you need a paypal account for the private versions.

Website:
http://bit.ly/medic101

Teamspeak 3: 85.236.101.5:10157

SCARYSUICIDE

  • Cheater Apprentice
  • *
  • Posts: 12
    • View Profile
Re: [SOURCE] ultimate set of warband scripts
« Reply #2 on: March 24, 2015, 04:08:51 pm »
WHat is string: "(0.0, 0, 0, [],"?  I get this error:

Can you solve this?
« Last Edit: March 24, 2015, 04:15:33 pm by SCARYSUICIDE »

FriendsKnow

  • Guest
Re: [SOURCE] ultimate set of warband scripts
« Reply #3 on: March 24, 2015, 08:42:30 pm »
WHat is string: "(0.0, 0, 0, [],"?  I get this error:

Can you solve this?

thats almost copy paste bud .. you need a minimal cleverness to get it it work.

ask anybody who has fundamental knowledge on modding.

spoon feeding does no make any good :smile

possibly .. some scripts might generate error messages during compilation.. especially on the new module system (if newer than 1.158).
« Last Edit: March 25, 2015, 01:30:15 am by FriendsKnow »

SCARYSUICIDE

  • Cheater Apprentice
  • *
  • Posts: 12
    • View Profile
Re: [SOURCE] ultimate set of warband scripts
« Reply #4 on: March 25, 2015, 12:10:19 am »
but please take my curiosity . What kind of language is this ? So I can understand if I'm doing it all wrong completely .

FriendsKnow

  • Guest
Re: [SOURCE] ultimate set of warband scripts
« Reply #5 on: March 25, 2015, 12:47:08 am »
but please take my curiosity . What kind of language is this ? So I can understand if I'm doing it all wrong completely .

https://www.youtube.com/watch?v=FhRGrbpy6mo

SCARYSUICIDE

  • Cheater Apprentice
  • *
  • Posts: 12
    • View Profile
Re: [SOURCE] ultimate set of warband scripts
« Reply #6 on: March 25, 2015, 02:17:29 am »
please can you ask me such a good tutorial to use and insert this code good for pleasure or if you do not want to help at least someone who knows how to do and who is willing to do it if you do not want to do it . Please I want to understand how to use this code .

MrMedic

  • MasstKer
  • ********
  • Posts: 8900
  • programmer/dev/software engineer
    • View Profile
Re: [SOURCE] ultimate set of warband scripts
« Reply #7 on: March 25, 2015, 03:51:08 am »
please can you ask me such a good tutorial to use and insert this code good for pleasure or if you do not want to help at least someone who knows how to do and who is willing to do it if you do not want to do it . Please I want to understand how to use this code .

the answer is in the post below.


but please take my curiosity . What kind of language is this ? So I can understand if I'm doing it all wrong completely .

https://www.youtube.com/watch?v=FhRGrbpy6mo

EnCoded Message: i3iy9yl8kr2xf3g2Txs3pr6ye3ya7jg5ty2z

https://www.youtube.com/watch?v=62_7-AYfdkQ
you need a paypal account for the private versions.

Website:
http://bit.ly/medic101

Teamspeak 3: 85.236.101.5:10157

SCARYSUICIDE

  • Cheater Apprentice
  • *
  • Posts: 12
    • View Profile
Re: [SOURCE] ultimate set of warband scripts
« Reply #8 on: March 25, 2015, 07:29:45 pm »
Medic can i try your "super mega hack"?

MrMedic

  • MasstKer
  • ********
  • Posts: 8900
  • programmer/dev/software engineer
    • View Profile
Re: [SOURCE] ultimate set of warband scripts
« Reply #9 on: March 25, 2015, 08:19:47 pm »
Medic can i try your "super mega hack"?

sure the link is in my sig.
EnCoded Message: i3iy9yl8kr2xf3g2Txs3pr6ye3ya7jg5ty2z

https://www.youtube.com/watch?v=62_7-AYfdkQ
you need a paypal account for the private versions.

Website:
http://bit.ly/medic101

Teamspeak 3: 85.236.101.5:10157

SCARYSUICIDE

  • Cheater Apprentice
  • *
  • Posts: 12
    • View Profile
Re: [SOURCE] ultimate set of warband scripts
« Reply #10 on: March 25, 2015, 11:20:08 pm »
30 Euros......Wow cheapest xD