Pawn Code??

  • Hi,


    Warum funktioniert bei mir der Pawn Code nicht richtig?


    Schaut mal


    public OnPlayerSpawn(playerid){ switch(GetPVarInt(playerid,"Fraktion")) { case 0: {} case 1: {SetPlayerCameraLookAt(playerid,-1737.1488,-580.0195,25.0168); SetPlayerCameraPos(playerid,-1746.5472,-579.8239,27.0168); AddPlayerClass(265,-1313.4124,-310.0840,37.9846,269.15,3,1000,24,1000,29,1000); AddPlayerClass(266,-1313.4124,-310.0840,37.9846,269.15,3,1000,24,1000,29,1000); AddPlayerClass(267,-1313.4124,-310.0840,37.9846,269.15,3,1000,24,1000,29,1000); SetPlayerColor(playerid,0x007AFFFF);} case 2: {SetPlayerPos(playerid,Terrorspawn); GivePlayerWeapon(playerid,22,1000); GivePlayerWeapon(playerid,1,1000); GivePlayerWeapon(playerid,24,1000); GivePlayerWeapon(playerid,30,1000); SetPlayerColor(playerid,COLOR_RED);} case 3: {SetPlayerPos(playerid,Stunterspawn);} }}



    Warum wird da alles hintereinander geschrieben? Das war früher nicht so...



    Ist das bei euch auch der Fall?'


    Mfg Vince


  • public OnPlayerSpawn(playerid)
    {
    switch(GetPVarInt(playerid,"Fraktion"))
    {
    case 0: {}
    case 1: {AddPlayerClass(265,-1313.4124,-310.0840,37.9846,269.15,3,1000,24,1000,29,1000); AddPlayerClass(266,-1313.4124,-310.0840,37.9846,269.15,3,1000,24,1000,29,1000); AddPlayerClass(267,-1313.4124,-310.0840,37.9846,269.15,3,1000,24,1000,29,1000); SetPlayerColor(playerid,0x007AFFFF);}
    case 2: {SetPlayerPos(playerid,Terrorspawn); GivePlayerWeapon(playerid,22,1000); GivePlayerWeapon(playerid,1,1000); GivePlayerWeapon(playerid,24,1000); GivePlayerWeapon(playerid,30,1000); SetPlayerColor(playerid,COLOR_RED);}
    case 3: {SetPlayerPos(playerid,Stunterspawn);}
    }
    }


    aah Cool Danke!