Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Colour combinations for certain soccer teams to be used to create 3D {brickr} models
# Create a soccer player using {brickr}
# This file specifies some colour combinations for certain teams
# Blog post: https://www.rostrum.blog/2019/05/31/brickr-soccer/
# You need to load some packages
# library(brickr)
# library(dray) # from remotes::install_github("matt-dray/dray")
# After creating a colour specification, pass it to
# bricks_from_table() %>% display_bricks() to render it
arsenal <- create_brickr_player()
liverpool <- create_brickr_player(
shirt_body_col = 7, # Bright red
shirt_sleeve_col = 7, # Bright red
shorts_col = 7, # Bright red
sock_col = 7, # Bright red
sock_trim_col = 7 # Bright red
)
man_city <- create_brickr_player(
shirt_body_col = 13, # Light royal blue
shirt_sleeve_col = 13, # Light royal blue
shorts_col = 1, # White
sock_col = 27, # Earth blue
sock_trim_col = 27 # Earth blue
)
tottenham <- create_brickr_player(
shirt_body_col = 1, # White
shirt_sleeve_col = 1, # White
shorts_col = 35, # Medium lilac
sock_col = 1, # White
sock_trim_col = 35 # Medium lilac
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.