From 76c1a5e2f814b01e9a7d42d7f850d4ab1d5531e4 Mon Sep 17 00:00:00 2001 From: BuckarooBanzay Date: Wed, 9 Feb 2022 11:24:10 +0100 Subject: [PATCH] add fancy_travelnet:fancy_travelnet fixes #247 --- mapobject/setup.go | 32 +++++++++++++++++--------------- 1 file changed, 17 insertions(+), 15 deletions(-) diff --git a/mapobject/setup.go b/mapobject/setup.go index 90f3020..525328d 100644 --- a/mapobject/setup.go +++ b/mapobject/setup.go @@ -41,21 +41,23 @@ func Setup(ctx *app.App) { //travelnet if ctx.Config.MapObjects.Travelnet { - l.AddMapObject("travelnet:travelnet", &TravelnetBlock{}) - l.AddMapObject("travelnet:travelnet_red", &TravelnetBlock{}) - l.AddMapObject("travelnet:travelnet_orange", &TravelnetBlock{}) - l.AddMapObject("travelnet:travelnet_blue", &TravelnetBlock{}) - l.AddMapObject("travelnet:travelnet_cyan", &TravelnetBlock{}) - l.AddMapObject("travelnet:travelnet_green", &TravelnetBlock{}) - l.AddMapObject("travelnet:travelnet_dark_green", &TravelnetBlock{}) - l.AddMapObject("travelnet:travelnet_violet", &TravelnetBlock{}) - l.AddMapObject("travelnet:travelnet_pink", &TravelnetBlock{}) - l.AddMapObject("travelnet:travelnet_magenta", &TravelnetBlock{}) - l.AddMapObject("travelnet:travelnet_brown", &TravelnetBlock{}) - l.AddMapObject("travelnet:travelnet_grey", &TravelnetBlock{}) - l.AddMapObject("travelnet:travelnet_dark_grey", &TravelnetBlock{}) - l.AddMapObject("travelnet:travelnet_black", &TravelnetBlock{}) - l.AddMapObject("travelnet:travelnet_white", &TravelnetBlock{}) + tb := &TravelnetBlock{} + l.AddMapObject("travelnet:travelnet", tb) + l.AddMapObject("travelnet:travelnet_red", tb) + l.AddMapObject("travelnet:travelnet_orange", tb) + l.AddMapObject("travelnet:travelnet_blue", tb) + l.AddMapObject("travelnet:travelnet_cyan", tb) + l.AddMapObject("travelnet:travelnet_green", tb) + l.AddMapObject("travelnet:travelnet_dark_green", tb) + l.AddMapObject("travelnet:travelnet_violet", tb) + l.AddMapObject("travelnet:travelnet_pink", tb) + l.AddMapObject("travelnet:travelnet_magenta", tb) + l.AddMapObject("travelnet:travelnet_brown", tb) + l.AddMapObject("travelnet:travelnet_grey", tb) + l.AddMapObject("travelnet:travelnet_dark_grey", tb) + l.AddMapObject("travelnet:travelnet_black", tb) + l.AddMapObject("travelnet:travelnet_white", tb) + l.AddMapObject("fancy_travelnet:fancy_travelnet", tb) } //protector