Blockland Forums > Modification Help

Guns Bind

Pages: (1/2) > >>

Arcturus:

Is there something wrong with this:
It seems that it doesnt work, can someone please fix this:

--- Code: ---if (!$addedToolKeys)
{
$remapDivision[$remapCount] = "Weapon Binds";
$remapName[$remapCount] = "Use Gun";
$remapCmd[$remapCount] = "useGun";
$remapCount++;
$remapName[$remapCount] = "Use Guns Akimbo";
$remapCmd[$remapCount] = "useAkimboGun";
$remapCount++;
        $addedToolKeys = true;
}

function useGun(%on)

{
if(!%on){return;}
  commandtoserver('gun');
}

function useGun(%on)

{
if(!%on){return;}
  commandtoserver('gun');
}

function useAkimboGun(%on)
{
if(!%on){return;}
commandtoserver('AkimboGun');
}

function useAkimboGun(%on)
{
if(!%on){return;}
commandtoserver('AkimboGun');
}
--- End code ---


Headcrab Zombie:

Why do you have the same function twice?
And do you even have a serverCmdGun and serverCmdAkimboGun?
Also the spaces between if and (, as well and the lines between function and { might be causing problems

SpreadsPlague:

so you're making a server-sided keybind to pull out a gun .. ?

not to mention you have two repeated (and useless) functions

does this not make sense to anybody else or is it just me?

Arcturus:

Well can you guys fix it and copy paste it here?


SpreadsPlague:


--- Quote from: Arcturus on November 06, 2010, 02:58:33 PM ---Well can you guys fix it and copy paste it here?


--- End quote ---

can you tell us what you're trying to do first?

it sounds like you're trying to make a keybind that pulls out a gun. this is for use on your own server, correct? (because if not I have some bad news for you AKA it won't work)

Pages: (1/2) > >>

Go to full version