What about simply not kicking those players? I'm sure you can do that yourself and save some time to the scripters...
Scripts
|
23 Nov 11, 12:23AM
Take the challenge, script it yourself.
here's some tips: 1- Make a list of names. [cubescript]alias dont_kick_list [unarmed armed unarmored unskilled xxXXXXXX_I_SNIPE_U_DEAD_XXXXXxx][/cubescript] 2- You need something to check your kick (it isn't possible through /kick), like /ckick (bind it to a key if you like: /saycommand "ckick ", or simply make a menu) [cubescript]alias ckick [...][/cubescript] 3- you will need a loop to match and check if your argument with the names on the list. [cubescript]alias ckick [ loop i (listlen $dont_kick_list) [if (strcmp (findpl $arg1) (at $dont_kick_list $i)) [] []] ][/cubescript]"loop" restarts to check the "body", adding +1 to "i" (starts on 0) in every loop until "i" = the number of names "listlen" counts the number of names on your list "findpl" returns the name of the client number "strcmp" matches the exact name from the client number with one name from the list "at" returns the name in the "i" position "if" executes the first order if the names match, if not execute the second "arg1" is the first argument given 4- now you need a way to know if the name you are trying to kick was found on the list after the loops. (created "dont_kick") [cubescript]alias ckick [ dont_kick = 0; loop i (listlen $dont_kick_list) [if (strcmp $arg1 (at $dont_kick_list $i)) [dont_kick = 1] [ if (= $dont_kick 1) [echo "Cannot kick, name on the dont_kick_list!"] [kick $arg1] ][/cubescript]"dont_kick" is checked on every loop, if the result is 0 we are free to kick. 5- I always rename and save $arg1 in this situations because it might change when you execute another command giving another argument (renamed it "someone"). [cubescript]alias ckick [ someone = $arg1; dont_kick = 0; loop i (listlen $dont_kick_list) [if (strcmp $someone (at $dont_kick_list $i)) [dont_kick = 1] []]; if (= $dont_kick 1) [echo "Cannot kick, name on the dont_kick_list!"] [kick $someone] ][/cubescript] I did not test it, i'm not sure if it'll work. Test it youself, fix it if necessary. :D
23 Nov 11, 07:09AM
Ok ty;)
23 Nov 11, 03:08PM
|BC|Wolf, its becuz i play gema's and i have autogemakick
24 Nov 11, 08:13PM
Hey guys,
i'm trying to make a list with friends and if you click on the name you search on that name, but it doesn't work and i don't know exactly how to make. please help me.
Yai!
* Orynge loves menus. The command to search is "searchnickname". To make a menu, take a look at this one, for example. It's part of a clan roster I'm scripting for my clan (B}) in my spare time. [SELECT ALL] Code: newmenu "cr-Orynge" Remember that menus don't automatically make a new line if that line is too big. Also, that "-1" means no command, and if it wasn't there and you clicked on that line, the menu would close. * Orynge still has to find "menuitemslider" in the docs.
25 Nov 11, 02:50AM
Yeh, I noticed that, so I made some. Feel free to copy this into your docs.cfg file. :D
[code=CubeScript] docsection [Menus] docident [menuitemcheckbox] [Creates a menu checkbox.]; docargument [N] [Menu item name] []; docargument [D] [Display checked or not] [1 or 0 (checked or unchecked)]; docargument [A] [Action when selected] []; docremark [Usually the value of a binary alias is used for the second argument.]; docident [menuitemimage] [Creates a menu item with an accompanying image.]; docargument [P] [Path and filename of image to be used] []; docargument [D] [Description] []; docargument [A] [Action when selected] []; docargument [H] [Hover action] []; docremark [Displays a tiny (text-line-sized) square image, P, along with normal menu item behavior.]; docident [menuitemkeyinput] [Creates a menu item which will bind a key to a command or alias.]; docargument [D] [The description of the command to be bound]; docargument [A] [The command or alias to be bound to the user-input key]; docident [menuitemslider] [Creates a menu item which utilizes a slider to output values.]; docargument [D] [Description]; docargument [Min] [Minimum value]; docargument [Max] [Maximum value]; docargument [C] [Current display value]; docargument [S] [Step value]; docargument [V] [Values to display when adjusting]; docargument [A] [Action to take on change]; docremark [The step value determines how big each step in the slider is.]; docident [menuitemtextinput] [Creates a text box for user string input.]; docargument [D] [Description]; docargument [V] [Value displayed]; docargument [A] [Action to perform when used]; docargument [H] [Action to perform when hovered over]; docargument [M] [Max characters allowed as input]; docexample [menuitemtextinput "Store commands in a test alias: " $testalias "alias testalias $arg1" "echo This will store a test alias." 16]; [/code]
25 Nov 11, 04:47PM
thanks orynge and v-man i look at that scripts and make my own :D
i type in menus.cfg menuitem Friends [showmenu friends] and then newmenu friends menuitem *K!D* [searchnickname *K!D*] because *K!D* is my brother ^^ thanks
25 Nov 11, 08:54PM
26 Nov 11, 01:48AM
(This post was last modified: 26 Nov 11, 05:16AM by paulmuaddibKA.)
(26 Jan 11, 11:46AM)MykeGregory Wrote:LOL THIS IS AWESOME, ups, caps lock... XD(22 Jan 11, 04:18PM)DES|V-Man Wrote: Edit: After going through 10 pages of the scripts thread I havent been able to find the one I was looking for :(, so... Could someone please tell me the script with the connects to the Match servers as Mewtwo and such (but maybe a revised version of the one that I had ???). Thanks in advance.
26 Nov 11, 06:29AM
26 Nov 11, 09:30AM
V-Man i saw nice
10 Dec 11, 09:32AM
What're the default definitions for delta_game_0 and delta_game_1? I accidentally ran an old script of mine that modified those and don't really remember CubeScript much.
I looked in defaults.cfg, and it had this: [SELECT ALL] Code: alias delta_game_0 [ if (= $arg1 1) [ primary ] [ secondary ] ] But it will obviously only switch between primary and secondary.
10 Dec 11, 09:37AM
[SELECT ALL] Code: $ grep -R "delta_game" * This tells me that it is in defaults.cfg and scripts.cfg. Go with scripts.cfg, it has all the deltas in it.
10 Dec 11, 09:40AM
Thanks. I believe "shiftweapon" is what I needed.
10 Dec 11, 10:25AM
Switch for cubescript:
[cubescript]// switch - Takes an integer argument to determine which block of code to execute. // NOTE: This command can only handle up to 23 "cases" (24 arguments). // SVN version only below // switch = [ // if (&& (<= $numargs 24) (checkrange $arg1 0 22)) [ // execute (getalias (format arg%1 (+ $arg1 2))) // ] // ] // AC 1104 and lower version switch = [ if (&& (<= $numargs 24) (&& (>= $arg1 0) (<= $arg1 22))) [ tmp = (getalias (format arg%1 (+ $arg1 2))) tmp ] ][/cubescript] Examples: [cubescript]i = 22 switch $i [ echo test 1 // case 0 ] [ echo test 2 // case 1 ] [ echo test 3 // case 2 ] [ echo test 4 // case 3 ] [ echo test 5 // and so on.. ] [ echo test 6 ] [ echo test 7 ] [ echo test 8 ] [ echo test 9 ] [ echo test 10 ] [ echo test 11 ] [ echo test 12 ] [ echo test 13 ] [ echo test 14 ] [ echo test 15 ] [ echo test 16 ] [ echo test 17 ] [ echo test 18 ] [ echo test 19 ] [ echo test 20 ] [ echo test 21 ] [ echo test 22 ] [ echo test 23 ] // Output: test 23[/cubescript] [cubescript]bind KEY [ // Use if statements to set an integer value for switch to inspect. // // If editing, execute case 0 (aka switch's arg2) // | if connected to a server, execute case 1 (aka switch's arg3) // | | if playing bots, execute case 2 (aka switch's arg4) // | | | else execute case 3 (aka switch's arg5) // | | | | if (|| $editing (= $gamemode 1)) [ i = 0 ] [ if $connected [ i = 1 ] [ if (curmodeattr bot) [ i = 2 ] [ i = 3 ] ] ] switch $i [ echo You're editing. // case 0 code block ] [ echo You're in multiplayer. // case 1 code block ] [ echo You're in singleplayer. // case 2 code block ] [ echo You're not playing. // case 3 code block ] ] // In SVN/future versions of AC, the above code for the keybind is a bad example. Use megabind instead.[/cubescript]
12 Dec 11, 07:06PM
could some1 write a script that would upon writting like
chagne 0 3 5 6 7 make forceteam to CN 0,3,5,6 and 7? PS numbers are just an example ty :)
12 Dec 11, 09:40PM
I haven't attempted such a thing in 1.1, but in 1.0 I couldn't find a way to get the client to perform repeated admin functions in one script. I'm not sure why that is, but I could take a look at 1.1 to see if the problem is still there.
You'll have to add a sleep obviously, because it's a vote even if it ends again immediately. Other than that, I can't see why it wouldn't work.
One day I will or someone will need to make and index of all these scripts lol.
Before I post my scripts I would like to remind you that I don't know a whole lot of cubescript and got help with these after my attempts didn't work but they are both my own ideas from reading through all the .cfgs 1. Favourite Maps Thanks V-Man! It adds a favourite maps to the maps menu so when selecting a map you need just open favourites and select rather than browse through your huge cache of maps. Also there's none that say "Untitled by Unknown" [cubescript] //Favourite Maps By D1551D3N7 newmenu "favourite_maps" menuitem "Team Deathmatch" "mode 0; showmenu favmaps" menuitem "Deathmatch" "mode 2; showmenu favmaps" menuitem "Team Survivor" "mode 4; showmenu favmaps" menuitem "Survivor" "mode 3; showmenu favmaps" menuitem "Capture the Flag" "mode 5; showmenu favmaps" menuitem "Hunt the Flag" "mode 13; showmenu favmaps" menuitem "Keep the Flag" "mode 15; showmenu favmaps" menuitem "Team Keep the Flag" "mode 14; showmenu favmaps" menuitem "Pistol Frenzy" "mode 6; showmenu favmaps" menuitem "Last Swiss Standing" "mode 9; showmenu favmaps" menuitem "One Shot, One Kill" "mode 10; showmenu favmaps" menuitem "Team One Shot, One Kill" "mode 11; showmenu favmaps" newmenu "favmaps" //Change the map names to the ones you like but they MUST be the //same name as the ones in your maps folder (without .cgz) alias favmaps "dreamland ac_douze krull_bunker mini_douze" "cgz" "map $arg1" genmapitems $favmaps [/cubescript] Then go to menus_multiplayer.cfg and add [cubescript] menuitem "Change To Favourite Map" "showmenu favourite_maps" [/cubescript] Beneath [cubescript] menuitem "Set mode/map..." "showmenu Gamemode" [/cubescript] ToDo: make savefav alias to save map to favourites. 2. Sendmap Menu Thanks Ronald_Reagan!!! [cubescript] newmenu Sendmap menudirlist "packages/maps" "cgz" "sendmap $arg1" [/cubescript] Now for some reason this dosen't work but I'm sure some one will be able to tweak it to work. Add it to menus_multiplayer.cfg below [cubescript] menuitem "Set mode/map..." "showmenu Gamemode" [/cubescript] or below favmaps if you have it :). Other Ideas: Ask Screenshot --- DONE SEE BELOW Instead of screenshotting after every single game it will pop up and ask you weather to take a screenshot or not. (I didnt get to finish this or manage it as couldnt figure out how to get function for the end of the game) Cool thing: Load a map of your choice on start http://forum.cubers.net/thread-1339.html This thread showed me this cool function. So right-click your assaultcube.bat file and click edit. Add --loadmap=maphere This was sitting in my drafts for a long time :) EDIT: Auto-screenshot Thanks Lantry!!!!! This needs V-mans tools.cfg to work. Might not work all the time [cubescript] alias scorescreenshot [ showscores 1; sleep 100 [ screenshot ] ] newmenu screenshot menuitem "Yes" [ sleep 30 [ scorescreenshot ] ] menuitem "no" addcheck_si [ showmenu screenshot ] [/cubescript]
13 Dec 11, 12:47AM
13 Dec 11, 01:27AM
(13 Dec 11, 12:39AM)D1551D3N7 Wrote: Ask Screenshot Well, it doesn't ask you each time, but I made a script which you might find useful. It automatically turns autoscreenshot on or off depending on the mastermode: here. As for the asking script, you can use the "start_intermission" alias, or if you have V-Man's CS tools, you should use the "addcheck_si" alias.
13 Dec 11, 01:33AM
I should probably make a whole autoexec.cfg file with all these in, and the necessary files. Ive obviously got some work to do!
Another idea :D
Auto GG This needs V-Mans tools.cfg [cubescript] addcheck_si [ say "GG Everyone :D" ] [/cubescript] added a "d" so that it'll work
13 Dec 11, 01:23PM
Well, Im a Script übbern00b, but I have some ideas... (dunno how difficult they might actually be).
One that pops up a menu to change the voicecoms. One that , after typing a connect, prompts you if you wanna save it and with which name. Thats all, for now...
Okay another idea :D If I bind my auto-screenshot and gg cause naturally you would have had a gg if you wanted screenshot
[cubescript] alias scorescreenshot [ showscores 1; sleep 100 [ screenshot ] ] newmenu screenshot menuitem "Yes" [ say "gg everyone :D"; scorescreenshot ] menuitem "no" addcheck_si [ showmenu screenshot ] [/cubescript] PaulmuaddibKA what do mean a menu to change voicecoms? I think it would be possible :D
13 Dec 11, 07:35PM
@D1551D3N7 An in-game menu which allows you to change the Voice-com Expression to the one you mostly prefer.
It could be arranged from this, which is my first try to get into scripting XD: [SELECT ALL] Code: // VoiceCom Menu An every category make a selectable item for each expression (Yes, All right sir, Affirmative...) where you could change it, instead of having to go to the .cfg file each time.
13 Dec 11, 09:19PM
[cubescript]
// forceteams -- force a variable number of client numbers to the opposite team -- by V-Man // requires tools.cfg alias forceteams [ forcelist = [] ft = 0; tmp1 = ft; tmp2 = $numargs; tmp3 = 100 loop sft $numargs [add2alias forcelist (getalias (concatword arg (+ $sft 1)))] tmp4 = [forceteam (at $forcelist $ft)] sloopme] [/cubescript] This works in SVN, haven't tested in 1.1.0.4. The sleeps are certainly the key to this, but in 1.0 you couldn't even sleep repeat admin commands (or perhaps I couldn't figure out how, but I do recall trying many different methods).
15 Jan 12, 11:21PM
This is a script to help you watch demos, it will change the crosshair and load the hitsound when a player hits another one. If you are folowing (ghost) cn 4, type /hit 4.
[SELECT ALL] Code: //change mycrosshair if you're not using star.png
17 Jan 12, 03:08PM
(This post was last modified: 17 Jan 12, 03:33PM by MykeGregory.)
A very basic melee knife script i made.
[SELECT ALL] Code: Bind F [weapon 0; attack; primary] Just type that and then spam F to use. Halo CE style. Just dont spam too quickly or it will just change back to your weapon without slashing. Please improve on this if you want cos it is gash, could be a handy script to have if its improved. |
« Next Oldest | Next Newest »
|