Results 1 to 4 of 4

Thread: problem of raw data parameter passing netgame engine

  1. #1

    Default problem of raw data parameter passing netgame engine

    I'm new to netgame(both play and wriite), so I think that it is nessesary to pass some many initial data from server to client to new some units owned by other players, already on the map and already have done some bad things, and I think this could be complicated.
    So my idea is to have a function in server that can read all needed infomation from single unit a time. and in fact, I want the unit class take care of the data itself, server side unit class have some "breif_your_self" function and at client side initial unit by the breif data.
    I don't know if it's a good idea but it seems more flexible than certain number of parameters.
    So the thing is when I decide to do so, I found CL_String, which can be parameter of a netgame event, do not accept data with zeros for good reason.....:wheelchair:...

    Thank you reading my poor English and, any suggestion on how I can pass the data OR some else good way to solve my problem would be very nice.

  2. #2
    ClanLib Developer
    Join Date
    Sep 2006
    Location
    Bergen, Norway
    Posts
    588

    Default

    I onyl understood half of what you wrote, but how much data do you need to send? There is no limit to the number of argument on a netgame event..

  3. #3

    Default

    Quote Originally Posted by sphair View Post
    I onyl understood half of what you wrote, but how much data do you need to send? There is no limit to the number of argument on a netgame event..
    Thank you for telling me that.
    And now I see type of the arguments can really be uncertain. so no more questions, thank you sphair

  4. #4
    ClanLib Developer
    Join Date
    Sep 2006
    Location
    Bergen, Norway
    Posts
    588

    Default

    There is also support for sending custom types. Check out the NetGame example in SVN - there is a CustomType that is serialized over the network.

Similar Threads

  1. NetGame channeling?
    By catch22 in forum Official ClanLib SDK Forums
    Replies: 2
    Last Post: 05-29-2009, 06:43 AM
  2. Collision data seems to be lost whenever I install a new version of NS
    By Uhfgood in forum Novashell Game Creation System
    Replies: 1
    Last Post: 07-08-2008, 10:39 PM
  3. about save data
    By DavinciZhe in forum Official ClanLib SDK Forums
    Replies: 4
    Last Post: 01-24-2008, 03:18 PM
  4. CL 0.8 pixel data deleter class
    By Trigve in forum Official ClanLib SDK Forums
    Replies: 0
    Last Post: 10-27-2007, 11:33 AM
  5. How to use the vector data from CL_Raw ?
    By ARme in forum Official ClanLib SDK Forums
    Replies: 0
    Last Post: 12-21-2006, 08:35 PM

Bookmarks

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •