AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting (https://forums.alliedmods.net/forumdisplay.php?f=107)
-   -   vgui_world_text_panel //SetDisplayText// (https://forums.alliedmods.net/showthread.php?t=331621)

Evai 03-29-2021 21:58

vgui_world_text_panel //SetDisplayText//
 
On the map they have vgui_world_text_panel and need change text with script, but how to do it idk

PHP Code:

void ChangeDisplayText()
{
    
char sBuffer[100];
    
int lastEdictInUse GetEntityCount();
    for (
int entity MaxClients+1entity <= lastEdictInUse; ++entity)
    {
        if ( !
IsValidEdict(entity) )
            continue;
        
        
GetEdictClassname(entitysBuffersizeof(sBuffer));    
        if (!
StrEqual(sBuffer"vgui_world_text_panel")) continue;

        
GetEntPropString(entityProp_Data"m_iName"sBuffersizeof(sBuffer)); 
        if (!
StrEqual(sBuffer"player")) continue;
        
        
SetEntPropString(entityProp_Data"here i got a brain daMage""Yep");
    }



stece 01-13-2022 12:12

Re: vgui_world_text_panel //SetDisplayText//
 
Did you ever find the correct property name? Looking for the same thing in reverse. Getting that property.

Bacardi 01-16-2022 13:21

Re: vgui_world_text_panel //SetDisplayText//
 
PHP Code:

...
    
int vgui_world_text_panel FindEntityByClassname(-1"vgui_world_text_panel");

    if(
vgui_world_text_panel == -1)
        return 
Plugin_Handled;


    
SetEntPropString(vgui_world_text_panelProp_Send"m_szDisplayText""Yes asdsadasdsa   asdasdasdasdsads");
... 



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

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