Jump to content

Need help with team script


HeArTBeaT

Recommended Posts

r, g, b is the color ( r = Red, g = Green, b = Blue )

+

createTeam dose not have a skin argument, But you can do it like :

Team = getPlayerTeam( player ) 
if Team and getTeamName(Team) == 'TeamName' then 
    setElementModel( player, skinID ) 
end 

Link to comment
r, g, b is the color ( r = Red, g = Green, b = Blue )

+

createTeam dose not have a skin argument, But you can do it like :

Team = getPlayerTeam( player ) 
if Team and getTeamName(Team) == 'TeamName' then 
    setElementModel( player, skinID ) 
end 

So this does what exactly?

Creates a team that the player can choose or?

Link to comment

Ok I got a old TDM script from someone.

I posted it , can you tell me what I need to modify to change team names , spawn locations and skins?

This is client not server

I modified it a bit (as much as I knew)

fadeCamera(true,5) 
setCameraMatrix( -1455.2576904297, 700, 95 ,-1527.845703125, 691.43920898438, 111) 
showPlayerHudComponent ( "all", false ) 
  
local function teamauswahleng() 
    destroyElement(flagbox) 
    Teambox = guiCreateWindow(0.3766,0.3417,0.2539,0.1406,"choose a Team",true) 
    guiWindowSetSizable(Teambox,false) 
    teamabtn = guiCreateButton(15,33,100,82,"test",false,Teambox) 
    teambbtn = guiCreateButton(210,35,100,82,"Caesar's Legion",false,Teambox) 
    showCursor(true) 
  
    addEventHandler("onClientGUIClick", teamabtn, function() 
        destroyElement(Teambox) 
        showCursor(false) 
        fadeCamera(false,5) 
        setTimer(function() 
            showPlayerHudComponent ( "all", true ) 
            showPlayerHudComponent ( "area_name", false ) 
            showPlayerHudComponent ( "Money", false ) 
            triggerServerEvent("TeamAauswahl", getLocalPlayer()) 
            removeEventHandler("onClientRender",root,infobox) 
        end,5000,1) 
    end) 
  
    addEventHandler("onClientGUIClick", teambbtn, function() 
        destroyElement(Teambox) 
        showCursor(false) 
        fadeCamera(false,5) 
        setTimer(function() 
            showPlayerHudComponent ( "all", true ) 
            showPlayerHudComponent ( "area_name", false ) 
            showPlayerHudComponent ( "Money", false ) 
            triggerServerEvent("TeamBauswahl", getLocalPlayer()) 
            removeEventHandler("onClientRender",root,infobox) 
        end,5000,1) 
    end) 
end 
  
local function teamauswahlger() 
    destroyElement(flagbox) 
    Teambox = guiCreateWindow(0.3766,0.3417,0.2539,0.1406,"Wählen Sie bitte ein Team aus",true) 
    guiWindowSetSizable(Teambox,false) 
    teamabtn = guiCreateButton(15,33,100,82,"test",false,Teambox) 
    teambbtn = guiCreateButton(210,35,100,82,"Caesar's Legion",false,Teambox) 
    showCursor(true) 
  
    addEventHandler("onClientGUIClick", teamabtn, function() 
        destroyElement(Teambox) 
        showCursor(false) 
        fadeCamera(false,5) 
        setTimer(function() 
            showPlayerHudComponent ( "all", true ) 
            showPlayerHudComponent ( "area_name", false ) 
            showPlayerHudComponent ( "Money", false ) 
            triggerServerEvent("TeamAauswahl", getLocalPlayer()) 
            removeEventHandler("onClientRender",root,infobox) 
        end,5000,1) 
    end) 
  
    addEventHandler("onClientGUIClick", teambbtn, function() 
        destroyElement(Teambox) 
        showCursor(false) 
        fadeCamera(false,5) 
        setTimer(function() 
            showPlayerHudComponent ( "all", true ) 
            showPlayerHudComponent ( "area_name", false ) 
            showPlayerHudComponent ( "Money", false ) 
            triggerServerEvent("TeamBauswahl", getLocalPlayer()) 
            removeEventHandler("onClientRender",root,infobox) 
        end,5000,1) 
    end) 
end 
  
setTimer(function() 
    flagbox = guiCreateWindow(0.3766,0.3417,0.2539,0.1406,"choose a Language/wähle eine Sprache",true) 
    guiWindowSetSizable(flagbox,false) 
    flageng = guiCreateStaticImage(15,33,100,82,"images/language/eng.png",false,flagbox) 
    flagger = guiCreateStaticImage(210,35,100,82,"images/language/ger.png",false,flagbox) 
    flagengbtn = guiCreateButton(15,33,100,82,"",false,flagbox) 
    flaggerbtn = guiCreateButton(210,35,100,82,"",false,flagbox) 
    showCursor(true) 
  
    function infobox() 
        dxDrawImage ( -15, 870, 250, 100, 'images/info.png', 0, 0, 0 ) 
        local scriptinfo = dxDrawText("Script by HeArTBeaT",10, 885, 1265, 1000, tocolor(255,255,255,255),1,"pricedown","left","top",true,false,false) 
        local versioninfo = dxDrawText("Fallout San Andreas",10, 917, 1265, 939,tocolor(255,255,255,255),1,"pricedown","left","top",true,false,false) 
    end 
    addEventHandler("onClientRender",root,infobox) 
  
    addEventHandler("onClientGUIClick", flagengbtn, function() 
        teamauswahleng() 
    end) 
  
    addEventHandler("onClientGUIClick", flaggerbtn, function() 
        teamauswahlger() 
    end) 
end,5000,1) 

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

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