Jump to content

[RACE] Vehicles start to blow up after a short time.


Fella

Recommended Posts

Hi, so my problem looks like this:

NAJa6vu.png

gJvN78A.png

all the player vehicles just start to blow up without a pause or interruption, e.g. it happens not in a single round but in all the rounds until server's shutdown.

just restarting race does nothing at all and doesn't affect on this bug, i also tried to upload both new server and admin resources, but it didn't do anything as well, also i checked the logs and they didn't say anything as well, it just sort of starts randomly, without a notice. restarting the server resolves it, but only for like 5 minutes. then it all starts all over again.

could you enlighten me what is it supposed to be and how do i get rid of it? i also checked ACL and none of unknown to me resources have the admin rights neither i gave the rights to any new resource lately. it just randomly started today even though i didn't do anything new/unusual. :shock:

Link to comment
Also be sure noone can access runcode .

how do i do that?

check all custom scripts/resources you have and search for

createExplosion

blowVehicle

i know that a few maps on the server have this clientside script:

  
  
    setTimer( 
        function() 
            if isPedInVehicle( localPlayer ) then 
                local pVehicle = getPedOccupiedVehicle( localPlayer ); 
          if isElementInWater( pVehicle ) and not isVehicleBlown( pVehicle ) then 
                    blowVehicle( pVehicle ); 
                end 
            end 
        end, 
    1000, 0 ); 
  

(it blows up vehicles that fall into water)

but only a handful of maps actually have this script, while there're more than 100 maps on the server and as i said this bug happens on all of them, not only on the specific ones that have this script.

Link to comment

do the thing what Grafu said

i believe you could just check the server.log file in logs folder, all the codes which were run should be in there so if someone has used the runcode to create explosions, you will see it in the log

and other possibility is that just one out of 100 of your maps is 'trolling' you by making explosions for every single map, so if first it wasnt first possibility, then its probably this one

Link to comment

the very first thing i did was checking the logs, but it gave me nothing. i deleted the last 4 maps that i've uploaded today, 1 of them has the script that i showed earlier, also i deleted both runcode and webadmin, yea, it's kinda barbarian solution but for the past past 2,5 years i used them maybe a couple of times, so i didn't lose that much. anyways, i'll see if something changes after this steps, thanks for the tips, guys.

Link to comment

Runcode doesn't output any usage, if used on http. So check, if your http server is only accessible to you. Another thing that might be happening to the vehicles is that the server might think that they are actually in water and trigger your water destruction script (I am not sure, but I guess it happens due to bad handling configuration or some client bugs).

Link to comment
  • MTA Team

You could use addDebugHook to trace where blowVehicle is being called like this:

function onBlowVehicle( sourceResource, functionName, isAllowedByACL, luaFilename, luaLineNumber, ... ) 
    local args = { ... } 
    local resname = sourceResource and getResourceName(sourceResource) 
    outputDebugString( "preFunction" 
        .. " " .. tostring(resname) 
        .. " " .. tostring(functionName) 
        .. " allowed:" .. tostring(isAllowedByACL) 
        .. " file:" .. tostring(luaFilename) 
        .. "(" .. tostring(luaLineNumber) .. ")" 
        .. " numArgs:" .. tostring(#args) 
        .. " arg1:" .. tostring(args[1]) 
        ) 
end 
  
addDebugHook( "preFunction", onBlowVehicle, {"blowVehicle"} )  

Link to comment
Runcode doesn't output any usage, if used on http. So check, if your http server is only accessible to you. Another thing that might be happening to the vehicles is that the server might think that they are actually in water and trigger your water destruction script (I am not sure, but I guess it happens due to bad handling configuration or some client bugs).

as i said i just deleted the runcode resource, but just in case, how do i "check, if your http server is only accessible to you"?

ccw

how do i actually run this code and see what results it will give?

Link to comment
  • MTA Team
how do i actually run this code and see what results it will give?

Save it to a file and add a meta.xml like the one below to create a resource. The results will be in the server log.

<meta> 
    <script src="debughook.lua" /> 
</meta> 

Link to comment
Runcode doesn't output any usage, if used on http. So check, if your http server is only accessible to you. Another thing that might be happening to the vehicles is that the server might think that they are actually in water and trigger your water destruction script (I am not sure, but I guess it happens due to bad handling configuration or some client bugs).

as i said i just deleted the runcode resource, but just in case, how do i "check, if your http server is only accessible to you"?

ccw

how do i actually run this code and see what results it will give?

Open your chrome, enter your http server IP (server IP:http port) and check if it requests for authentification.

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...