{"action":"created","comment":{"url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/pulls/comments/63291162","id":63291162,"diff_hunk":"@@ -708,8 +710,9 @@ void draw_points( WINDOW *w, points_left &points, int netPointCost )\n {\n     mvwprintz( w, 3, 2, c_black, clear_str );\n     std::string points_msg = points.to_string();\n-    int pMsg_length = utf8_width( points_msg );\n-    mvwprintz( w, 3, 2, c_ltgray, points_msg.c_str() );\n+    int pMsg_length = utf8_width( points_msg, true );\n+    nc_color color;","path":"src/newcharacter.cpp","position":28,"original_position":28,"commit_id":"eb7f14738be9700dc2f5956229cfb2e0f93e1080","original_commit_id":"eb7f14738be9700dc2f5956229cfb2e0f93e1080","user":{"login":"BevapDin","id":5095435,"avatar_url":"https://avatars.githubusercontent.com/u/5095435?v=3","gravatar_id":"","url":"https://api.github.com/users/BevapDin","html_url":"https://github.com/BevapDin","followers_url":"https://api.github.com/users/BevapDin/followers","following_url":"https://api.github.com/users/BevapDin/following{/other_user}","gists_url":"https://api.github.com/users/BevapDin/gists{/gist_id}","starred_url":"https://api.github.com/users/BevapDin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/BevapDin/subscriptions","organizations_url":"https://api.github.com/users/BevapDin/orgs","repos_url":"https://api.github.com/users/BevapDin/repos","events_url":"https://api.github.com/users/BevapDin/events{/privacy}","received_events_url":"https://api.github.com/users/BevapDin/received_events","type":"User","site_admin":false},"body":"This needs to be initialized, probably just to `c_ltgray` and than you can use it as second color parameter in the function call below (as in `print_colored_text( ..., color, color, points_msg )`).","created_at":"2016-05-15T12:51:01Z","updated_at":"2016-05-15T12:51:01Z","html_url":"https://github.com/CleverRaven/Cataclysm-DDA/pull/16572#discussion_r63291162","pull_request_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/pulls/16572","_links":{"self":{"href":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/pulls/comments/63291162"},"html":{"href":"https://github.com/CleverRaven/Cataclysm-DDA/pull/16572#discussion_r63291162"},"pull_request":{"href":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/pulls/16572"}}},"pull_request":{"url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/pulls/16572","id":69256041,"html_url":"https://github.com/CleverRaven/Cataclysm-DDA/pull/16572","diff_url":"https://github.com/CleverRaven/Cataclysm-DDA/pull/16572.diff","patch_url":"https://github.com/CleverRaven/Cataclysm-DDA/pull/16572.patch","issue_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/issues/16572","number":16572,"state":"open","locked":false,"title":"Multi pool errors messages","user":{"login":"Shoes01","id":3358624,"avatar_url":"https://avatars.githubusercontent.com/u/3358624?v=3","gravatar_id":"","url":"https://api.github.com/users/Shoes01","html_url":"https://github.com/Shoes01","followers_url":"https://api.github.com/users/Shoes01/followers","following_url":"https://api.github.com/users/Shoes01/following{/other_user}","gists_url":"https://api.github.com/users/Shoes01/gists{/gist_id}","starred_url":"https://api.github.com/users/Shoes01/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Shoes01/subscriptions","organizations_url":"https://api.github.com/users/Shoes01/orgs","repos_url":"https://api.github.com/users/Shoes01/repos","events_url":"https://api.github.com/users/Shoes01/events{/privacy}","received_events_url":"https://api.github.com/users/Shoes01/received_events","type":"User","site_admin":false},"body":"This is in response to issue #15918. \r\n\r\nThis PR attempts to add error messages when allocating points incorrectly using the Multiple Pool option. \r\n\r\nThere are some quirks, where being at -4+2+2=0 or -2+0+2=0 will complain about trait points, while -2+2+0=0 will (rightfully) complain about stats. However, this is better than nothing! And to make the error logs more accurate might require more delicate code than what I added.\r\n\r\nI looked at adding coloring schemes to indicate errors; for example, if a user allocated -2+0+2=0, the -2 would be red. Or if the user allocated 0-2+2=0, but the 0 and the -2 would be red. This could not be done easily because the whole equation is coded as one single string, and thus one single color. If coloring is something that would be a good feature, add it to the issue mentioned above and I might get to it another day.","created_at":"2016-05-07T23:32:27Z","updated_at":"2016-05-15T12:51:01Z","closed_at":null,"merged_at":null,"merge_commit_sha":"504a6ae3029e170571b1478a4a2ef6f6bcc2a8ac","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/pulls/16572/commits","review_comments_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/pulls/16572/comments","review_comment_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/pulls/comments{/number}","comments_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/issues/16572/comments","statuses_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/statuses/eb7f14738be9700dc2f5956229cfb2e0f93e1080","head":{"label":"Shoes01:multi-pool-errors","ref":"multi-pool-errors","sha":"eb7f14738be9700dc2f5956229cfb2e0f93e1080","user":{"login":"Shoes01","id":3358624,"avatar_url":"https://avatars.githubusercontent.com/u/3358624?v=3","gravatar_id":"","url":"https://api.github.com/users/Shoes01","html_url":"https://github.com/Shoes01","followers_url":"https://api.github.com/users/Shoes01/followers","following_url":"https://api.github.com/users/Shoes01/following{/other_user}","gists_url":"https://api.github.com/users/Shoes01/gists{/gist_id}","starred_url":"https://api.github.com/users/Shoes01/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Shoes01/subscriptions","organizations_url":"https://api.github.com/users/Shoes01/orgs","repos_url":"https://api.github.com/users/Shoes01/repos","events_url":"https://api.github.com/users/Shoes01/events{/privacy}","received_events_url":"https://api.github.com/users/Shoes01/received_events","type":"User","site_admin":false},"repo":{"id":8102755,"name":"Cataclysm-DDA","full_name":"Shoes01/Cataclysm-DDA","owner":{"login":"Shoes01","id":3358624,"avatar_url":"https://avatars.githubusercontent.com/u/3358624?v=3","gravatar_id":"","url":"https://api.github.com/users/Shoes01","html_url":"https://github.com/Shoes01","followers_url":"https://api.github.com/users/Shoes01/followers","following_url":"https://api.github.com/users/Shoes01/following{/other_user}","gists_url":"https://api.github.com/users/Shoes01/gists{/gist_id}","starred_url":"https://api.github.com/users/Shoes01/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Shoes01/subscriptions","organizations_url":"https://api.github.com/users/Shoes01/orgs","repos_url":"https://api.github.com/users/Shoes01/repos","events_url":"https://api.github.com/users/Shoes01/events{/privacy}","received_events_url":"https://api.github.com/users/Shoes01/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Shoes01/Cataclysm-DDA","description":"Cataclysm - Dark Days Ahead. The unofficial continuation projects for Whales' Cataclysm Roguelike","fork":true,"url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA","forks_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/forks","keys_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/teams","hooks_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/hooks","issue_events_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/issues/events{/number}","events_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/events","assignees_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/assignees{/user}","branches_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/branches{/branch}","tags_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/tags","blobs_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/git/refs{/sha}","trees_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/statuses/{sha}","languages_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/languages","stargazers_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/stargazers","contributors_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/contributors","subscribers_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/subscribers","subscription_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/subscription","commits_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/commits{/sha}","git_commits_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/git/commits{/sha}","comments_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/comments{/number}","issue_comment_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/issues/comments{/number}","contents_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/contents/{+path}","compare_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/merges","archive_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/downloads","issues_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/issues{/number}","pulls_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/pulls{/number}","milestones_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/milestones{/number}","notifications_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/labels{/name}","releases_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/releases{/id}","deployments_url":"https://api.github.com/repos/Shoes01/Cataclysm-DDA/deployments","created_at":"2013-02-08T22:34:40Z","updated_at":"2015-01-27T23:31:38Z","pushed_at":"2016-05-14T15:55:13Z","git_url":"git://github.com/Shoes01/Cataclysm-DDA.git","ssh_url":"git@github.com:Shoes01/Cataclysm-DDA.git","clone_url":"https://github.com/Shoes01/Cataclysm-DDA.git","svn_url":"https://github.com/Shoes01/Cataclysm-DDA","homepage":"http://www.cataclysm.glyphgryph.com/","size":761625,"stargazers_count":0,"watchers_count":0,"language":"C++","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"CleverRaven:master","ref":"master","sha":"49b18d8afb3628ced0659eb08317e010abe42e3f","user":{"login":"CleverRaven","id":4367009,"avatar_url":"https://avatars.githubusercontent.com/u/4367009?v=3","gravatar_id":"","url":"https://api.github.com/users/CleverRaven","html_url":"https://github.com/CleverRaven","followers_url":"https://api.github.com/users/CleverRaven/followers","following_url":"https://api.github.com/users/CleverRaven/following{/other_user}","gists_url":"https://api.github.com/users/CleverRaven/gists{/gist_id}","starred_url":"https://api.github.com/users/CleverRaven/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CleverRaven/subscriptions","organizations_url":"https://api.github.com/users/CleverRaven/orgs","repos_url":"https://api.github.com/users/CleverRaven/repos","events_url":"https://api.github.com/users/CleverRaven/events{/privacy}","received_events_url":"https://api.github.com/users/CleverRaven/received_events","type":"Organization","site_admin":false},"repo":{"id":5973855,"name":"Cataclysm-DDA","full_name":"CleverRaven/Cataclysm-DDA","owner":{"login":"CleverRaven","id":4367009,"avatar_url":"https://avatars.githubusercontent.com/u/4367009?v=3","gravatar_id":"","url":"https://api.github.com/users/CleverRaven","html_url":"https://github.com/CleverRaven","followers_url":"https://api.github.com/users/CleverRaven/followers","following_url":"https://api.github.com/users/CleverRaven/following{/other_user}","gists_url":"https://api.github.com/users/CleverRaven/gists{/gist_id}","starred_url":"https://api.github.com/users/CleverRaven/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CleverRaven/subscriptions","organizations_url":"https://api.github.com/users/CleverRaven/orgs","repos_url":"https://api.github.com/users/CleverRaven/repos","events_url":"https://api.github.com/users/CleverRaven/events{/privacy}","received_events_url":"https://api.github.com/users/CleverRaven/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/CleverRaven/Cataclysm-DDA","description":"Cataclysm - Dark Days Ahead. A fork/variant of Cataclysm Roguelike by Whales.","fork":false,"url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA","forks_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/forks","keys_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/keys{/key_id}","collaborators_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/teams","hooks_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/hooks","issue_events_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/issues/events{/number}","events_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/events","assignees_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/assignees{/user}","branches_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/branches{/branch}","tags_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/tags","blobs_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/git/refs{/sha}","trees_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/git/trees{/sha}","statuses_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/statuses/{sha}","languages_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/languages","stargazers_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/stargazers","contributors_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/contributors","subscribers_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/subscribers","subscription_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/subscription","commits_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/commits{/sha}","git_commits_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/git/commits{/sha}","comments_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/comments{/number}","issue_comment_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/issues/comments{/number}","contents_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/contents/{+path}","compare_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/compare/{base}...{head}","merges_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/merges","archive_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/downloads","issues_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/issues{/number}","pulls_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/pulls{/number}","milestones_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/milestones{/number}","notifications_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/labels{/name}","releases_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/releases{/id}","deployments_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/deployments","created_at":"2012-09-26T22:57:43Z","updated_at":"2016-05-13T20:55:37Z","pushed_at":"2016-05-15T12:20:13Z","git_url":"git://github.com/CleverRaven/Cataclysm-DDA.git","ssh_url":"git@github.com:CleverRaven/Cataclysm-DDA.git","clone_url":"https://github.com/CleverRaven/Cataclysm-DDA.git","svn_url":"https://github.com/CleverRaven/Cataclysm-DDA","homepage":"http://en.cataclysmdda.com/","size":1028814,"stargazers_count":949,"watchers_count":949,"language":"C++","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":876,"mirror_url":null,"open_issues_count":1203,"forks":876,"open_issues":1203,"watchers":949,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/pulls/16572"},"html":{"href":"https://github.com/CleverRaven/Cataclysm-DDA/pull/16572"},"issue":{"href":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/issues/16572"},"comments":{"href":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/issues/16572/comments"},"review_comments":{"href":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/pulls/16572/comments"},"review_comment":{"href":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/pulls/16572/commits"},"statuses":{"href":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/statuses/eb7f14738be9700dc2f5956229cfb2e0f93e1080"}}}}