Completed p3 in LUA