-
Notifications
You must be signed in to change notification settings - Fork 41
/
tf2_inventory.rb
33 lines (26 loc) · 897 Bytes
/
tf2_inventory.rb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
# This code is free software; you can redistribute it and/or modify it under
# the terms of the new BSD License.
#
# Copyright (c) 2010-2014, Sebastian Staudt
require 'steam-condenser/community/game_inventory'
require 'steam-condenser/community/tf2/tf2_item'
module SteamCondenser::Community
# Represents the inventory (aka. Backpack) of a Team Fortress 2 player
#
# @author Sebastian Staudt
class TF2Inventory < GameInventory
# The Steam application ID of Team Fortress 2
APP_ID = 440
# Creates a new inventory object for the given SteamID64 in Team Fortress 2
# (App ID 440)
#
# @param [Fixnum] steam_id64 The 64bit SteamID of the player to get the
# inventory for
# @macro cacheable
def initialize(steam_id64)
super APP_ID, steam_id64
end
# The class representing Team Fortress 2 items
@item_class = TF2Item
end
end