{"action":"created","comment":{"url":"https://api.github.com/repos/CBATeam/CBA_A3/pulls/comments/42478093","id":42478093,"diff_hunk":"@@ -0,0 +1,27 @@\n+/* ----------------------------------------------------------------------------\n+Internal Function: CBA_fnc_synchTeamColors\n+\n+Description:\n+    Synchs the team colors every second. Does not need to be called manually.\n+\n+Parameters:\n+    None\n+\n+Returns:\n+    Nothing\n+\n+Author:\n+    BaerMitUmlaut\n+---------------------------------------------------------------------------- */\n+\n+#include \"script_component.hpp\"\n+\n+if (leader player == player) then {\n+    {\n+        if ((assignedTeam _x) != (_x getVariable [QGVAR(synchedTeam), \"MAIN\"])) then {\n+            //Local team != currently synched team, so we need to synchronize them again\n+            [\"CBA_teamColorChanged\", [_x, assignedTeam _x]] call CBA_fnc_globalEvent;","path":"addons/common/fnc_synchTeamColors.sqf","position":23,"original_position":23,"commit_id":"2210b67a2676e76abe65f722acc46341bf0de53b","original_commit_id":"5a396cc199ed24f075f03b6770f79906bdfe65c7","user":{"login":"BaerMitUmlaut","id":9693842,"avatar_url":"https://avatars.githubusercontent.com/u/9693842?v=3","gravatar_id":"","url":"https://api.github.com/users/BaerMitUmlaut","html_url":"https://github.com/BaerMitUmlaut","followers_url":"https://api.github.com/users/BaerMitUmlaut/followers","following_url":"https://api.github.com/users/BaerMitUmlaut/following{/other_user}","gists_url":"https://api.github.com/users/BaerMitUmlaut/gists{/gist_id}","starred_url":"https://api.github.com/users/BaerMitUmlaut/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/BaerMitUmlaut/subscriptions","organizations_url":"https://api.github.com/users/BaerMitUmlaut/orgs","repos_url":"https://api.github.com/users/BaerMitUmlaut/repos","events_url":"https://api.github.com/users/BaerMitUmlaut/events{/privacy}","received_events_url":"https://api.github.com/users/BaerMitUmlaut/received_events","type":"User","site_admin":false},"body":"That's possible too, but would require extension of the PFH (unless there's a CBA event for it? there's no doc for default events and I didn't see any either) and it would ofc have a delay. Without that delay it would be great for triggering a CBA event though.\r\n\r\nEither options aren't perfect in my opinion. Choose your poison...","created_at":"2015-10-20T10:21:06Z","updated_at":"2015-10-20T10:21:06Z","html_url":"https://github.com/CBATeam/CBA_A3/pull/185#discussion_r42478093","pull_request_url":"https://api.github.com/repos/CBATeam/CBA_A3/pulls/185","_links":{"self":{"href":"https://api.github.com/repos/CBATeam/CBA_A3/pulls/comments/42478093"},"html":{"href":"https://github.com/CBATeam/CBA_A3/pull/185#discussion_r42478093"},"pull_request":{"href":"https://api.github.com/repos/CBATeam/CBA_A3/pulls/185"}}},"pull_request":{"url":"https://api.github.com/repos/CBATeam/CBA_A3/pulls/185","id":48009827,"html_url":"https://github.com/CBATeam/CBA_A3/pull/185","diff_url":"https://github.com/CBATeam/CBA_A3/pull/185.diff","patch_url":"https://github.com/CBATeam/CBA_A3/pull/185.patch","issue_url":"https://api.github.com/repos/CBATeam/CBA_A3/issues/185","number":185,"state":"open","locked":false,"title":"Added team color synchronization","user":{"login":"BaerMitUmlaut","id":9693842,"avatar_url":"https://avatars.githubusercontent.com/u/9693842?v=3","gravatar_id":"","url":"https://api.github.com/users/BaerMitUmlaut","html_url":"https://github.com/BaerMitUmlaut","followers_url":"https://api.github.com/users/BaerMitUmlaut/followers","following_url":"https://api.github.com/users/BaerMitUmlaut/following{/other_user}","gists_url":"https://api.github.com/users/BaerMitUmlaut/gists{/gist_id}","starred_url":"https://api.github.com/users/BaerMitUmlaut/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/BaerMitUmlaut/subscriptions","organizations_url":"https://api.github.com/users/BaerMitUmlaut/orgs","repos_url":"https://api.github.com/users/BaerMitUmlaut/repos","events_url":"https://api.github.com/users/BaerMitUmlaut/events{/privacy}","received_events_url":"https://api.github.com/users/BaerMitUmlaut/received_events","type":"User","site_admin":false},"body":"This synchronizes fireteam colors across the network. Other addons can either call the `\"CBA_teamColorChanged\"` event or indirectly trigger that event by remote calling `assignTeam` on the squad leaders machine.\r\n\r\nSee issue #94.","created_at":"2015-10-18T14:44:57Z","updated_at":"2015-10-20T10:21:06Z","closed_at":null,"merged_at":null,"merge_commit_sha":"090bba6c62e363477616e0c97b8398591d71024e","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/CBATeam/CBA_A3/pulls/185/commits","review_comments_url":"https://api.github.com/repos/CBATeam/CBA_A3/pulls/185/comments","review_comment_url":"https://api.github.com/repos/CBATeam/CBA_A3/pulls/comments{/number}","comments_url":"https://api.github.com/repos/CBATeam/CBA_A3/issues/185/comments","statuses_url":"https://api.github.com/repos/CBATeam/CBA_A3/statuses/2210b67a2676e76abe65f722acc46341bf0de53b","head":{"label":"BaerMitUmlaut:synch-team-colors","ref":"synch-team-colors","sha":"2210b67a2676e76abe65f722acc46341bf0de53b","user":{"login":"BaerMitUmlaut","id":9693842,"avatar_url":"https://avatars.githubusercontent.com/u/9693842?v=3","gravatar_id":"","url":"https://api.github.com/users/BaerMitUmlaut","html_url":"https://github.com/BaerMitUmlaut","followers_url":"https://api.github.com/users/BaerMitUmlaut/followers","following_url":"https://api.github.com/users/BaerMitUmlaut/following{/other_user}","gists_url":"https://api.github.com/users/BaerMitUmlaut/gists{/gist_id}","starred_url":"https://api.github.com/users/BaerMitUmlaut/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/BaerMitUmlaut/subscriptions","organizations_url":"https://api.github.com/users/BaerMitUmlaut/orgs","repos_url":"https://api.github.com/users/BaerMitUmlaut/repos","events_url":"https://api.github.com/users/BaerMitUmlaut/events{/privacy}","received_events_url":"https://api.github.com/users/BaerMitUmlaut/received_events","type":"User","site_admin":false},"repo":{"id":44475831,"name":"CBA_A3","full_name":"BaerMitUmlaut/CBA_A3","owner":{"login":"BaerMitUmlaut","id":9693842,"avatar_url":"https://avatars.githubusercontent.com/u/9693842?v=3","gravatar_id":"","url":"https://api.github.com/users/BaerMitUmlaut","html_url":"https://github.com/BaerMitUmlaut","followers_url":"https://api.github.com/users/BaerMitUmlaut/followers","following_url":"https://api.github.com/users/BaerMitUmlaut/following{/other_user}","gists_url":"https://api.github.com/users/BaerMitUmlaut/gists{/gist_id}","starred_url":"https://api.github.com/users/BaerMitUmlaut/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/BaerMitUmlaut/subscriptions","organizations_url":"https://api.github.com/users/BaerMitUmlaut/orgs","repos_url":"https://api.github.com/users/BaerMitUmlaut/repos","events_url":"https://api.github.com/users/BaerMitUmlaut/events{/privacy}","received_events_url":"https://api.github.com/users/BaerMitUmlaut/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/BaerMitUmlaut/CBA_A3","description":"Community Base Addons for Arma 3","fork":true,"url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3","forks_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/forks","keys_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/keys{/key_id}","collaborators_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/teams","hooks_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/hooks","issue_events_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/issues/events{/number}","events_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/events","assignees_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/assignees{/user}","branches_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/branches{/branch}","tags_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/tags","blobs_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/git/refs{/sha}","trees_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/git/trees{/sha}","statuses_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/statuses/{sha}","languages_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/languages","stargazers_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/stargazers","contributors_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/contributors","subscribers_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/subscribers","subscription_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/subscription","commits_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/commits{/sha}","git_commits_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/git/commits{/sha}","comments_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/comments{/number}","issue_comment_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/issues/comments{/number}","contents_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/contents/{+path}","compare_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/compare/{base}...{head}","merges_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/merges","archive_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/downloads","issues_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/issues{/number}","pulls_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/pulls{/number}","milestones_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/milestones{/number}","notifications_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/labels{/name}","releases_url":"https://api.github.com/repos/BaerMitUmlaut/CBA_A3/releases{/id}","created_at":"2015-10-18T11:38:34Z","updated_at":"2015-10-18T11:38:36Z","pushed_at":"2015-10-20T09:36:49Z","git_url":"git://github.com/BaerMitUmlaut/CBA_A3.git","ssh_url":"git@github.com:BaerMitUmlaut/CBA_A3.git","clone_url":"https://github.com/BaerMitUmlaut/CBA_A3.git","svn_url":"https://github.com/BaerMitUmlaut/CBA_A3","homepage":"","size":9499,"stargazers_count":0,"watchers_count":0,"language":"SQF","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"CBATeam:master","ref":"master","sha":"d91297d00a879cf3548cf7ea8c2469d7a1d3b800","user":{"login":"CBATeam","id":12647545,"avatar_url":"https://avatars.githubusercontent.com/u/12647545?v=3","gravatar_id":"","url":"https://api.github.com/users/CBATeam","html_url":"https://github.com/CBATeam","followers_url":"https://api.github.com/users/CBATeam/followers","following_url":"https://api.github.com/users/CBATeam/following{/other_user}","gists_url":"https://api.github.com/users/CBATeam/gists{/gist_id}","starred_url":"https://api.github.com/users/CBATeam/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CBATeam/subscriptions","organizations_url":"https://api.github.com/users/CBATeam/orgs","repos_url":"https://api.github.com/users/CBATeam/repos","events_url":"https://api.github.com/users/CBATeam/events{/privacy}","received_events_url":"https://api.github.com/users/CBATeam/received_events","type":"Organization","site_admin":false},"repo":{"id":36454957,"name":"CBA_A3","full_name":"CBATeam/CBA_A3","owner":{"login":"CBATeam","id":12647545,"avatar_url":"https://avatars.githubusercontent.com/u/12647545?v=3","gravatar_id":"","url":"https://api.github.com/users/CBATeam","html_url":"https://github.com/CBATeam","followers_url":"https://api.github.com/users/CBATeam/followers","following_url":"https://api.github.com/users/CBATeam/following{/other_user}","gists_url":"https://api.github.com/users/CBATeam/gists{/gist_id}","starred_url":"https://api.github.com/users/CBATeam/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CBATeam/subscriptions","organizations_url":"https://api.github.com/users/CBATeam/orgs","repos_url":"https://api.github.com/users/CBATeam/repos","events_url":"https://api.github.com/users/CBATeam/events{/privacy}","received_events_url":"https://api.github.com/users/CBATeam/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/CBATeam/CBA_A3","description":"Community Base Addons for Arma 3","fork":false,"url":"https://api.github.com/repos/CBATeam/CBA_A3","forks_url":"https://api.github.com/repos/CBATeam/CBA_A3/forks","keys_url":"https://api.github.com/repos/CBATeam/CBA_A3/keys{/key_id}","collaborators_url":"https://api.github.com/repos/CBATeam/CBA_A3/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/CBATeam/CBA_A3/teams","hooks_url":"https://api.github.com/repos/CBATeam/CBA_A3/hooks","issue_events_url":"https://api.github.com/repos/CBATeam/CBA_A3/issues/events{/number}","events_url":"https://api.github.com/repos/CBATeam/CBA_A3/events","assignees_url":"https://api.github.com/repos/CBATeam/CBA_A3/assignees{/user}","branches_url":"https://api.github.com/repos/CBATeam/CBA_A3/branches{/branch}","tags_url":"https://api.github.com/repos/CBATeam/CBA_A3/tags","blobs_url":"https://api.github.com/repos/CBATeam/CBA_A3/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/CBATeam/CBA_A3/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/CBATeam/CBA_A3/git/refs{/sha}","trees_url":"https://api.github.com/repos/CBATeam/CBA_A3/git/trees{/sha}","statuses_url":"https://api.github.com/repos/CBATeam/CBA_A3/statuses/{sha}","languages_url":"https://api.github.com/repos/CBATeam/CBA_A3/languages","stargazers_url":"https://api.github.com/repos/CBATeam/CBA_A3/stargazers","contributors_url":"https://api.github.com/repos/CBATeam/CBA_A3/contributors","subscribers_url":"https://api.github.com/repos/CBATeam/CBA_A3/subscribers","subscription_url":"https://api.github.com/repos/CBATeam/CBA_A3/subscription","commits_url":"https://api.github.com/repos/CBATeam/CBA_A3/commits{/sha}","git_commits_url":"https://api.github.com/repos/CBATeam/CBA_A3/git/commits{/sha}","comments_url":"https://api.github.com/repos/CBATeam/CBA_A3/comments{/number}","issue_comment_url":"https://api.github.com/repos/CBATeam/CBA_A3/issues/comments{/number}","contents_url":"https://api.github.com/repos/CBATeam/CBA_A3/contents/{+path}","compare_url":"https://api.github.com/repos/CBATeam/CBA_A3/compare/{base}...{head}","merges_url":"https://api.github.com/repos/CBATeam/CBA_A3/merges","archive_url":"https://api.github.com/repos/CBATeam/CBA_A3/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/CBATeam/CBA_A3/downloads","issues_url":"https://api.github.com/repos/CBATeam/CBA_A3/issues{/number}","pulls_url":"https://api.github.com/repos/CBATeam/CBA_A3/pulls{/number}","milestones_url":"https://api.github.com/repos/CBATeam/CBA_A3/milestones{/number}","notifications_url":"https://api.github.com/repos/CBATeam/CBA_A3/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/CBATeam/CBA_A3/labels{/name}","releases_url":"https://api.github.com/repos/CBATeam/CBA_A3/releases{/id}","created_at":"2015-05-28T17:34:05Z","updated_at":"2015-10-12T17:05:02Z","pushed_at":"2015-10-20T09:36:50Z","git_url":"git://github.com/CBATeam/CBA_A3.git","ssh_url":"git@github.com:CBATeam/CBA_A3.git","clone_url":"https://github.com/CBATeam/CBA_A3.git","svn_url":"https://github.com/CBATeam/CBA_A3","homepage":"","size":9499,"stargazers_count":39,"watchers_count":39,"language":"SQF","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":24,"mirror_url":null,"open_issues_count":19,"forks":24,"open_issues":19,"watchers":39,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/CBATeam/CBA_A3/pulls/185"},"html":{"href":"https://github.com/CBATeam/CBA_A3/pull/185"},"issue":{"href":"https://api.github.com/repos/CBATeam/CBA_A3/issues/185"},"comments":{"href":"https://api.github.com/repos/CBATeam/CBA_A3/issues/185/comments"},"review_comments":{"href":"https://api.github.com/repos/CBATeam/CBA_A3/pulls/185/comments"},"review_comment":{"href":"https://api.github.com/repos/CBATeam/CBA_A3/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/CBATeam/CBA_A3/pulls/185/commits"},"statuses":{"href":"https://api.github.com/repos/CBATeam/CBA_A3/statuses/2210b67a2676e76abe65f722acc46341bf0de53b"}}}}