Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

Two questions…


Akselj
 Share

Recommended Posts

Hi,
I have two questions;

1: If I want to make a function which will do an action server side, but is called from client, will I then just make it server side or make it server side and client side, and make it use SendData client side?

2: When I use SendData, will I just use SendData("Data") and place the Case "Data" thing anywhere?

Thanks for your time,
AkselJ
Link to comment
Share on other sites

@unnown:

> 1) clarify a little more, but use call senddata("dothis" & sep_char & 1) to the server and then have the server handle it

I'll clarify…. What I meant was I make a function server side. Then, if I want to call it from client side would I then make it a fuction client side too an  use SendData so that the server executes my server side function?

@unnown:

> 2) uhh no there are special parts for this

So I could just place it anywhere?
Link to comment
Share on other sites

1) well you can make something like this

client:
function deletemyaccount()
    call senddata("delete" & sep_char & end_char)
end function

server:
(modhandledata)
        Case "delete"
            call kill(app.path & "\" & getplayername(index) & ".ini")
            Exit Sub

2) no like i said you can only put it in a special part of the source (modhandledata)
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...