Ergebnis 1 bis 2 von 2

Thema: Kann Befehle nicht mit Console ausführen

  1. #1

    Standard Kann Befehle nicht mit Console ausführen

    Ich hab hier folgendes Lua-Script:

    Code:
    local Team_Sound1 = Sound( "npc/combine_soldier/vo/one.wav" )
    
    local Team_Sound2 = Sound( "npc/combine_soldier/vo/two.wav" )
    
    local Start_Sound = Sound( "vo/Streetwar/Alyx_gate/al_letsgo.wav" )
    
    /*---------------------------------------------------------
       Name:	CreateT
       Desc:	Creates two teams.
    ---------------------------------------------------------*/
    
    local function CreateT()
    
        if ( !player:IsAdmin() ) then return end
    
    	team.SetUp (1, "Admins, Color (0, 0, 255, 0))
    	team.SetUp (2, "Guests, Color (255, 0, 0, 0))
    	self.weapon:EmitSound( Start_Sound )
    	
    end
    
    concommand.Add( "mz_createt", CreateT )
    
    /*---------------------------------------------------------
       Name:	PointT1
       Desc:	Adds Team 1 one point.
    ---------------------------------------------------------*/
    
    local function PointT1()
    	
    	if ( !player:IsAdmin() ) then return end
    	
    	team.AddScore (1, 1)
    	self.Weapon:EmitSound( Team_Sound1 )
    	
    end
    
    concommand.Add( "mz_point1", PointT1 )
    
    /*---------------------------------------------------------
       Name:	PointT2
       Desc:	Adds Team 2 one point.
    ---------------------------------------------------------*/
    
    local function PointT2()
    	
    	if ( !player:IsAdmin() ) then return end
    	
    	team.AddScore (2, 1)
    	self.Weapon:EmitSound( Team_Sound2 )
    	
    end
    
    concommand.Add( "mz_point2", PointT2 )
    Wenn ich die Befehle mz_createt ; mz_point1 ; mz_point2 in die Console schreibe, steht da nur "unknown command". Wie behebe ich den Fehler?

    MfG MarvZombie


    [youtube]RiV_ue-PbL4[/youtube]

  2. #2

    Standard AW: Kann Befehle nicht mit Console ausführen

    öhm klare sache

    1. Wo is das
    Code:
    if !CLIENT then return end
    2. isses im autorun ordner? wenn ja welcher Client oder Server? wenn nich hasses vorher mit lua_openscript_cl geladen?

    wenn das alles zutrifft guck ich mirs nochmal an vorher machts keinen sinn Oo

Berechtigungen

  • Neue Themen erstellen: Nein
  • Themen beantworten: Nein
  • Anhänge hochladen: Nein
  • Beiträge bearbeiten: Nein
  •