[GSTNet] Send_Function Working Correctly?

Posted By: adoado

[GSTNet] Send_Function Working Correctly? - 05/03/08 18:17

Hello ^^

I am using GSTNet. I call Send_Function on the client, and the server receives it but no client does?

I call:

Send_Function("OnClientJoinGlobal","0",1,1);

And in the 'Send_Function' function is

GSTNet_ClientSend(0, GSTNet_EventFunction, sGSTNetTemp1);

so, why is this message not getting to any of the clients?

Thanks,
Adoado ^^
Posted By: nfs42

Re: [GSTNet] Send_Function Working Correctly? - 05/04/08 03:02

you have to register an event with GSTNet_Events(GSTNet_EventFunction,funcname) and send the message in this event function from server to the defined client.

that's wrong in the manual. see demo
 Code:
//------------------------------------------------------------------
// function for event: GSTNet_EventFunction
// input: vTyp : event-id
//        sMsg: data
//        vSender: sender client id
//        vReceiver: receiver id       
//------------------------------------------------------------------
function evFunction(vTyp, sMsg, vSender, vReceiver)
{
  diag("\nType:"); str_for_num(sGSTNetTemp, vTyp); diag(sGSTNetTemp);
  diag("\nSender:"); str_for_num(sGSTNetTemp, vSender); diag(sGSTNetTemp);
  diag("\nReceiver:"); str_for_num(sGSTNetTemp, vReceiver); diag(sGSTNetTemp);
  GSTNet_ServerSend(vReceiver, vTyp, sMsg);
  if(GSTNet_Connection() == 2 || GSTNet_Connection() == 3 ) {
    Parse_Function(sMsg);             // parse and execute ...
  }
}


i have to overwork some function because automatic sending infos from clients to other clients by the server without checking by the server is really insecure, because GSTNet.dll can be used to connect to any GSTNet-server
Posted By: adoado

Re: [GSTNet] Send_Function Working Correctly? - 05/09/08 06:40

Hello

Ok, thank you, I am using events now and I nearly have them working ^^

Just one idea to improve GSTNet - could you make it that if I call "serversend" with a clientID which does not exist it does not freeze? Using Sendarray, etc is fine when you send to an invalid clientID.

Thanks,
Adoado
Posted By: nfs42

Re: [GSTNet] Send_Function Working Correctly? - 05/09/08 07:15

good find, i will fix this
Posted By: adoado

Re: [GSTNet] Send_Function Working Correctly? - 05/09/08 07:35

Thankyou so much! ;\) You would not believe how much that would help my project atm :P

Just wondering, when will the fix be released? \:D

Thanks again,
Adoado
Posted By: nfs42

Re: [GSTNet] Send_Function Working Correctly? - 05/09/08 09:29

this weekend
Posted By: adoado

Re: [GSTNet] Send_Function Working Correctly? - 05/10/08 15:04

Awesome, thanks again ;\)
Posted By: nfs42

Re: [GSTNet] Send_Function Working Correctly? - 05/11/08 00:22

Download GSTNet 0.5.24
----------------------------------------------------------------------------------
^: Bugfix
x: changed feature
+: added feature
-: deleted feature
*************************************************
2008-05-09 Release 0.5.24 public beta
-------------------------------------------------
^ crash with sending to an none existing receiver
x _Synchronize input mode
+ _SynchronizeEntity
+ _SynchronizeSkills


need sendfile function ?
Posted By: adoado

Re: [GSTNet] Send_Function Working Correctly? - 05/11/08 22:38

Thanks ;\)

I tried it, but it does not work correctly. I replaced the old DLL with the new one and I get messages such as 'ServerInit not found in DLL', 'clientsend not found in DLL', etc. ??

Thanks,
Adoado
Posted By: nfs42

Re: [GSTNet] Send_Function Working Correctly? - 05/11/08 23:43

is dll loaded ?? acklog.txt
Posted By: adoado

Re: [GSTNet] Send_Function Working Correctly? - 05/12/08 22:38

Nope, its not loading up. The previous version worked fine..

Thanks,
adoado
Posted By: nfs42

Re: [GSTNet] Send_Function Working Correctly? - 05/12/08 22:43

nothing really changed
can you post me the acklog.txt ?
what version of GSTNet loads fine ?
Posted By: broozar

Re: [GSTNet] Send_Function Working Correctly? - 05/13/08 17:49

the fixed 0.5.23 "v2" i assume, the one you created for us after we complained about a similar error, "dll could not be loaded". -> germanunkol's problem.
Posted By: nfs42

Re: [GSTNet] Send_Function Working Correctly? - 05/13/08 17:52

nothing really changed, i'll look into it
© 2024 lite-C Forums