Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
On-The-Fly sensitivity script (V2 released)
#1
So, I wanted to make a script that utilized universaldelta (that thing where you can hold a key and use the scroll wheel and it does stuff), but I couldn't figure out how, so I just took the easy route and added on to the mouse binds :D

Code:
alias mouse_sens_inc [
    if $sens_active [
        sensitivity (+f $sensitivity 0.05)
        sensitivity
    ] []
]
alias mouse_sens_dec [
    if $sens_active [
        sensitivity (-f $sensitivity 0.05)
        sensitivity
    ] []
]


bind MOUSE4 [if $sens_active [mouse_sens_inc] [universaldelta 1]]
bind MOUSE5 [if $sens_active [mouse_sens_dec] [universaldelta -1]]
bind Q [ if $editing [ domodifier 1 ] [ alias sens_active 1 ; onrelease [ alias sens_active 0 ] ] ]

Note: I didn't think I needed to spell this out, but, I decided I will anyway, just in case. This script allows you to hold Q and scroll, and it will adjust your sensitivity in increments of 0.05 (in assaultcube of course, this is cubescript Tongue )

EDIT: This script is now obsolete, see below for v2
Reply
#2
this is amazing! How do i put it into the game so i can use it?
Reply
#3
Really? o.o
I didn't expect anyone to actually want to use this, lol..
I kindof made it and posted it just for the heck of it.

You could copy/paste it into your autoexec.cfg file, but it would be better to set up a scripts folder that auto-executes everything within it

How to do that (for windows, assuming you have write-access to your AC files)
  • Add this to your autoexec.cfg file:
    Code:
    execdir scripts\
  • Create scripts\ folder in your main AC directory (same folder as your bin_win32\, config\, assaultcube.bat, packages\, etc.)
  • Create new file, called whatever you want (such as mouse_settings.cfg), but it must have the .cfg file extension. Note: if your windows system hides file extensions, make sure you change the file extension, it is possible to change just the name to blablah.cfg, where with the extension shown, it would actually blahblah.cfg.txt
  • Copy/Paste the code into your mouse_settings.cfg file (or whatever filename you chose)
  • Make any tweaks to the code you desire (adjusting the increments, changing the keybind, etc.)
  • Save, close, Run AC, and enjoy Smile

This method will give you a folder that you can drop all your scripts in, each one a separate file, which is a lot easier to manage than one huge, bloated autoexec.cfg file (Trust me, I know this from experience >.> )




I suppose I could post some other little scripts I've made, just don't ask me for the mimicry script (if you even know what that is) Tongue
Reply
#4
Post them gogogogo :D
Reply
#5
Version 2:

Code:
alias delta_game_1 [
    sensitivity (+f $sensitivity (*f 0.05 $arg1))
    echo (concat "Sensitivity =" $sensitivity)
]
alias delta_spect_1 delta_game_1
bind Q [domodifier 1]

Explanation: I added onto the domodifier stuff, and utilized uinversaldelta like I wanted to in the first place :D
(I could provide an in-depth explanation if desired)

Thanks to HeWho for pointing me in the right direction on this Smile
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)