Skip to content
This repository was archived by the owner on Oct 22, 2024. It is now read-only.

Commit

Permalink
Move the style prototype stuff out of data.lua
Browse files Browse the repository at this point in the history
This is the way everyone else does it, so why not?
  • Loading branch information
narc0tiq committed Aug 15, 2015
1 parent 65c1eb6 commit c5a2b05
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 23 deletions.
24 changes: 1 addition & 23 deletions data.lua
Original file line number Diff line number Diff line change
@@ -1,23 +1 @@
data:extend({
{
type = "font",
name = "evoGUI_small_font",
from = "default",
size = 10,
},
})

local evoGUI_small_button_style = {
type = "button_style",
parent = "button_style",
font = "evoGUI_small_font",
scalable = false,
width = 18,
height = 18,
top_padding = 0,
bottom_padding = 0,
left_padding = 0,
right_padding = 0,
}

data.raw["gui-style"].default["evoGUI_small_button_style"] = evoGUI_small_button_style
require "prototypes.styles"
23 changes: 23 additions & 0 deletions prototypes/styles.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
data:extend({
{
type = "font",
name = "evoGUI_small_font",
from = "default",
size = 10,
},
})

local evoGUI_small_button_style = {
type = "button_style",
parent = "button_style",
font = "evoGUI_small_font",
scalable = false,
width = 18,
height = 18,
top_padding = 0,
bottom_padding = 0,
left_padding = 0,
right_padding = 0,
}

data.raw["gui-style"].default["evoGUI_small_button_style"] = evoGUI_small_button_style

0 comments on commit c5a2b05

Please sign in to comment.