Confused in Munchkin Swarm


#1

I do not know what “end expected (to close at 3:5) at 13:1” means. I am using Lua.

My code is:


loop
       local enemy = self:findNearestEnemy()
    if enemy then
    -- If it comes closer than 10 meters, cleave it!
 local distance = self:distanceTo(enemy)
 if distance > 10 then
     self:attack(enemy)
    -- Else, attack the "Chest" by name.
 else
attack("Chest") 
end


#2

could you wrap your code in triple backticks `


#3

I do not know what backticks are used for in coding or how.


#4

Tom meant to ask you to format the code so it displays properly here. See the FAQ - I need help with my code!


#5

Fixed the format of the coding