* adding support for TestSessionMessage

This commit is contained in:
Seth Call 2012-08-26 21:45:25 -05:00
parent f26f923677
commit 4a2bf208fb
1 changed files with 6 additions and 0 deletions

View File

@ -83,6 +83,12 @@ module JamRuby
return Jampb::ClientMessage.new(:type => ClientMessage::Type::USER_JOINED_JAM_SESSION, :target => CLIENT_TARGET, :user_joined_jam_session => joined)
end
# create a test message to send in session
def test_session_message(session_id, msg)
test = Jampb::TestSessionMessage.new(:msg => msg)
return Jampb::ClientMessage.new(:type => ClientMessage::Type::TEST_SESSION_MESSAGE, :target => SESSION_TARGET_PREFIX + session_id, :test_session_message => test)
end
# create a heartbeat
def heartbeat()
heartbeat = Jampb::Heartbeat.new