# Tomb Raider - code help - what are functions - lua default code for level

**URL:** <https://discourse.codecombat.com/t/tomb-raider-code-help-what-are-functions-lua-default-code-for-level/9418>\
**Category:** Uncategorized\
**Created:** [October 21, 2016, 11:13pm UTC](https://discourse.codecombat.com/t/tomb-raider-code-help-what-are-functions-lua-default-code-for-level/9418 "2016-10-21T23:13:19Z")\
**Posts on this page:** 1\
**Showing post:** 33

<div class="post-metadata">

**Author:** ![Harry\_the\_Wanderer](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.codecombat.com/harry_the_wanderer/32/5369_2.png) [@Harry\_the\_Wanderer](https://discourse.codecombat.com/u/Harry_the_Wanderer)\
**Post date:** [October 23, 2016, 12:55am UTC](https://discourse.codecombat.com/t/tomb-raider-code-help-what-are-functions-lua-default-code-for-level/9418/33 "2016-10-23T00:55:14Z")

</div>

Adding more patches here:

> [@LUA patches for other levels in forest](https://discourse.codecombat.com/t/lua-patches-for-other-levels-in-forest/9431):
>
> Maniac Munchkins ```lua -- Another chest in the field for the hero to break open! -- Attack the chest to break it open. -- Some munchkins wont stand idly by while you attack it! -- Defend yourself when a munchkin gets too close. while true do local enemy = hero:findNearestEnemy() local distance = hero:distanceTo(enemy) if hero:isReady(“cleave”) then – First priority is to cleave if its ready: elseif distance \< 5 then -- Attack the nearest munchkin that gets too close: else -- …

---

_[View the full topic](https://discourse.codecombat.com/t/tomb-raider-code-help-what-are-functions-lua-default-code-for-level/9418)._
