switch spectator not working, switch player does

You think you've found a bug? Please report it here.

Moderators: Lapo, Bax

Post Reply
EsquireMD
Posts: 6
Joined: 02 Nov 2009, 22:54

switch spectator not working, switch player does

Post by EsquireMD »

switch player works for me on both server and client side, however it switches a spectator(-1) to a player which is opposite to its description. And switchSpectator doesn't do anything for me. anyone else have this problem?
User avatar
Lapo
Site Admin
Posts: 23438
Joined: 21 Mar 2005, 09:50
Location: Italy

Post by Lapo »

Hi,
those methods should have probably be called with a more meaningful name.
Originally only switchSpectator existed, which would turn a spectator user into a player. Subsequently we have added the switchPlayer method which turns a player into a spectator.

Can you explain exactly what is not working for you and a description of how we can reproduce it?
Also make sure to specify which server and client API version you are using.

Thank you
Lapo
--
gotoAndPlay()
...addicted to flash games
EsquireMD
Posts: 6
Joined: 02 Nov 2009, 22:54

Post by EsquireMD »

Hi Lapo,

I am using the latest and greatest, Smart fox server 1.6.6 and the client API is flash AS3.

The command _server.switchPlayer(theUser, theRoomId) is supposed to according to the server API, switch a player into a spectator(playerid = -1).
However, the command switches a spectator into a player and assigns it the next available player id number. and the command switch spectator on the server API does nothing. it will not switch a player into a spectator or vice versa. The same happens for the AS3 API of switch spectator and switch player.

Thanks for the help.
Post Reply