{"action":"closed","issue":{"url":"https://api.github.com/repos/leMaik/RpgPlus/issues/20","labels_url":"https://api.github.com/repos/leMaik/RpgPlus/issues/20/labels{/name}","comments_url":"https://api.github.com/repos/leMaik/RpgPlus/issues/20/comments","events_url":"https://api.github.com/repos/leMaik/RpgPlus/issues/20/events","html_url":"https://github.com/leMaik/RpgPlus/issues/20","id":114363345,"number":20,"title":"Event system for entities","user":{"login":"leMaik","id":5544859,"avatar_url":"https://avatars.githubusercontent.com/u/5544859?v=3","gravatar_id":"","url":"https://api.github.com/users/leMaik","html_url":"https://github.com/leMaik","followers_url":"https://api.github.com/users/leMaik/followers","following_url":"https://api.github.com/users/leMaik/following{/other_user}","gists_url":"https://api.github.com/users/leMaik/gists{/gist_id}","starred_url":"https://api.github.com/users/leMaik/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/leMaik/subscriptions","organizations_url":"https://api.github.com/users/leMaik/orgs","repos_url":"https://api.github.com/users/leMaik/repos","events_url":"https://api.github.com/users/leMaik/events{/privacy}","received_events_url":"https://api.github.com/users/leMaik/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/leMaik/RpgPlus/labels/enhancement","name":"enhancement","color":"84b6eb"},{"url":"https://api.github.com/repos/leMaik/RpgPlus/labels/scripting","name":"scripting","color":"0052cc"}],"state":"closed","locked":false,"assignee":null,"milestone":{"url":"https://api.github.com/repos/leMaik/RpgPlus/milestones/1","html_url":"https://github.com/leMaik/RpgPlus/milestones/MS1:%20Basic%20functionality%20and%20API","labels_url":"https://api.github.com/repos/leMaik/RpgPlus/milestones/1/labels","id":1341239,"number":1,"title":"MS1: Basic functionality and API","description":"Some basic functionality is done. Scripting a simple RPG should already be possible, but more complicated (and more awesome) features are still missing.\r\nDialogs, shopping and mob interaction is implemented.","creator":{"login":"leMaik","id":5544859,"avatar_url":"https://avatars.githubusercontent.com/u/5544859?v=3","gravatar_id":"","url":"https://api.github.com/users/leMaik","html_url":"https://github.com/leMaik","followers_url":"https://api.github.com/users/leMaik/followers","following_url":"https://api.github.com/users/leMaik/following{/other_user}","gists_url":"https://api.github.com/users/leMaik/gists{/gist_id}","starred_url":"https://api.github.com/users/leMaik/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/leMaik/subscriptions","organizations_url":"https://api.github.com/users/leMaik/orgs","repos_url":"https://api.github.com/users/leMaik/repos","events_url":"https://api.github.com/users/leMaik/events{/privacy}","received_events_url":"https://api.github.com/users/leMaik/received_events","type":"User","site_admin":false},"open_issues":0,"closed_issues":12,"state":"open","created_at":"2015-10-06T19:57:34Z","updated_at":"2015-11-01T14:09:09Z","due_on":"2015-10-30T23:00:00Z","closed_at":null},"comments":0,"created_at":"2015-10-30T22:01:08Z","updated_at":"2015-11-01T14:09:09Z","closed_at":"2015-11-01T14:09:09Z","body":"The lua wrappers for entities should support events, like this:\r\n\r\n```lua\r\nvillager = rpgplus.spawn(\"villager\", {x=0,y=0,z=0,world=\"world\"})\r\nvillager:on(\"interact\", function(event)\r\n   villager:tell(event:getPlayer(), \"Hello!\")\r\nend)"}}