{"action":"created","issue":{"url":"https://api.github.com/repos/Facepunch/garrysmod-issues/issues/2180","labels_url":"https://api.github.com/repos/Facepunch/garrysmod-issues/issues/2180/labels{/name}","comments_url":"https://api.github.com/repos/Facepunch/garrysmod-issues/issues/2180/comments","events_url":"https://api.github.com/repos/Facepunch/garrysmod-issues/issues/2180/events","html_url":"https://github.com/Facepunch/garrysmod-issues/issues/2180","id":99695454,"number":2180,"title":"sbox_persist doesn't persist through server restarts","user":{"login":"Fuzzik","id":4961219,"avatar_url":"https://avatars.githubusercontent.com/u/4961219?v=3","gravatar_id":"","url":"https://api.github.com/users/Fuzzik","html_url":"https://github.com/Fuzzik","followers_url":"https://api.github.com/users/Fuzzik/followers","following_url":"https://api.github.com/users/Fuzzik/following{/other_user}","gists_url":"https://api.github.com/users/Fuzzik/gists{/gist_id}","starred_url":"https://api.github.com/users/Fuzzik/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Fuzzik/subscriptions","organizations_url":"https://api.github.com/users/Fuzzik/orgs","repos_url":"https://api.github.com/users/Fuzzik/repos","events_url":"https://api.github.com/users/Fuzzik/events{/privacy}","received_events_url":"https://api.github.com/users/Fuzzik/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":7,"created_at":"2015-08-07T17:44:18Z","updated_at":"2015-08-07T22:14:19Z","closed_at":null,"body":"sbox_persist \"1\" is in my server.cfg, thus being set before the map loads. Making an entity persistent and using changelevel to see if it is still there works fine, but even after using changelevel to load the same map, persistent entities are gone after a server restart.\r\n\r\nThe persist file for the map \"data/persist/mapname_1.txt\" is still there, but it's as if it's being ignored by the game."},"comment":{"url":"https://api.github.com/repos/Facepunch/garrysmod-issues/issues/comments/128845203","html_url":"https://github.com/Facepunch/garrysmod-issues/issues/2180#issuecomment-128845203","issue_url":"https://api.github.com/repos/Facepunch/garrysmod-issues/issues/2180","id":128845203,"user":{"login":"robotboy655","id":3299036,"avatar_url":"https://avatars.githubusercontent.com/u/3299036?v=3","gravatar_id":"","url":"https://api.github.com/users/robotboy655","html_url":"https://github.com/robotboy655","followers_url":"https://api.github.com/users/robotboy655/followers","following_url":"https://api.github.com/users/robotboy655/following{/other_user}","gists_url":"https://api.github.com/users/robotboy655/gists{/gist_id}","starred_url":"https://api.github.com/users/robotboy655/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/robotboy655/subscriptions","organizations_url":"https://api.github.com/users/robotboy655/orgs","repos_url":"https://api.github.com/users/robotboy655/repos","events_url":"https://api.github.com/users/robotboy655/events{/privacy}","received_events_url":"https://api.github.com/users/robotboy655/received_events","type":"User","site_admin":false},"created_at":"2015-08-07T22:14:19Z","updated_at":"2015-08-07T22:14:19Z","body":"Add it to the file, restart your server and look for server console output.\r\n```\r\nhook.Add( \"InitPostEntity\", \"PersistenceInit\", function()\r\n\r\n\tlocal PersistPage = GetConVarString( \"sbox_persist\" )\r\n\tprint(\"DONT MISS ME: ------------------------------------- \", PersistPage)\r\n\tif ( PersistPage == \"0\" ) then return end\r\n\r\n\thook.Run( \"PersistenceLoad\", PersistPage );\r\n\t\r\nend )\r\n```"}}