Class: Rubirai::FaceMessage

Inherits:
Message
  • Object
show all
Defined in:
lib/rubirai/messages/message.rb

Overview

The QQ Face Emoji message type

Instance Attribute Summary collapse

Attributes inherited from Message

#bot, #type

Class Method Summary collapse

Methods inherited from Message

all_types, check_type, #to_h, to_message

Instance Attribute Details

#face_idInteger (readonly)

Returns the face's id.

Returns:

  • (Integer)

    the face's id



302
# File 'lib/rubirai/messages/message.rb', line 302

set_message :Face, :face_id, :name

#nameString? (readonly)

Returns the face's name.

Returns:

  • (String, nil)

    the face's name



302
# File 'lib/rubirai/messages/message.rb', line 302

set_message :Face, :face_id, :name

Class Method Details

.from(**kwargs) ⇒ Rubirai::FaceMessage

Form a Rubirai::FaceMessage. Only needs to give one of the two arguments.

Options Hash (**kwargs):

  • :face_id (Integer)

    the face id (high priority)

  • :name (String)

    the face's name (low priority)

Returns:



302
# File 'lib/rubirai/messages/message.rb', line 302

set_message :Face, :face_id, :name