{"action":"opened","issue":{"url":"https://api.github.com/repos/X2CommunityCore/X2WOTCCommunityHighlander/issues/93","repository_url":"https://api.github.com/repos/X2CommunityCore/X2WOTCCommunityHighlander","labels_url":"https://api.github.com/repos/X2CommunityCore/X2WOTCCommunityHighlander/issues/93/labels{/name}","comments_url":"https://api.github.com/repos/X2CommunityCore/X2WOTCCommunityHighlander/issues/93/comments","events_url":"https://api.github.com/repos/X2CommunityCore/X2WOTCCommunityHighlander/issues/93/events","html_url":"https://github.com/X2CommunityCore/X2WOTCCommunityHighlander/issues/93","id":267928543,"number":93,"title":"Streamline NumUpgradeSlots for X2ItemTemplates","user":{"login":"Musashi1584","id":30629257,"avatar_url":"https://avatars0.githubusercontent.com/u/30629257?v=4","gravatar_id":"","url":"https://api.github.com/users/Musashi1584","html_url":"https://github.com/Musashi1584","followers_url":"https://api.github.com/users/Musashi1584/followers","following_url":"https://api.github.com/users/Musashi1584/following{/other_user}","gists_url":"https://api.github.com/users/Musashi1584/gists{/gist_id}","starred_url":"https://api.github.com/users/Musashi1584/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Musashi1584/subscriptions","organizations_url":"https://api.github.com/users/Musashi1584/orgs","repos_url":"https://api.github.com/users/Musashi1584/repos","events_url":"https://api.github.com/users/Musashi1584/events{/privacy}","received_events_url":"https://api.github.com/users/Musashi1584/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2017-10-24T07:41:22Z","updated_at":"2017-10-24T07:41:22Z","closed_at":null,"author_association":"CONTRIBUTOR","body":"To extend upgrade slots to items other then weapons and make them accessible to modders\r\nadd `GetNumWeaponUpgradeSlots()` to `X2ItemTemplate`\r\nand use it in all places that currently access `X2WeaponTemplate(Template).NumUpgradeSlots`.\r\n\r\n`GetNumWeaponUpgradeSlots` returns  `NumUpgradeSlots` if set (in case of `X2WeaponTemplate`) or reads the value from a helper config array.\r\n\r\nAlso add a function `GetNumWeaponUpgradeSlots` in `XComGameState_Item` that considers breakthroughs, and adds a way for mods to modify the output.\r\n\r\nPitfalls: Lookout for code that relies on weapons be the only items that use attachements."}}
{"actor":{"display_login":"Musashi1584"}}