{"action":"opened","issue":{"url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/issues/13915","labels_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/issues/13915/labels{/name}","comments_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/issues/13915/comments","events_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/issues/13915/events","html_url":"https://github.com/CleverRaven/Cataclysm-DDA/issues/13915","id":115570785,"number":13915,"title":"Adding quantity parameter to non-ammo items","user":{"login":"Nandorianen","id":7211122,"avatar_url":"https://avatars.githubusercontent.com/u/7211122?v=3","gravatar_id":"","url":"https://api.github.com/users/Nandorianen","html_url":"https://github.com/Nandorianen","followers_url":"https://api.github.com/users/Nandorianen/followers","following_url":"https://api.github.com/users/Nandorianen/following{/other_user}","gists_url":"https://api.github.com/users/Nandorianen/gists{/gist_id}","starred_url":"https://api.github.com/users/Nandorianen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Nandorianen/subscriptions","organizations_url":"https://api.github.com/users/Nandorianen/orgs","repos_url":"https://api.github.com/users/Nandorianen/repos","events_url":"https://api.github.com/users/Nandorianen/events{/privacy}","received_events_url":"https://api.github.com/users/Nandorianen/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-11-06T19:25:55Z","updated_at":"2015-11-06T19:25:55Z","closed_at":null,"body":"Hoarding items seems to be a very big source of lag. When you have those 500 scrap metal pieces and 1000 rags everything is slow. Using inventory is slow, crafting menus are slow, etc.\r\nMeanwhile there are ammo-type items that handle this a little better. You have a thread item with stack size set to 1000, not 1000 separate units of thread. And yet you can separate it however you like.\r\n\r\nSo why not make normal items behave closer to their ammo counterparts code-wise? When an item is placed / moved somewhere, be it a tile or an inventory, check if the same item is there already and if it can be stacked. If there is, increase \"quantity\" by 1. A check for stackable items is already there to draw items as stacked in AIM. It already checks for freshness and damage.\r\n\r\nMy limited coding knowledge tells me that it should be pretty easy to implement for someone who actually knows how to code. I do not foresee any real problems with save compatibility either. This should make mid-late game much more smooth for hoarders, reduce save bloat and make developer's private life better by 20% by improving morale and karma."}}