{"action":"created","issue":{"url":"https://api.github.com/repos/supertuxkart/stk-code/issues/3143","repository_url":"https://api.github.com/repos/supertuxkart/stk-code","labels_url":"https://api.github.com/repos/supertuxkart/stk-code/issues/3143/labels{/name}","comments_url":"https://api.github.com/repos/supertuxkart/stk-code/issues/3143/comments","events_url":"https://api.github.com/repos/supertuxkart/stk-code/issues/3143/events","html_url":"https://github.com/supertuxkart/stk-code/pull/3143","id":305745276,"number":3143,"title":"AI item handling improvements","user":{"login":"Alayan-stk-2","id":25536748,"avatar_url":"https://avatars2.githubusercontent.com/u/25536748?v=4","gravatar_id":"","url":"https://api.github.com/users/Alayan-stk-2","html_url":"https://github.com/Alayan-stk-2","followers_url":"https://api.github.com/users/Alayan-stk-2/followers","following_url":"https://api.github.com/users/Alayan-stk-2/following{/other_user}","gists_url":"https://api.github.com/users/Alayan-stk-2/gists{/gist_id}","starred_url":"https://api.github.com/users/Alayan-stk-2/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Alayan-stk-2/subscriptions","organizations_url":"https://api.github.com/users/Alayan-stk-2/orgs","repos_url":"https://api.github.com/users/Alayan-stk-2/repos","events_url":"https://api.github.com/users/Alayan-stk-2/events{/privacy}","received_events_url":"https://api.github.com/users/Alayan-stk-2/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":7,"created_at":"2018-03-15T22:46:23Z","updated_at":"2018-03-19T02:38:06Z","closed_at":null,"author_association":"CONTRIBUTOR","pull_request":{"url":"https://api.github.com/repos/supertuxkart/stk-code/pulls/3143","html_url":"https://github.com/supertuxkart/stk-code/pull/3143","diff_url":"https://github.com/supertuxkart/stk-code/pull/3143.diff","patch_url":"https://github.com/supertuxkart/stk-code/pull/3143.patch"},"body":"A general summary of the changes in the patch : \r\n\r\n- As discussed on the IRC, replace the random item usage bool by an int for several modes (from 1 to 5 plus 0 for \"do nothing\"), to make each difficulty have its own item AI (with some shared parts).\r\n- Add a boost_ai characteristic for karts ; allowing some karts to have a different AI in the same race. This is a preparation for a future fix to #2777 : make GP results less random and more challenging.\r\n- Several AI improvements in bubbleshield, swatter and throwed items usage. Main changes summarized at the end.\r\n- Collecting a different type of item resets the time of last use to remove unnecessary waiting.\r\n- Different tiers of item usage ability set in place for some items\r\n- Tiers of nitro usage revised\r\n- Vast improvements of nitro usage\r\n- HandleItems call placed inside HandleSteering to allow making it aware of items nearby\r\n- Fixes #3139 : the AI won't try to pass back a bomb to the kart it got it from.\r\n- Adds a small engine boost to nitro for balance reasons (making it useful at speeds other than max speed)\r\n\r\nI've compiled and tested the patch.\r\n\r\n<del>The shield activation near boxes/bad items needs improvement, but the overall behavior remains more effective.</del> Fixed with latest commit. There should be few false positives.\r\n\r\nThe items who have not yet been updated for the new system will be used like before AI-wise. So there should be no regression.\r\n\r\nMain AI improvements : \r\n- Throwed items are used even if the shield is on if restricted mode is disabled ; \r\n- Shield and swatter are used to remove bad attachments ; \r\n- Shield is used before hitting a bad item or an item box\r\n- The Switch is not used blindly anymore. The best AI now evaluates close items to make a decision.\r\n- Nitro is used by bursts by checking on the remaining time of nitro effect\r\n- Nitro is used when close to max speed or slow (to make use of the max speed or of the acceleration bonus), not when slightly below max speed (avoiding the AI using nitro when catched with a plunger)\r\n- Several minor improvements"},"comment":{"url":"https://api.github.com/repos/supertuxkart/stk-code/issues/comments/374084826","html_url":"https://github.com/supertuxkart/stk-code/pull/3143#issuecomment-374084826","issue_url":"https://api.github.com/repos/supertuxkart/stk-code/issues/3143","id":374084826,"user":{"login":"Alayan-stk-2","id":25536748,"avatar_url":"https://avatars2.githubusercontent.com/u/25536748?v=4","gravatar_id":"","url":"https://api.github.com/users/Alayan-stk-2","html_url":"https://github.com/Alayan-stk-2","followers_url":"https://api.github.com/users/Alayan-stk-2/followers","following_url":"https://api.github.com/users/Alayan-stk-2/following{/other_user}","gists_url":"https://api.github.com/users/Alayan-stk-2/gists{/gist_id}","starred_url":"https://api.github.com/users/Alayan-stk-2/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Alayan-stk-2/subscriptions","organizations_url":"https://api.github.com/users/Alayan-stk-2/orgs","repos_url":"https://api.github.com/users/Alayan-stk-2/repos","events_url":"https://api.github.com/users/Alayan-stk-2/events{/privacy}","received_events_url":"https://api.github.com/users/Alayan-stk-2/received_events","type":"User","site_admin":false},"created_at":"2018-03-19T02:38:06Z","updated_at":"2018-03-19T02:38:06Z","author_association":"CONTRIBUTOR","body":"The latest changes, aside from fixing some errors, make the AI nitro code depend more on the kart-properties linked to nitro. It should work better across the different types of karts (light/medium/heavy) and be more resilient if the config files are tweaked.\r\n\r\nFrom my tests, all the nitro features seem to finally work as intended. I don't expect to do more changes to it."}}
{"actor":{"display_login":"Alayan-stk-2"}}