Phiilip~* Posted March 5, 2013 Share Posted March 5, 2013 when I start the 'race' also automatically start 'race_traffic_sensor' and 'race_toptimes' race_traffic_sensor I not want to start when I start the race, and I changed the name race_toptimes to JK_toptimes obviously the race tries to find race_toptimes and can not find... how do I change it? Thanks! (and sorry for bad english ><') Link to comment
Anderl Posted March 5, 2013 Share Posted March 5, 2013 (edited) It is in the 'meta.xml' file in 'race' gamemode, search for 'include' sub-nodes. EDIT: Exactly as Anony said, I actually thought these were included resources, my bad Edited March 5, 2013 by Guest Link to comment
Anony# Posted March 5, 2013 Share Posted March 5, 2013 @ Anderl, is not the "meta.xml" remove the following lines from his "race_server.lua" --for _,line in ipairs(Addons.report) do --outputConsole ( 'Race addon: ' .. line, source ) --end --------------------------------------------------------------------- --[[ addEventHandler('onResourceStart', g_ResRoot, function() outputDebugString('Race resource starting') startAddons() end ) ]]-- ----------------------------------------------------------------------- -- addon management Addons = {} Addons.report = {} Addons.reportShort = '' -- Start addon resources listed in the setting 'race.addons' function startAddons() Addons.report = {} Addons.reportShort = '' -- Check permissions local bCanStartResource = hasObjectPermissionTo ( getThisResource(), "function.startResource", false ) local bCanStopResource = hasObjectPermissionTo ( getThisResource(), "function.stopResource", false ) if not bCanStartResource or not bCanStopResource then local line1 = 'WARNING: Race does not have permission to start/stop resources' local line2 = 'WARNING: Addons may not function correctly' outputDebugString( line1 ) outputDebugString( line2 ) table.insert(Addons.report,line1) table.insert(Addons.report,line2) end for idx,name in ipairs(string.split(getString('race.addons'),',')) do if name ~= '' then local resource = getResourceFromName(name) if not resource then outputWarning( "Can't use addon '" .. name .. "', as it is not the name of a resource" ) else if getResourceInfo ( resource, 'addon' ) ~= 'race' then outputWarning( "Can't use addon " .. name .. ', as it does not have addon="race" in the info section' ) else -- Start or restart resource if getResourceState(resource) == 'running' then stopResource(resource) TimerManager.createTimerFor("raceresource"):setTimer( function() startResource(resource) end, 200, 1 ) else startResource(resource) end -- Update Addons.report local tag = getResourceInfo ( resource, 'name' ) or getResourceName(resource) local build = getResourceInfo ( resource, 'build' ) or '' local version = getResourceInfo ( resource, 'version' ) or '' local author = getResourceInfo ( resource, 'author' ) or '' local description = getResourceInfo ( resource, 'description' ) or '' local line = tag .. ' - ' .. description .. ' - by ' .. author .. ' - version [' .. version .. '] [' .. build .. ']' table.insert(Addons.report,line) -- Update Addons.reportShort if Addons.reportShort ~= '' then Addons.reportShort = Addons.reportShort .. ', ' end Addons.reportShort = Addons.reportShort .. tag end end end end end Link to comment
Anderl Posted March 5, 2013 Share Posted March 5, 2013 I figured that out before you edited the reply. I don't use 'race' gamemode since much time ago, I thought these resources were includes. Link to comment
Phiilip~* Posted March 5, 2013 Author Share Posted March 5, 2013 Ok , in my race_server I canceled the functions --[[addEventHandler('onPlayerJoin', g_Root, function() outputConsole ( 'Race version ' .. getBuildString(), source, 255, 127, 0 ) for _,line in ipairs(Addons.report) do outputConsole ( 'Race addon: ' .. line, source ) end end )]]-- and --[[addEventHandler('onResourceStart', g_ResRoot, function() outputDebugString('Race resource starting') startAddons() end )]]-- As said Anony... btw I found this in meta "#addons" value="race_toptimes,race_traffic_sensor" accept="*" desc="List of race addon resources to load automatically" /> Should I change something? Link to comment
Anony# Posted March 5, 2013 Share Posted March 5, 2013 you can delete or dexar it will not change anything if you edited the "race_server.lua" Link to comment
Phiilip~* Posted March 5, 2013 Author Share Posted March 5, 2013 Help me again pls the 'votemanager' is still starting with the server, after I removed this line: that was in mtaserver.conf What I need to make it not start? Link to comment
Anony# Posted March 5, 2013 Share Posted March 5, 2013 remove the line from "meta.xml" <include resource="votemanager"/> observation resource "race" Link to comment
Phiilip~* Posted March 5, 2013 Author Share Posted March 5, 2013 Ok , work Thanks again... Link to comment
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now