Search found 31 matches

by duke
13 May 2009, 09:08
Forum: Server Side Extension Development
Topic: get All Users In a Zone
Replies: 19
Views: 16332

With the java version, Eclipse couldn't resolve Users to a type and couldnt cast ArrayList to a LinkedList (which it apparently had to do to use .push).
by duke
12 May 2009, 11:52
Forum: Server Side Extension Development
Topic: get All Users In a Zone
Replies: 19
Views: 16332

No, there isn't a direct method to do so. However you cycle through all the available rooms in the Zone and call the getAllUsers() method, which returns an array of users. The array returned is not an Actionscript array, but a Java array. This doesn't change things too much, but a Java array does n...
by duke
11 May 2009, 12:35
Forum: Features Wish List
Topic: getAllUsersButOne for Zone
Replies: 1
Views: 2658

getAllUsersButOne for Zone

Currently you can use getAllUsersButOne on a Room type, which is great - it's a very useful function! Could it be added to Zone? This (untested) should mimic it: User admin = zone.getUserByName("admin"); receivers = zone.getAllUsersInZone(); receivers.remove(admin);
by duke
10 May 2009, 11:16
Forum: Server Side Extension Development
Topic: Another userlist question/syntax problem (Java)
Replies: 1
Views: 1387

Another userlist question/syntax problem (Java)

How do I do this, but without busted syntax :P

Code: Select all

      for (User user : zone.getUserList())
      {
         trace(user.GetName());
      }
by duke
09 May 2009, 08:26
Forum: .Net / Unity3D API
Topic: GetAllUsers() ?
Replies: 1
Views: 2104

GetAllUsers() ?

Am I able to do this? I don't care what room they're in, I just want to do roomList().getAllUsers(); or something.
by duke
09 May 2009, 06:26
Forum: Server Side Extension Development
Topic: simple if statement doesnt work as expected
Replies: 4
Views: 2210

draive wrote:try:

if(!username.equals("admin"){

something

}


Thanks, that worked:

Code: Select all

if (!username.equalsIgnoreCase("admin"))
by duke
09 May 2009, 02:33
Forum: Server Side Extension Development
Topic: simple if statement doesnt work as expected
Replies: 4
Views: 2210

simple if statement doesnt work as expected

This doesn't work for some reason, where logically, it should! if (username != "admin") { trace("The user is " + username); } I mean, it traces that line in the console and says "The user is admin", but by the logic of that code, it shouldn't e...
by duke
08 May 2009, 01:40
Forum: SmartFoxServer 1.x Discussions and Help
Topic: { Update } SmartFoxServer PRO 1.6.5 is out!
Replies: 30
Views: 22312

Where abouts is the NPC tutorial in the online docs? Wouldn't mind reading about it over my lunch break :)
by duke
27 Apr 2009, 12:04
Forum: Server Side Extension Development
Topic: Resolving username from userid?
Replies: 1
Views: 1246

Resolving username from userid?

Can I do this on a server extension? I don't want to trust the client to send me his username as part of the sendXtMessage. I need to use the username in an SQL statement.
by duke
27 Apr 2009, 07:36
Forum: .Net / Unity3D API
Topic: SendXtMessage problem
Replies: 7
Views: 8717

Forgot a crucial part of the code that throws the current client to the SmartFox class: void OnConnection(bool success, string error) { if ( success ) { SmartFox.Connection = smartFox; Now my debugging stuff says im both sending the message and receiving a response :)
by duke
26 Apr 2009, 23:22
Forum: .Net / Unity3D API
Topic: SendXtMessage problem
Replies: 7
Views: 8717

Actually I think I know why. I wanted to keep the login/authentication completely seperate from the game, so I followed the island demo, but had some problems invoking the smartfox client using from Smartfox.cs, so I simply made a new SmartFoxClient. So I think i just have a new client sitting there...
by duke
26 Apr 2009, 06:03
Forum: .Net / Unity3D API
Topic: SendXtMessage problem
Replies: 7
Views: 8717

SendXtMessage problem

I've probably just missed something here: -C# / Unity3D -The command is definitely being sent on the client side. -All my extensions operate on the zone rather than per room (for the moment anyway). Relevant lines from client: extensionName = "moo_exchange"; smartFox.SendXtMessage(exte...
by duke
18 Apr 2009, 13:03
Forum: Server Side Extension Development
Topic: MySql Connection Confusion, Basic Questions
Replies: 16
Views: 10513

Hey duke, You may need to change the Driver in your config.xml to your current driver. You may want to check out this post for some hints. http://www.smartfoxserver.com/forums/viewtopic.php?p=15260#15260 Hope it helps, - Mike Thank you sir - that worked! I was still using the old driver name.
by duke
18 Apr 2009, 02:00
Forum: Server Side Extension Development
Topic: MySql Connection Confusion, Basic Questions
Replies: 16
Views: 10513

I'm having similar problems. Both SFS and mysql are on the same computer. I copied the latest JDBC for mysql, as per the instructions, and it still doesn't work. SFS even says it's processing that jar file! *sys-package-mgr*: processing new jar, 'C:\Program Files\SmartFoxServerPRO_1.6.2 \jre\lib\ext...
by duke
17 Apr 2009, 11:59
Forum: Server Side Extension Development
Topic: More Java examples!
Replies: 1
Views: 1232

More Java examples!

It would be great to see the existing AS server examples as java code :)

On a related topic, can you do _server.md5() in J? I only see hashCode(), which doesn't have the same function as md5, and returns an int.

Go to advanced search