{"action":"created","issue":{"url":"https://api.github.com/repos/Southclaw/ScavengeSurvive/issues/201","repository_url":"https://api.github.com/repos/Southclaw/ScavengeSurvive","labels_url":"https://api.github.com/repos/Southclaw/ScavengeSurvive/issues/201/labels{/name}","comments_url":"https://api.github.com/repos/Southclaw/ScavengeSurvive/issues/201/comments","events_url":"https://api.github.com/repos/Southclaw/ScavengeSurvive/issues/201/events","html_url":"https://github.com/Southclaw/ScavengeSurvive/issues/201","id":143823057,"number":201,"title":"Multi-Language Support","user":{"login":"Southclaw","id":1636971,"avatar_url":"https://avatars.githubusercontent.com/u/1636971?v=3","gravatar_id":"","url":"https://api.github.com/users/Southclaw","html_url":"https://github.com/Southclaw","followers_url":"https://api.github.com/users/Southclaw/followers","following_url":"https://api.github.com/users/Southclaw/following{/other_user}","gists_url":"https://api.github.com/users/Southclaw/gists{/gist_id}","starred_url":"https://api.github.com/users/Southclaw/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Southclaw/subscriptions","organizations_url":"https://api.github.com/users/Southclaw/orgs","repos_url":"https://api.github.com/users/Southclaw/repos","events_url":"https://api.github.com/users/Southclaw/events{/privacy}","received_events_url":"https://api.github.com/users/Southclaw/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/Southclaw/ScavengeSurvive/labels/enhancement","name":"enhancement","color":"84b6eb"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":7,"created_at":"2016-03-27T15:56:16Z","updated_at":"2016-04-28T10:56:03Z","closed_at":null,"body":"Now that a module has been added to support multiple languages, translation must be done.\r\n\r\nI will explain how the module works and the code syntax for sending messages based on a player's language.\r\n\r\nOriginal code:\r\n```\r\nMsg(playerid, YELLOW, \" >  Language changed to English!\");\r\n```\r\n\r\nNew code:\r\n```\r\nMsg(playerid, YELLOW, L:playerid[\"LANGCHANGE\"]);\r\n```\r\n\r\nThe original string now exists in ```./scriptfiles/SSS/languages/English\"```:\r\n```\r\nLANGCHANGE= >  Language changed to English!\r\n```\r\nAlong with translations in other files, such as ```./scriptfiles/SSS/languages/English\"```:\r\n```\r\nLANGCHANGE= >  Idioma alterado para Português\r\n```\r\n\r\nSo to add a translation, replace the original static string with the new syntax and a unique \"tag\" for that particular string of text. Then add that string of text to the English translation file and your translated version to the respected file.\r\n\r\nIMPORTANT:\r\nOnce you've added the original English version and your translated version, if there are other language files present you cannot leave out the tag you just added. You must add the English version to all other language files so the original string exists there until a translation for that language is added.\r\n\r\nFor example, I don't know French so until someone adds a French translation, this is what the file ```./scriptfiles/SSS/languages/French\"``` looks like:\r\n```\r\nLANGCHANGE= >  Language changed to French (No translation yet)!\r\n```\r\n"},"comment":{"url":"https://api.github.com/repos/Southclaw/ScavengeSurvive/issues/comments/215388032","html_url":"https://github.com/Southclaw/ScavengeSurvive/issues/201#issuecomment-215388032","issue_url":"https://api.github.com/repos/Southclaw/ScavengeSurvive/issues/201","id":215388032,"user":{"login":"Southclaw","id":1636971,"avatar_url":"https://avatars.githubusercontent.com/u/1636971?v=3","gravatar_id":"","url":"https://api.github.com/users/Southclaw","html_url":"https://github.com/Southclaw","followers_url":"https://api.github.com/users/Southclaw/followers","following_url":"https://api.github.com/users/Southclaw/following{/other_user}","gists_url":"https://api.github.com/users/Southclaw/gists{/gist_id}","starred_url":"https://api.github.com/users/Southclaw/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Southclaw/subscriptions","organizations_url":"https://api.github.com/users/Southclaw/orgs","repos_url":"https://api.github.com/users/Southclaw/repos","events_url":"https://api.github.com/users/Southclaw/events{/privacy}","received_events_url":"https://api.github.com/users/Southclaw/received_events","type":"User","site_admin":false},"created_at":"2016-04-28T10:56:03Z","updated_at":"2016-04-28T10:56:03Z","body":"Just a quick note, I added the replacements mentioned in my previous post. You can leave things like \"C_YELLOW\" but just replace the quote marks with {} (easy with regex search and replace)\r\n\r\nhttps://github.com/Southclaw/ScavengeSurvive/blob/9a847d0fbc23e705d6c16fb4e03923717bc757d4/gamemodes/sss/core/server/language.pwn#L70-L94\r\n\r\nI've also completed English definitions for all calls to ShowActionText, if anyone is planning to contribute please ensure you have the latest version of the code synced locally so you know what has already been done!"}}