Author Topic: Quick Outfit  (Read 866 times)

Hey, is there possible to make a Quick Outfit change like when you press Key 1;   you get that specific Outfit and when you press 2 you get another one?

Please tell me if there is an possible way to do this.     (Client-Sided)

There is a way.

Not quite sure what the way is, but I don't think it's all that hard.

There is a way.

Not quite sure what the way is, but I don't think it's all that hard.

Good, :D

You need to find the function for the Player Avatar Quick change, make it into a script, rebind some stuff then you'll be along on your way.

You need to find the function for the Player Avatar Quick change, make it into a script, rebind some stuff then you'll be along on your way.
hmm I wonder if you spam them if the server has rainbow player kick on if it boots you :D

hmm I wonder if you spam them if the server has rainbow player kick on if it boots you :D

of course

Code: [Select]
function av_fav1() {
    AvatarGui::clickFav(AvatarGui, 1);
    clientCmdUpdatePrefs();
}

if(!$avatarfavbinds) {
    $remapDivision[$remapCount] = "Avatar Favorites";
    $remapName[$remapCount] = "Favorite 1";
    $remapCmd[$remapCount] = "av_fav1";
    $remapCount++;
    $avatarfavbinds = "1";
}

copy and paste the first part and the part with all the $remap__ things, replace 1 with 2, 3, 4, 5, 6, 7, 8, 9, 0

i know there's almost definitely a way to do this more efficiently but i don't know how, it's the first thing that came to mind.

Code: [Select]
function av_fav1() {
    AvatarGui::clickFav(AvatarGui, 1);
    clientCmdUpdatePrefs();
}

if(!$avatarfavbinds) {
    $remapDivision[$remapCount] = "Avatar Favorites";
    $remapName[$remapCount] = "Favorite 1";
    $remapCmd[$remapCount] = "av_fav1";
    $remapCount++;
    $avatarfavbinds = "1";
}

copy and paste the first part and the part with all the $remap__ things, replace 1 with 2, 3, 4, 5, 6, 7, 8, 9, 0

i know there's almost definitely a way to do this more efficiently but i don't know how, it's the first thing that came to mind.

Nice.

Code: [Select]
$AC::S::P = -1;
$AC::S::N = -1;
function logAvatarSaves() {
deleteVariables("$AC::S::*");
$AC::S::N = -1;
for(%i = -1; %i <= 9; %i++)
if(isFile("config/client/AvatarFavorites/" @ %i @ ".cs"))
$AC::S::L[$AC::S::N++] = %i;
}
logAvatarSaves();

function cycleAvatars(%val) {
if(%val && !$AC::S::LC) {
exec("config/client/AvatarFavorites/" @ $AC::S::L[$AC::S::P++] @ ".cs");
if($AC::S::P >= $AC::S::N) $AC::S::P = 0;
//transferOldAvatarPrefs();
clientCmdUpdatePrefs();
$AC::S::LC = schedule(1150 + ServerConnection.getPing(), 0, eval, "$AC::S::LC = 0;");
}
}

if(!$AC::Bind) {
if(isFunction(AddBind))
AddBind("Action", "Cycle Avatars", "cycleAvatars");
else {
$remapDivision[$remapCount] = "Avatar Cycler";
$remapName[$remapCount] = "Cycle Avatars";
$remapCmd[$remapCount] = "cycleAvatars";
$remapCount++;
}
$AC::Bind = true;
}

My most current version of Avatar Cycler. Now to watch as people criticize and improve upon it.
« Last Edit: August 11, 2011, 07:55:50 PM by MegaScientifical »

aaaaaaaaaa placid

That will cause the user to be banned

You forgot the argument in the keybinded function again.

We don't want it to run again when released.

My script has a delay of 1150 milliseconds plus the ping, which should always keep you from changing too fast and activating that ban script.

aaaaaaaaaa placid

That will cause the user to be banned

You forgot the argument in the keybinded function again.

We don't want it to run again when released.
ah yeah man.. i always forget to add that. come to think of it, i can't even remember what it is.. :/

My script has a delay of 1150 milliseconds plus the ping, which should always keep you from changing too fast and activating that ban script.
You'd still get kicked if you have DrenDran's mod.

You'd still get kicked if you have DrenDran's mod.

He told me he wouldn't with such a delay.