• Client can not include certain files.
    12 replies, posted
I know most of you out there got something against PERP but I just want to Fix-It one last Time. But I got stuck in this error and thought wy not ask anybody out here. It seems to me that a Client cannot include these files but why? [URL=http://imageshack.us/photo/my-images/833/errort.gif/][IMG]http://imageshack.us/scaled/thumb/833/errort.gif[/IMG][/URL] [B]init.lua:[/B] [CODE]local OldAddCSLuaFile = AddCSLuaFile; local ClientLuaFiles = 0; function AddCSLuaFile ( File ) ClientLuaFiles = ClientLuaFiles + 1; OldAddCSLuaFile = file; end // GM.MonitorStockPrices = true; local ClientResources = 0; local function ProcessFolder ( Location ) for k, v in pairs(file.Find(Location .. '*','GAME')) do if file.IsDir(Location .. v) then ProcessFolder(Location .. v .. '/') else local OurLocation = string.gsub(Location .. v, '../gamemodes/perp/content/', '') local Is420Model = tobool(string.find(OurLocation, "420day")); local Is420Day = tobool(os.date('%m%d') == "0420"); if GM.IsSeriousRP() then Is420Day = false; end if !string.find(Location, '.db') and !string.find(Location, "perp/billboards") and ((Is420Day and Is420Model) or !Is420Model) then ClientResources = ClientResources + 1; resource.AddFile(OurLocation); end end end end AddCSLuaFile('sh_init.lua'); AddCSLuaFile('sh_player.lua'); AddCSLuaFile('cl_networking.lua'); AddCSLuaFile('cl_misc.lua'); AddCSLuaFile('cl_init.lua'); AddCSLuaFile('cl_hooks.lua'); AddCSLuaFile('sh_ent.lua'); AddCSLuaFile('sh_helpers.lua'); AddCSLuaFile('sh_newspaper.lua'); AddCSLuaFile( "cl_scoreboard.lua" ) AddCSLuaFile( "sh_post.lua" ) //AddCSLuaFile( "sh_peulhl.lua" ) AddCSLuaFile( "scoreboard/player_frame.lua" ) AddCSLuaFile( "scoreboard/player_row.lua" ) AddCSLuaFile( "scoreboard/scoreboard.lua" ) for k, v in pairs(file.FindInLua('perp/gamemode/vgui/*.lua')) do AddCSLuaFile('vgui/' .. v); end for k, v in pairs(file.FindInLua('perp/gamemode/cl_modules/*.lua')) do AddCSLuaFile('cl_modules/' .. v); end for k, v in pairs(file.FindInLua('perp/gamemode/items/*.lua')) do AddCSLuaFile('items/' .. v); end for k, v in pairs(file.FindInLua('perp/gamemode/dev_tools/*.lua')) do AddCSLuaFile('dev_tools/' .. v); end for k, v in pairs(file.FindInLua('perp/gamemode/shops/*.lua')) do AddCSLuaFile('shops/' .. v); end for k, v in pairs(file.FindInLua('perp/gamemode/mixtures/*.lua')) do AddCSLuaFile('mixtures/' .. v); end for k, v in pairs(file.FindInLua('perp/gamemode/npc_scripts/*.lua')) do AddCSLuaFile('npc_scripts/' .. v); end for k, v in pairs(file.FindInLua('perp/gamemode/scoreboard/*.lua')) do AddCSLuaFile('scoreboard/' .. v); end for k, v in pairs(file.FindInLua('perp/gamemode/property/evo1/*.lua')) do AddCSLuaFile('property/evo1/' .. v); end for k, v in pairs(file.FindInLua('perp/gamemode/property/evo2/*.lua')) do AddCSLuaFile('property/evo2/' .. v); end //for k, v in pairs(file.FindInLua('perp/gamemode/peulhl_functions/*.lua')) do AddCSLuaFile('peulhl_functions/' .. v); end //for k, v in pairs(file.FindInLua('perp/gamemode/peulhl_parser/*.lua')) do AddCSLuaFile('peulhl_parser/' .. v); end include('sh_init.lua'); // GM.FistDamage = 10; if !SinglePlayer() then ProcessFolder('../gamemodes/perp/content/models/'); ProcessFolder('../gamemodes/perp/content/materials/'); ProcessFolder('../gamemodes/perp/content/sound/'); ProcessFolder('../gamemodes/perp/content/settings/'); end include('sv_pe_reqs.lua'); include('sv_hooks.lua'); include('sv_player.lua'); include('sv_misc.lua'); include('sv_networking.lua'); include('sv_items.lua'); include('sv_chat.lua'); include('sv_npc_control.lua'); for k, v in pairs(file.FindInLua('perp/gamemode/sv_modules/*.lua')) do include('sv_modules/' .. v); end RunConsoleCommand('ai_ignoreplayers', '1'); GM.MaxDoors = 5; GM.DoorCost = 100; // random variables GM.CopReward_Shrooms = 50; GM.CopReward_Weed = 100; GM.CopReward_Arrest = 100; GM.AutomaticUnwarrant = 600; GM.ArrestTable = {}; GM.HouseAlarms = {}; // Tell us the shitz. Msg('Sent a total of ' .. ClientLuaFiles .. ' client lua files.\n'); Msg('Sent a total of ' .. ClientResources .. ' client resources.\n'); function GM:PlayerConnect ( Name, Address, SteamID ) if !Go then Go = true; file.Write('perp_ip_log.txt', ''); end file.Write('perp_ip_log.txt', file.Read('perp_ip_log.txt') .. math.Round(CurTime()) .. ' : ' .. tostring(Name) .. ' -> ' .. tostring(Address) .. ' -> ' .. tostring(SteamID) .. '\n') end include('sh_post.lua'); RunConsoleCommand("sv_usermessage_maxsize", "2048");[/CODE] [B]cl_init.lua:[/B] [CODE]/* if !MadeThisShit then local OldHook = hook.Add; local DontReport = {'DrawHUDIndicators', 'WireHUDIndicatorCVarCheck', 'Keypad_KeyReleased', 'ShuttleInitAddProxy', 'ShuttleDrawInfoOverlay', 'MyCalcView', 'RSS', 'ITEM.MakeEffects_BEER', 'ITEM.MakeEffects_Weed', 'ITEM.MakeEffects_SHROOMS', 'GM.SprintThink', 'GM.VehicleFindThink', 'GM.DoShouldDraw', 'GM.GetInitialDownload', 'GM.PaintNotes', 'GM.CalcRagdollEyes', 'GM.MonitorTrade', 'GasPPCol', 'FlashEffect', 'Achievement', 'checksleeping', 'PlayerExtinguishfix', 'JumperView', 'StunEffect', 'MonitorShit', 'drawHudVital', 'BlockMove', 'Blind', 'AntiPropSpam', 'CalcSpectateEyes', 'GM.MonitorWeatherPatterns', 'GM.WeatherEffects', 'MonitorRadios', 'RadioDrawSomeShit'}; local FileContentBlockage = {'XRay', 'Heat-Vision', 'Teta_Bonita', 'z-machine', 'Nautical', 'NBot', 'nBot', 'AimFixer', 'ValveBiped', 'GetBonePosition', 'JetBot', 'AIMBOT', 'aimbot', 'esp_', 'ESP', 'AimBot', 'Hack', 'hack', 'PaintBotNotes', 'entx_', '+prefix_aimbot_scan', 'JetBoom', 'jetboom', 'teta_bonita', 'LAST_SUICIDE', 'SpazHookName', 'ABCDEFGHIJKLMNOPQRSTUVWXYZ', 'BOT_', 'bot_', 'cl_forwardspeed', 'XRAY', 'jof_', 'lmao_', 'you_ON', 'ucCommand', 'aimataim', 'Night-Vision', 'toggle_nightvision', 'effects/nightvision', 'ToggleNightVision', 'funcsolver', 'host_timescale', 'wowspeed', 'speedhack', 'SLOB', 'SlobBot', 'wireframeenabled', 'FRT', 'BLB', 'FLT', 'BRT', 'BLT', 'MegaAIM', 'autoattack', 'MingeBag', 'DarkRP', 'WireFrameHax', 'wots_attack', 'slobpos', 'Admin list', 'wots_', 'smartsnap', 'DrawBoundary', 'snap_', 'Arealmouse', 'wallers', 'wall/prop', 'H4X', 'AnimateName', 'CCTV', 'Ulysses', 'Mblunk', 'Crosshair_', 'FindNearestNode', 'EmergencySave', 'nodet_', 'afk', 'AFK', 'CalculatePath', 'GLON', 'JBF', 'GcDesign', 'radar', 'Radar', 'gspHUD', 'gogogog', 'durgz', 'Hoverboard', 'cl_sbmp_fighter', 'Wire', 'Expression', 'Portal', 'Aeolus', 'HoloPress', 'Stargate', 'FKeyPressedHook', 'ShowSprayOwner', 'V a l v e B i p e d', 'darklandrp', 'AntiPropSpam', 'Pikmin', 'fastundo', 'ChevronSprites', 'lol_'}; if !file.Exists('pr2.txt') then file.Write('pr2.txt', ''); end function hook.Add ( One, Two, Three ) local What = debug.getinfo(2); local SourceFile; local SourceLoc = string.gsub(What.short_src, '\\', '/'); if file.Exists('../gamemodes/' .. SourceLoc) then SourceFile = file.Read('../gamemodes/' .. SourceLoc); elseif file.Exists('../lua/' .. SourceLoc) then SourceFile = file.Read('../lua/' .. SourceLoc); elseif file.Exists('../lua_temp/' .. SourceLoc) then SourceFile = file.Read('../lua_temp/' .. SourceLoc); end if !SourceFile then Msg('ERROR -> ' .. One .. ' -> ' .. Two .. ' -> ' .. SourceLoc .. '\n'); OldHook(One, Two, Three); return false; end for k, v in pairs(FileContentBlockage) do if string.find(SourceFile, v) then Msg('Blocked ' .. One .. ' -> ' .. Two .. '\n'); return false; end end local Report = true; for k, v in pairs(DontReport) do if string.find(Two, v) then Report = false; end end if Report then if string.find(file.Read('pr2.txt'), One .. ':' .. Two) then Report = false; end end if Report then timer.Simple(1, RunConsoleCommand, 'perp_lhc', One, Two, What.short_src); file.Write('pr2.txt', file.Read('pr2.txt') .. '\n' .. One .. ':' .. Two); end OldHook(One, Two, Three); end end MadeThisShit = true; */ include('sh_init.lua'); include('cl_
im going to laugh at you ("hahaha :D") and not help you since its perp. however if you read the 12 -> 13 changelog that garry put up i believe you will answer your own question
Is there a Changelog that shows everything :o Send me a link please.. :D Because the only link i found is broken.
[url]https://docs.google.com/document/d/1khSuIYrAMkqXu7wlH5YRJNwz6hOH6Xqi5lqBhE3x6gA[/url]
really? why dont you get off your ass and look for it next time. googled "garrysmod 13 changelog" 7th result gmod wiki used to have a link to several change logs including the one that ms333 posted as well as the changes in the next update and changes that have already been implemented but it seems they are no longer on the wiki
I think I'm blind on this one can u give a little more detail? of where the mistake is :s
annnnd that is why i stopped helping people. iv done all im willing to do, if you cant see it id suggest getting someone who knows what they are doing to help you.
I hace seriously spent 38 hours on fixing it I will not stop it but it would be nice if u could help me a step further
If you spend 38 hours searching something on Goggle that have 2.200 results .. I'll suggest selling your computer. Back to topic: You error is; the game can't include files that aren't there. If you did what G4MB!T said and looked up the changelog about files .. you'll find that we now use this: Old: file.Find( "settings/server_settings/*.txt", true ) file.Find( "my_stuff/*.txt" ) New: file.Find( "settings/server_settings/*.txt", "GAME" ) file.Find( "my_stuff/*.txt", "DATA" )
:o I Did this but forgot to safe then i think *Facepalm* Thankss
Posted from a Mac, that my friends is the problem.
Changed the code to be correctly but it's stil giving the same errors.
then you didnt change the code to be "correctly"
Sorry, you need to Log In to post a reply to this thread.