Wrox Programmer Forums
|
BOOK: Professional XMPP Programming with JavaScript and jQuery
This is the forum to discuss the Wrox book Professional XMPP Programming with JavaScript and jQuery by Jack Moffitt; ISBN: 978-0-470-54071-8
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Professional XMPP Programming with JavaScript and jQuery section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old October 15th, 2012, 03:05 AM
Registered User
 
Join Date: Oct 2012
Posts: 7
Thanks: 1
Thanked 0 Times in 0 Posts
Default No response after start game, CH11 Toetem

I tried ch11 Toetem example with jids registered on jabber.org.
After I click start game, there is no response at the client side. The players were removed from the waiting list but the board wasn't shown. At the referee side it received <service-unavailable>. I still not able to figure it out.

Could someone please help with this problem?
Here is the stanzas gathered from referee.js console.log:

Code:
<body xmlns='http://jabber.org/protocol/httpbind'>
  <iq from='[email protected]/3421d0bab9909f90' to='[email protected]/3d9a96c5a9e8965e' type='set' id='5214:sendIQ'>
    <start xmlns='http://metajack.im/ns/toetem' with='[email protected]/0d8d8ad79f9eac14'/>
  </iq>
</body>

<body rid='2100151655' xmlns='http://jabber.org/protocol/httpbind' sid='ed19fc2ba482dc016aa09e399d5e60a2'>
  <iq to='[email protected]/3421d0bab9909f90' id='5214:sendIQ' type='result' xmlns='jabber:client'/>
  <message to='[email protected]/0d8d8ad79f9eac14' xmlns='jabber:client'>
    <not-waiting xmlns='http://metajack.im/ns/toetem'>
      <player jid='[email protected]/0d8d8ad79f9eac14'/>
    </not-waiting>
  </message>
  <message to='[email protected]/3421d0bab9909f90' xmlns='jabber:client'>
    <not-waiting xmlns='http://metajack.im/ns/toetem'>
      <player jid='[email protected]/0d8d8ad79f9eac14'/>
    </not-waiting>
  </message>
  <presence to='[email protected]/Referee' xmlns='jabber:client'>
    <x xmlns='http://jabber.org/protocol/muc'/>
  </presence>
</body>

<body xmlns='http://jabber.org/protocol/httpbind'>
  <presence from='[email protected]/Referee' to='[email protected]/3d9a96c5a9e8965e'>
    <x xmlns='http://jabber.org/protocol/muc#user'>
      <item affiliation='owner' role='moderator'/>
      <status code='201'/>
    </x>
  </presence>
</body>

<body rid='2100151656' xmlns='http://jabber.org/protocol/httpbind' sid='ed19fc2ba482dc016aa09e399d5e60a2'>
  <message to='[email protected]' xmlns='jabber:client'>
    <x xmlns='http://jabber.org/protocol/muc#user'>
      <invite to='[email protected]/0d8d8ad79f9eac14'/>
    </x>
  </message>
  <message to='[email protected]' xmlns='jabber:client'>
    <x xmlns='http://jabber.org/protocol/muc#user'>
      <invite to='[email protected]/3421d0bab9909f90'/>
    </x>
  </message>
  <message to='[email protected]/0d8d8ad79f9eac14' xmlns='jabber:client'>
    <games xmlns='http://metajack.im/ns/toetem'>
      <game x-player='[email protected]/0d8d8ad79f9eac14' o-player='[email protected]/3421d0bab9909f90' room='[email protected]'/>
    </games>
  </message>
  <message to='[email protected]/3421d0bab9909f90' xmlns='jabber:client'>
    <games xmlns='http://metajack.im/ns/toetem'>
      <game x-player='[email protected]/0d8d8ad79f9eac14' o-player='[email protected]/3421d0bab9909f90' room='[email protected]'/>
    </games>
  </message>
</body>

