1. Post #1

    January 2012
    261 Posts
    I am in despair, server crashes constantly, I tried a variety of options

    Code:
    //AMBRO MADE THIS - TOSS IT IN LUA/AUTORUN/SERVER
    
    hook.Add("Think","AMB_CrashCatcher",function()
    	for k, ent in pairs(ents.FindByClass("prop_ragdoll")) do
    		if IsValid(ent) then
    			if ent.player_ragdoll then
    				local velo = ent:GetVelocity( ):Length()
    				if velo >= 1500 and velo <= 2499 then
    					AMB_KillVelocity(ent)
    					ServerLog("[!CRASHCATCHER!] Caught velocity > 1500 on a ragdoll entity, negating velocity and temporarily disabling motion.\n")
    				elseif velo >= 2500 then
    					ent:Remove()
    					ServerLog("[!CRASHCATCHER!] Caught velocity > 2500 on a ragdoll entity, removing offending ragdoll entity from world.\n")
    				end
    			end
    		end
    	end
    end)
    
    function AMB_SetSubPhysMotionEnabled(ent, enable)
       if not IsValid(ent) then return end
    
       for i=0, ent:GetPhysicsObjectCount()-1 do
          local subphys = ent:GetPhysicsObjectNum(i)
          if IsValid(subphys) then
             subphys:EnableMotion(enable)
             if enable then
                subphys:Wake()
             end
          end
       end
    end
    
    function AMB_KillVelocity(ent)
       ent:SetVelocity(vector_origin)
    
       -- The only truly effective way to prevent all kinds of velocity and
       -- inertia is motion disabling the entire ragdoll for a tick
       -- for non-ragdolls this will do the same for their single physobj
       AMB_SetSubPhysMotionEnabled(ent, false)
    
       timer.Simple(0, function() AMB_SetSubPhysMotionEnabled(ent, true) end)
    end
    and

    Code:
    hook.Add( "Think", "EntityLeftMap", function()
    	for _, v in pairs( ents.GetAll() ) do
    		if IsValid( v ) and not v:IsPlayer() and not v:IsNPC() and v:GetPos().z <= -2000 then
    			v:Remove()
    		end
    	end
    end )
    does not help...

    Errors:





    crash on all maps (TTT gamemode) if it was because of the Lua errors they would have been in the console, but they are not there

    What's the problem HEEELP!
    Reply With Quote Edit / Delete Show Events Artistic Artistic x 1 (list)

  2. Post #2

    January 2013
    41 Posts
    Обнови сервер и мод. Да именно TTT и еще можно убрать все аддоны и ставить их по одному чтоб узнать в каком из них проблема если она все таки в них есть...
    P.S Sorry for my bad english(
    Reply With Quote Edit / Delete Windows 7 Ukraine Show Events Friendly Friendly x 1 (list)

  3. Post #3

    January 2012
    261 Posts
    MULTI LANG MODE ON =)
    Обнови сервер и мод. Да именно TTT и еще можно убрать все аддоны и ставить их по одному чтоб узнать в каком из них проблема если она все таки в них есть...
    P.S Sorry for my bad english(
    Server updated/Сервер обновил
    Log:
    Инициализация обновления сервера/Initialize update server

    Восстановление файлов и каталогов/repair files and folders


    Обновление сервера через Steam Console Client

    Steam Console Client (c) Valve Corporation
    -- type 'quit' to exit --
    Loading Steam3...OK.
    Loading Steam2...OK.

    Connecting anonymously to Steam Public...Success.
    Success! App '4020' already up to date.
    Redirecting stderr to 'd:\gameservers_def\.tools\SteamCmd\logs\stderr.tx t'
    [ 0%] Checking for available updates...
    [----] Verifying installation...

    Обновление сервера завершено/Updating server сompleted
    TTT latest/TTT итак последний

    Addons: ULX,ULib,PointShop
    Reply With Quote Edit / Delete Windows 7 Russian Federation Show Events