Jump to content

[Ayuda] Currently spectating


Bc#

Recommended Posts

Posted

Nesesito hacer que lo de esta imagen se vea en color y con otra fuente.

currentlyspectating.png

Intente con la funcion

dxDrawColorText 

Pero no me funcionó.

Creo no estoy seguro que se edita en el race_client especificamente dentro de esta funcion:

function Spectate.setTarget( player ) 
    if Spectate.hasDroppedCamera() then 
        return 
    end 
  
    Spectate.active = true 
    Spectate.target = player 
    if Spectate.target then 
        if Spectate.getCameraTargetPlayer() ~= Spectate.target then 
            setCameraTarget(Spectate.target) 
        end 
        guiSetText(g_GUI.speclabel, 'Currently spectating:\n' .. getPlayerName(Spectate.target)) 
    else 
        local x,y,z = getElementPosition(g_Me) 
        x = x - ( x % 32 ) 
        y = y - ( y % 32 ) 
        z = getGroundPosition ( x, y, 5000 ) or 40 
        setCameraTarget( g_Me ) 
        setCameraMatrix( x,y,z+10,x,y+50,z+60) 
        guiSetText(g_GUI.speclabel, 'Currently spectating:\n No one to spectate') 
    end 
    if Spectate.active and Spectate.savePos then 
        guiSetText(g_GUI.speclabel, guiGetText(g_GUI.speclabel) .. "\n\nPress 'B' to join") 
    end 
end 

¿Alguna ayuda o idea de como hacerlo?

:?::?::?::?::?::?::?::?::?::?::?:

Posted
si es alli puedes usar un
getPlayerNametagColor 

y despues

guiLabelSetColor 

me parece que era asi

Tu dices, ¿hacer esto?

        guiLabelSetColor(g_GUI.speclabel, 'Currently spectating:\n' .. getPlayerNametagColor(Spectate.target)) 

Posted
        local myLabel = guiSetText(g_GUI.speclabel, 'Currently spectating:\n' .. getPlayerNametagColor(Spectate.target, theplayer) 
        guiLabelSetColor ( myLabel, 255, 255, 255 ) 

Creo que seria haci.

Si no lo es me podrías dar un ejemplo por que cada ves que pruebo esto se me bugea.

Posted (edited)

prueba asi aver

       local myLabel = guiSetText(g_GUI.speclabel, 'Currently spectating:\n' .. getPlayerName(Spectate.target, theplayer) 
       local r,g,b = getPlayerNametagColor ( Spectate.target, theplayer ) 
       guiLabelSetColor ( myLabel, r,g,b ) 

Edited by Guest
Posted
prueba asi aver
       local myLabel = guiSetText(g_GUI.speclabel, 'Currently spectating:\n' .. getPlayerName(Spectate.target, theplayer) 
       local Color = getPlayerNameTagColor ( Spectate.target, theplayer ) 
       guiLabelSetColor ( myLabel, Color ) 

No soy experto en esto pero creo que ahí no se especifica color ni en RGB ni en hexagesimal.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...