<body xmlns='http://jabber.org/protocol/httpbind'>
  <message from='[email protected]' to='[email protected]/3d9a96c5a9e8965e' type='error'>
    <error code='503' type='cancel'>
      <service-unavailable xmlns='urn:ietf:params:xml:ns:xmpp-stanzas'/>
    </error>
  </message>
  <message from='[email protected]' to='[email protected]/3d9a96c5a9e8965e' type='error'>
    <error code='503' type='cancel'>
      <service-unavailable xmlns='urn:ietf:params:xml:ns:xmpp-stanzas'/>
    </error>
  </message>
</body>
 
Old October 15th, 2012, 11:40 AM
Registered User
 
Join Date: Oct 2012
Posts: 7
Thanks: 1
Thanked 0 Times in 0 Posts
Default

If I use jids registered on jabin.org, the problem is the same as described in this post: toetem not work when start game in Ch11.

The error stanza is received at the client side. Still don't know what cause the problem. The log is as follows:
Code:
<body xmlns='http://jabber.org/protocol/httpbind'>
  <message from='[email protected]/27208282491350285820889743' to='[email protected]/28817725171350285918212729'>
    <not-waiting xmlns='http://metajack.im/ns/toetem'>
      <player jid='[email protected]/28817725171350285918212729'/>
    </not-waiting>
  </message>
</body>

<body xmlns='http://jabber.org/protocol/httpbind'>
  <message from='[email protected]/27208282491350285820889743' to='[email protected]/28817725171350285918212729'>
    <games xmlns='http://metajack.im/ns/toetem'>
      <game x-player='[email protected]/42860538521350285929788015' room='[email protected]' o-player='[email protected]/28817725171350285918212729'/>
    </games>
  </message>
</body>

<body xmlns='http://jabber.org/protocol/httpbind'>
  <message from='[email protected]' to='[email protected]/28817725171350285918212729'>
    <x xmlns='http://jabber.org/protocol/muc#user'>
      <invite from='[email protected]/27208282491350285820889743'/>
    </x>
  </message>
</body>

<body rid='4137960843' xmlns='http://jabber.org/protocol/httpbind' sid='1031dcd5a967fc596068dbb25df96954'>
  <presence to='[email protected]/[email protected]/28817725171350285918212729' xmlns='jabber:client'>
    <x xmlns='http://jabber.org/protocol/muc'/>
  </presence>
</body>

<body xmlns='http://jabber.org/protocol/httpbind'>
  <presence from='[email protected]' to='[email protected]/28817725171350285918212729' type='error'>
    <x xmlns='http://jabber.org/protocol/muc'/>
    <error code='404' type='cancel'>
      <item-not-found xmlns='urn:ietf:params:xml:ns:xmpp-stanzas'/>
    </error>
  </presence>
</body>
 
Old October 15th, 2012, 01:28 PM
Registered User
 
Join Date: Oct 2012
Posts: 7
Thanks: 1
Thanked 0 Times in 0 Posts
Default

I changed the MUC_SERVICE to 'conference.jwchat.org' and it works!
Originally it was 'conference.jabber.org'.

Changing it resolves the 2 issues above but really don't know what causes these problems.
 
Old October 15th, 2012, 03:49 PM
Wrox Author
 
Join Date: Jan 2010
Posts: 178
Thanks: 0
Thanked 16 Times in 15 Posts
Default

Many severs only allow local users to access rooms and such. It may be that was the case here.

Toetem doesn't use MUC (at least not the version from the bok), so I'm not sure why that factored into it at all.

In any case, glad you got it working.





Similar Threads
Thread Thread Starter Forum Replies Last Post
No response after start game, CH11 Toetem begeeben BOOK: Professional XMPP Programming with JavaScript and jQuery 0 October 15th, 2012 02:49 AM
toetem not work when start game in Ch11 yinzhihong BOOK: Professional XMPP Programming with JavaScript and jQuery 3 August 3rd, 2012 11:25 AM
Toetem App ankushchadda BOOK: Professional XMPP Programming with JavaScript and jQuery 1 December 5th, 2010 05:20 PM
Changes in toetem app ankushchadda BOOK: Professional XMPP Programming with JavaScript and jQuery 4 November 1st, 2010 03:11 PM
How to start game development imsuneeta General .NET 0 September 21st, 2005 12:02 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.