{"action":"created","issue":{"url":"https://api.github.com/repos/vbawol/DayZ-Epoch/issues/1567","labels_url":"https://api.github.com/repos/vbawol/DayZ-Epoch/issues/1567/labels{/name}","comments_url":"https://api.github.com/repos/vbawol/DayZ-Epoch/issues/1567/comments","events_url":"https://api.github.com/repos/vbawol/DayZ-Epoch/issues/1567/events","html_url":"https://github.com/vbawol/DayZ-Epoch/pull/1567","id":42682863,"number":1567,"title":"If Crafting Item is SledgeHammer","user":{"login":"Namindu","id":5004971,"avatar_url":"https://avatars.githubusercontent.com/u/5004971?v=3","gravatar_id":"","url":"https://api.github.com/users/Namindu","html_url":"https://github.com/Namindu","followers_url":"https://api.github.com/users/Namindu/followers","following_url":"https://api.github.com/users/Namindu/following{/other_user}","gists_url":"https://api.github.com/users/Namindu/gists{/gist_id}","starred_url":"https://api.github.com/users/Namindu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Namindu/subscriptions","organizations_url":"https://api.github.com/users/Namindu/orgs","repos_url":"https://api.github.com/users/Namindu/repos","events_url":"https://api.github.com/users/Namindu/events{/privacy}","received_events_url":"https://api.github.com/users/Namindu/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/vbawol/DayZ-Epoch/labels/prio:low","name":"prio:low","color":"207de5"},{"url":"https://api.github.com/repos/vbawol/DayZ-Epoch/labels/type:bug","name":"type:bug","color":"eb6420"},{"url":"https://api.github.com/repos/vbawol/DayZ-Epoch/labels/type:enhancement","name":"type:enhancement","color":"006b75"}],"state":"open","locked":false,"assignee":{"login":"Windmolders","id":3929563,"avatar_url":"https://avatars.githubusercontent.com/u/3929563?v=3","gravatar_id":"","url":"https://api.github.com/users/Windmolders","html_url":"https://github.com/Windmolders","followers_url":"https://api.github.com/users/Windmolders/followers","following_url":"https://api.github.com/users/Windmolders/following{/other_user}","gists_url":"https://api.github.com/users/Windmolders/gists{/gist_id}","starred_url":"https://api.github.com/users/Windmolders/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Windmolders/subscriptions","organizations_url":"https://api.github.com/users/Windmolders/orgs","repos_url":"https://api.github.com/users/Windmolders/repos","events_url":"https://api.github.com/users/Windmolders/events{/privacy}","received_events_url":"https://api.github.com/users/Windmolders/received_events","type":"User","site_admin":false},"milestone":null,"comments":6,"created_at":"2014-09-13T00:41:48Z","updated_at":"2015-07-22T21:02:23Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/vbawol/DayZ-Epoch/pulls/1567","html_url":"https://github.com/vbawol/DayZ-Epoch/pull/1567","diff_url":"https://github.com/vbawol/DayZ-Epoch/pull/1567.diff","patch_url":"https://github.com/vbawol/DayZ-Epoch/pull/1567.patch"},"body":"If the Item being crafted is a sledgehammer then it will check to see if its in the inventory, If Yes, then it will add it to the players bag. If No, then it will add it to their main gear.\r\n\r\nNote:\r\n1) I have not Tested it Yet\r\n2) This currently dose not check to see if player has a bag or not.\r\n3) Will need to add the Text of the \"cutText\" to the stringtables."},"comment":{"url":"https://api.github.com/repos/vbawol/DayZ-Epoch/issues/comments/123862451","html_url":"https://github.com/vbawol/DayZ-Epoch/pull/1567#issuecomment-123862451","issue_url":"https://api.github.com/repos/vbawol/DayZ-Epoch/issues/1567","id":123862451,"user":{"login":"ebaydayz","id":7761693,"avatar_url":"https://avatars.githubusercontent.com/u/7761693?v=3","gravatar_id":"","url":"https://api.github.com/users/ebaydayz","html_url":"https://github.com/ebaydayz","followers_url":"https://api.github.com/users/ebaydayz/followers","following_url":"https://api.github.com/users/ebaydayz/following{/other_user}","gists_url":"https://api.github.com/users/ebaydayz/gists{/gist_id}","starred_url":"https://api.github.com/users/ebaydayz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ebaydayz/subscriptions","organizations_url":"https://api.github.com/users/ebaydayz/orgs","repos_url":"https://api.github.com/users/ebaydayz/repos","events_url":"https://api.github.com/users/ebaydayz/events{/privacy}","received_events_url":"https://api.github.com/users/ebaydayz/received_events","type":"User","site_admin":false},"created_at":"2015-07-22T21:02:23Z","updated_at":"2015-07-22T21:02:23Z","body":"I opened a pull request to add it to stringtable.xml\r\n\r\nHere it is with the localized strings:\r\n\r\n<pre><code>if ((_x == \"ItemSledge\") && {_x in items player}) then {\r\n\t_bag = unitBackpack player;\r\n\tif (!isNull _bag) then {\r\n\t\tcutText [format[(localize \"str_epoch_player_313\"),_x], \"PLAIN\"];\r\n\t\t_bag addWeaponCargoGlobal [_x,1];\r\n\t} else {\r\n\t\tcutText [format[(localize \"str_epoch_player_314\"),_x], \"PLAIN\"];\r\n\t\t_object = createVehicle [\"WeaponHolder\",position player,[],0,\"CAN_COLLIDE\"];\r\n\t\t_object setVariable [\"permaLoot\",true];\r\n\t\t_object addWeaponCargoGlobal [_x,1];\r\n\t};\r\n} else {\r\n\tplayer addWeapon _x;\r\n};</code></pre>"}}