From 15ba396e9d6fb2d210337339ec1ddab4e0896883 Mon Sep 17 00:00:00 2001 From: Trevor Flynn Date: Sat, 16 Sep 2017 10:01:39 -0700 Subject: [PATCH] Fix reallocating new array for enums on lookup --- game/src/plugins/skill/firemaking/src/fireamaking_data.kt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/game/src/plugins/skill/firemaking/src/fireamaking_data.kt b/game/src/plugins/skill/firemaking/src/fireamaking_data.kt index 4a130159d..01bb8bd6b 100644 --- a/game/src/plugins/skill/firemaking/src/fireamaking_data.kt +++ b/game/src/plugins/skill/firemaking/src/fireamaking_data.kt @@ -17,4 +17,6 @@ val FIRE_OBJ = 2732 val ASH = 592 val LIGHT_ANIMATION = Animation(733) -fun lookupLog(id: Int): Log? = Log.values().find { it.id == id } \ No newline at end of file +val LOGS = Log.values() + +fun lookupLog(id: Int): Log? = LOGS.find { it.id == id } \ No newline at end of file