# Engine Error - Attempt to index a nil value (goblin boss sheep)

**URL:** <https://discourse.stonehearth.net/t/engine-error-attempt-to-index-a-nil-value-goblin-boss-sheep/24841>\
**Category:** Resolved Reports\
**Tags:** resolved\
**Created:** [August 22, 2016, 8:12pm UTC](https://discourse.stonehearth.net/t/engine-error-attempt-to-index-a-nil-value-goblin-boss-sheep/24841 "2016-08-22T20:12:40Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Dreamchime](https://sea2.discourse-cdn.com/flex022/user_avatar/discourse.stonehearth.net/dreamchime/32/52378_2.png) [@Dreamchime](https://discourse.stonehearth.net/u/Dreamchime)\
**Post date:** [August 22, 2016, 8:12pm UTC](https://discourse.stonehearth.net/t/engine-error-attempt-to-index-a-nil-value-goblin-boss-sheep/24841/1 "2016-08-22T20:12:40Z")

</div>

This popped up after killing what I think was a “boss” goblin. It doesn’t seem like it actually caused any problems in-game, however, at least not yet.

release-610 (x64)  
radiant/modules/entities.lua:304: attempt to index a nil value  
stack traceback:  
radiant/modules/common.lua:237: in function 'report\_traceback’  
radiant/modules/common.lua:248: in function \<radiant/modules/common.lua:242\>  
radiant/modules/entities.lua:304: in function ‘set\_player\_id’  
…cs/trigger/raidcamp/encounters/boss\_death\_script.lua:13: in function ‘start’  
…ter/controllers/encounters/dialog\_tree\_encounter.lua:38: in function ‘start’  
…ervices/server/game\_master/controllers/encounter.lua:115: in function ‘start’  
…arth/services/server/game\_master/controllers/arc.lua:373: in function ‘\_start\_encounter’  
…arth/services/server/game\_master/controllers/arc.lua:349: in function ‘\_trigger\_edge’  
…arth/services/server/game\_master/controllers/arc.lua:282: in function ‘\_trigger\_out\_edge’  
…arth/services/server/game\_master/controllers/arc.lua:256: in function ‘trigger\_next\_encounter’  
…/controllers/encounters/wait\_for\_event\_encounter.lua:98: in function ‘\_on\_event\_triggered’  
…  
radiant/controllers/time\_tracker\_controller.lua:82: in function ‘set\_now’  
…hearth/services/server/calendar/calendar\_service.lua:379: in function ‘\_on\_event\_loop’  
…hearth/services/server/calendar/calendar\_service.lua:37: in function 'instance’  
radiant/modules/events.lua:227: in function \<radiant/modules/events.lua:221\>  
[C]: in function 'xpcall’  
radiant/modules/common.lua:257: in function 'xpcall’  
radiant/modules/events.lua:221: in function 'trigger’  
radiant/modules/events.lua:290: in function '\_trigger\_gameloop’  
radiant/modules/events.lua:338: in function '\_update’  
radiant/server.lua:62: in function \<radiant/server.lua:58\>

---

<div class="post-metadata">

**Author:** ![Relyss](https://sea2.discourse-cdn.com/flex022/user_avatar/discourse.stonehearth.net/relyss/32/41785_2.png) [@Relyss](https://discourse.stonehearth.net/u/Relyss)\
**Post date:** [August 27, 2016, 9:03am UTC](https://discourse.stonehearth.net/t/engine-error-attempt-to-index-a-nil-value-goblin-boss-sheep/24841/2 "2016-08-27T09:03:51Z")

</div>

Welcome to the forum, @Dreamchime 😃

Thanks for reporting!  
I believe this bug is fixed on A18 d3107. If you see it again after A18 stable is released, don’t hesitate to tell us.

---

<div class="post-metadata">

**Author:** ![Hreef](https://avatars.discourse-cdn.com/v4/letter/h/77aa72/32.png) [@Hreef](https://discourse.stonehearth.net/u/Hreef)\
**Post date:** [August 24, 2016, 11:02am UTC](https://discourse.stonehearth.net/t/engine-error-attempt-to-index-a-nil-value-goblin-boss-sheep/24841/3 "2016-08-24T11:02:09Z")

</div>

Hi,  
so probably it is not the same problem but as this error is also related to the goblin chieftain I thought it might still be connected.

This is the Error Log:  
release-610 (x64)radiant/modules/entities.lua:304: attempt to index a nil valuestack traceback:  
radiant/modules/common.lua:237: in function 'report\_traceback’  
radiant/modules/common.lua:248: in function \<radiant/modules/common.lua:242\>  
radiant/modules/entities.lua:304: in function ‘set\_player\_id’  
…cs/trigger/raidcamp/encounters/boss\_death\_script.lua:13: in function ‘start’  
…ter/controllers/encounters/dialog\_tree\_encounter.lua:38: in function ‘start’  
…ervices/server/game\_master/controllers/encounter.lua:115: in function ‘start’  
…arth/services/server/game\_master/controllers/arc.lua:373: in function ‘\_start\_encounter’  
…arth/services/server/game\_master/controllers/arc.lua:349: in function ‘\_trigger\_edge’  
…arth/services/server/game\_master/controllers/arc.lua:282: in function ‘\_trigger\_out\_edge’  
…arth/services/server/game\_master/controllers/arc.lua:256: in function ‘trigger\_next\_encounter’  
…/controllers/encounters/wait\_for\_event\_encounter.lua:98: in function ‘\_on\_event\_triggered’  
…  
radiant/controllers/time\_tracker\_controller.lua:82: in function ‘set\_now’  
…hearth/services/server/calendar/calendar\_service.lua:379: in function ‘\_on\_event\_loop’  
…hearth/services/server/calendar/calendar\_service.lua:37: in function 'instance’  
radiant/modules/events.lua:227: in function \<radiant/modules/events.lua:221\>  
[C]: in function 'xpcall’  
radiant/modules/common.lua:257: in function 'xpcall’  
radiant/modules/events.lua:221: in function 'trigger’  
radiant/modules/events.lua:290: in function '\_trigger\_gameloop’  
radiant/modules/events.lua:338: in function '\_update’  
radiant/server.lua:62: in function \<radiant/server.lua:58\>

time of occurrence:  
When killing the Horrendous Goblin Chieftain (I think his name was something with H? Unfortunately I forgot the complete name)

Version:  
latest one downloaded via Steam (Alpha 18)  
No Mods

Results:  
None that I could see. The game continues and I think also the steam cloud after killing him appeared. Loot also appeared. Maybe another Event message failed?

Hope it helps! Best regards

---

<div class="post-metadata">

**Author:** ![linda](https://sea2.discourse-cdn.com/flex022/user_avatar/discourse.stonehearth.net/linda/32/48510_2.png) [@linda](https://discourse.stonehearth.net/u/linda)\
**Post date:** [August 24, 2016, 9:04pm UTC](https://discourse.stonehearth.net/t/engine-error-attempt-to-index-a-nil-value-goblin-boss-sheep/24841/4 "2016-08-24T21:04:34Z")

</div>

Thanks for catching that! Game was trying to set player id on a dead boss sheep which caused errors. Will be fixed in next build
