Class: Discordrb::Collectibles::Nameplate
- Inherits:
-
Object
- Object
- Discordrb::Collectibles::Nameplate
- Defined in:
- lib/discordrb/data/collectibles.rb
Overview
Collectable background images shown on a user's name in the member's tab.
Instance Attribute Summary collapse
-
#asset ⇒ String
readonly
The path to the nameplate asset.
-
#label ⇒ String
readonly
The label of the nameplate.
-
#palette ⇒ Symbol
readonly
The background color of the nameplate.
-
#sku_id ⇒ Integer
readonly
ID of the nameplate's SKU.
Instance Method Summary collapse
-
#url(static: false) ⇒ String
Utility method to get the URL of this nameplate.
Instance Attribute Details
#asset ⇒ String (readonly)
Returns the path to the nameplate asset.
21 22 23 |
# File 'lib/discordrb/data/collectibles.rb', line 21 def asset @asset end |
#label ⇒ String (readonly)
Returns the label of the nameplate.
24 25 26 |
# File 'lib/discordrb/data/collectibles.rb', line 24 def label @label end |
#palette ⇒ Symbol (readonly)
Returns the background color of the nameplate.
27 28 29 |
# File 'lib/discordrb/data/collectibles.rb', line 27 def palette @palette end |
#sku_id ⇒ Integer (readonly)
Returns ID of the nameplate's SKU.
18 19 20 |
# File 'lib/discordrb/data/collectibles.rb', line 18 def sku_id @sku_id end |
Instance Method Details
#url(static: false) ⇒ String
Utility method to get the URL of this nameplate.
42 43 44 |
# File 'lib/discordrb/data/collectibles.rb', line 42 def url(static: false) static ? API.static_nameplate_url(@asset) : API.nameplate_url(@asset) end |