AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   Semiclip (There is no name) (https://forums.alliedmods.net/showthread.php?t=308331)

PurposeLessx 06-16-2018 18:54

Semiclip (There is no name)
 
I have a semiclip plugin. And while it is on, I cannot see the names of my teammates. Cannot see name, health or anything of them.

Spoiler

maqi 06-16-2018 19:52

Re: Semiclip (There is no name)
 
That is because they are not visible to you :D

PurposeLessx 06-17-2018 03:59

Re: Semiclip (There is no name)
 
How can I show names? It may be hudmessage.

maqi 06-17-2018 11:22

Re: Semiclip (There is no name)
 
try get_user_aiming()

raizo11 06-17-2018 12:38

Re: Semiclip (There is no name)
 
Code:

#include <amxmodx>
#include <cstrike>

new cvar_teaminfo

public plugin_init()
{
    cvar_teaminfo  = register_cvar("amxx_teaminfo","1")

    register_event("StatusValue","status","be","1=2","2!0");
    //register_forward(FM_PlayerPreThink, "status", 0)
}

public status(id)
{
            new name[32],pid = read_data(2)
            get_user_name(pid,name,31)
        new idAiming, iBodyPart
        get_user_aiming(id, idAiming, iBodyPart)
       
        if(is_user_alive(idAiming) && is_user_alive(id) ,get_pcvar_num(cvar_teaminfo))
        {
                if(cs_get_user_team(id) == CS_TEAM_CT && cs_get_user_team(idAiming) == CS_TEAM_CT)
                {
                        set_hudmessage(238,201,0,-1.0,0.70,1, 0.01, 3.0, 0.01, 0.01, -1)
                        show_hudmessage(id, "%s", name)
                }
                else
                if(cs_get_user_team(id) == CS_TEAM_T && cs_get_user_team(idAiming) == CS_TEAM_T)
                {
                        set_hudmessage(238,201,0,-1.0,0.70,1, 0.01, 3.0, 0.01, 0.01, -1)
                        show_hudmessage(id, "%s", name)
                }
        }
}


maqi 06-17-2018 12:41

Re: Semiclip (There is no name)
 
if a StatusValue event doesn't get called ( like it doesn't in his case, if i understood it well ). Then this wouldn't work.

PurposeLessx 06-17-2018 12:56

Re: Semiclip (There is no name)
 
The plugin which raizo11 posted, does work or doesn't work?

raizo11 06-17-2018 13:15

Re: Semiclip (There is no name)
 
idk test him

PurposeLessx 06-17-2018 13:20

Re: Semiclip (There is no name)
 
Now, i don't have anywhere I can test

PurposeLessx 06-17-2018 17:55

Re: Semiclip (There is no name)
 
Does not work. :( Same. There is no name of teammate


All times are GMT -4. The time now is 04:38.

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