AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   set_user_frags without <fun>, add scoreboard info, shield remove (https://forums.alliedmods.net/showthread.php?t=84362)

sappounet 01-24-2009 20:20

set_user_frags without <fun>, add scoreboard info, shield remove
 
Hello,

I got some questions :

1)
i want to remove the +3 when you planted a bomb that has exploded or when you defused a bomb so i catched "triggered" with register_logevent and then i do that :

Code:

if(equal(arg2, "Defused_The_Bomb"))
    {
    new currentfrags = get_user_frags(id)
    new newfrags = currentfrags - 3
    set_user_frags(id, newfrags)
    }

This works well, but to use "set_user_frags" i have to include <fun> and i dont want to.

Is there any other solution to change players frags ?

2)
I would like to add informations on the score board (KIT for CTs wo got defusal kits, Money for each payer, etc)

Is it possible to do that without creating a new score board ?

If not, could you very quickly explain me how to create a new scoreboard (name of fonctions to use, etc) ?

3)
I would like to totally disabled Tactical Shield:

Code:

register_event("WeapPickup","task_weaponpick","b");
but the shield has no weapon id and does not use the WeapPickup event

I also tried

Code:

register_clcmd("shield", "task_blockshield")

public task_blockshield(playerid)
{
return PLUGIN_HANDLED
}

His works if you buy it using bind (bind "x" "shield") but this don't works if you use buymenu ( 'Buy' then 8 then 8 ).

How could I do ?

4)
Maybe you know this bug i want to fix :
When you duck a bit too fast under a ceiling or an object, you are slowed down and you have to duck during a longer time (2 seconds) to be able to move at normal speed.

How could i fix that ? i got no ideas :(


Thanks

Exolent[jNr] 01-24-2009 20:22

Re: set_user_frags without include <fun> ? add scoreboard info ?
 
1. Include fakemeta_util, and use fm_set_user_frags().

2. Impossible.

sappounet 01-24-2009 20:38

Re: set_user_frags without <fun>, add scoreboard info, shield remove
 
Thanks for your answer.

I really would like to have the best performance plugin so i try to use only the very needed includes.

What are the impact of include <fun> or include <fakemeta_util> ?

Thanks

Exolent[jNr] 01-24-2009 21:19

Re: set_user_frags without <fun>, add scoreboard info, shield remove
 
fakemeta_util is uses the fakemeta module.
fun is its own module.

Either way, you will need a module enabled to set a client's frags.

SnoW 01-25-2009 05:23

Re: set_user_frags without <fun>, add scoreboard info, shield remove
 
2. Kind of possible. Prethink + IN_SCORE + HUD. Though they would never go exactly to the right location, because the size of each player's slot in scoreboard will depend on how many other players are in the server. Ofc this isn't IN the scoreboard, but kind of.


All times are GMT -4. The time now is 01:43.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.