Beiträge von Mr.Troll

    Lua
    hausLift = createObject ( 3114, 2091.2998046875, 2362.8994140625, 21.94, 0, 0, 179.99450683594)
    Status = 0function autoLift_func( player )     local pname = getPlayerName ( player )    if (pname == "Troll") then  if Status == 0 then     moveObject( hausLift, 2091.2998046875, 2362.8994140625, 9.8299999237061 )     Status = 1     outputChatBox("Lift wird nach unten gefahren", player, 0, 255, 0 )	 local sound = playsound ("sounds/lift.mp3")	 setSoundVolume (sound, 1)  else     moveObject( hausLIft, 2091.2998046875, 2362.8994140625, 21.94 )     Status = 0     outputChatBox("Lift wird nach oben gefahren. Bitte bleiben sie an ihrer jetzigen Position stehen", player, 0, 255, 0 ) 	 local sound = playsound ("sounds/lift.mp3")	 setSoundVolume (sound, 1) end end endaddComandHandler( "Lift", autoLift_func )
    Lua
    hausLift = createObject ( 3114, 2091.2998046875, 2362.8994140625, 21.94, 0, 0, 179.99450683594)
    Status = 0function autoLift_func( player ) local pname = getPlayerName ( player ) if (pname == "Troll") then  if Status == 0 then     moveObject( hausLift, 2091.2998046875, 2362.8994140625, 9.8299999237061 ) Status = 1 outputChatBox("Lift wird nach unten gefahren", player, 0, 255, 0 )	local sound = playsound ("sounds/lift.mp3")	 setSoundVolume sound, 1) else     moveObject( hausLIft, 2091.2998046875, 2362.8994140625, 21.94 ) Status = 0 outputChatBox("Lift wird nach oben gefahren. Bitte bleiben sie an ihrer jetzigen Position stehen", player, 0, 255, 0 ) local sound = playsound ("sounds/lift.mp3")	setSoundVolume (sound, 1) end end endaddComandHandler( "Lift", autoLift_func )

    Ich habe mir mit der Hilfe von YouTube und Mta wiki ein Aufzugsscript gebastelt da kommt nun aber immer ein Fehler in der Konsole das angeblich eine Nil value fehlt nun weis ich aber nicht wie ich dieses ändern soll

    Script:

    hausLift = createObject ( 3114, 2091.2998046875, 2362.8994140625, 21.94, 0, 0, 179.99450683594)

    Status = 0
    function autoLift_func( player )
    local pname = getPlayerName ( player )
    if (pname == "Troll") then
    if Status == 0 then
    moveObject( hausLift, 2091.2998046875, 2362.8994140625, 9.8299999237061 )
    Status = 1
    outputChatBox("Lift wird nach unten gefahren", player, 0, 255, 0 )
    local sound = playsound ("sounds/lift.mp3")
    setSoundVolume (sound, 1)
    else
    moveObject( hausLIft, 2091.2998046875, 2362.8994140625, 21.94 )
    Status = 0
    outputChatBox("Lift wird nach oben gefahren. Bitte bleiben sie an ihrer jetzigen Position stehen", player, 0, 255, 0 )
    local sound = playsound ("sounds/lift.mp3")
    setSoundVolume (sound, 1)
    end
    end
    end
    addComandHandler( "Lift", autoLift_func )

    Ich wollte mir für das Emerald Isle Casino in LV einen Aufzug scripten wo man beim Start also wenn man den Marker des Aufzugs betritt auswählen kann auf welcher ebene des Parkhauses der Aufzug halten soll

    Meine frage:
    Wie geh ich am besten vor? (hab sowas schon mal mit einer Art Teleporter gemacht aber das dann nur zum switchen zwischen zwei ebenen )