1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.
  2. Two Factor Authentication is now available on BeyondUnreal Forums. To configure it, visit your Profile and look for the "Two Step Verification" option on the left side. We can send codes via email (may be slower) or you can set up any TOTP Authenticator app on your phone (Authy, Google Authenticator, etc) to deliver codes. It is highly recommended that you configure this to keep your account safe.

Simulated Functions???

Discussion in 'Ask a Coder' started by Neuroflare, Jun 25, 2001.

  1. Neuroflare

    Neuroflare Brewer - Patriot

    Joined:
    Jun 21, 2001
    Messages:
    425
    Likes Received:
    0
    What does this mean : "Simulated: Declares that a function may execute on the client-side when an actor is either a simulated proxy or an autonomous proxy. All functions that are both native and final are automatically simulated as well."??? I'm really confused about this.
     
  2. Smoke39

    Smoke39 whatever

    Joined:
    Jun 2, 2001
    Messages:
    1,793
    Likes Received:
    0
    Blooha!

    I've seen simulated functions all over the place in various code, especially projectiles, I think. I've been wondering what they are, too.
     
  3. EvilDrWong

    EvilDrWong Every line of code elevates you

    Joined:
    Jun 16, 2001
    Messages:
    932
    Likes Received:
    0
    I might be wrong, but the way ive come to understand simulated functions is that theyre something the client needs to know about too... like... more than just a variable. Like... a projectiles Bounce, Touch, or HitWall function is usually simulated, because the client can perfom the function along with the server (creating a bit of prediction if the client is racking in the packet loss or whatever)
    liek i said, im probably wrong, but thats the way ive come to understand it.
     
  4. Dragonfly_of_Forgery

    Dragonfly_of_Forgery long gone

    Joined:
    Jun 12, 2001
    Messages:
    409
    Likes Received:
    0
    AHHH! REPLICATION! RUN WHILE YOU CAN!

    I found a few tutorials on it.

    Unreal Networking Architecture
    Tim Sweeney
    Epic MegaGames, Inc.
    http://www.epicgames.com/

    I don't know exactly where to get it from, but I'll send you it or post it here if you want.

    I have another too, about making a guided ripperblade. Again, I have no idea where it is from or even who wrote it.

    simulated functions get called on the client, but only if called from another simulated function.

    ----

    when a bullet hits a wall and makes a spark you can simulate it on the client, but anything important like taking damage is only done on the server and sent to the client. (may be wrong)
     
  5. Smoke39

    Smoke39 whatever

    Joined:
    Jun 2, 2001
    Messages:
    1,793
    Likes Received:
    0
    Cheese?

    I'm scared! Press five to continue.
     
  6. Neuroflare

    Neuroflare Brewer - Patriot

    Joined:
    Jun 21, 2001
    Messages:
    425
    Likes Received:
    0
    Client... Right

    You may all lose what little respect (if any) you had for me when i say this, but what's the client and the server?
     
  7. Smoke39

    Smoke39 whatever

    Joined:
    Jun 2, 2001
    Messages:
    1,793
    Likes Received:
    0
    Blah!

    The server is the dude who created da game and the clients are da people that connect to the server. At least that's how I think it works...
     
  8. Dragonfly_of_Forgery

    Dragonfly_of_Forgery long gone

    Joined:
    Jun 12, 2001
    Messages:
    409
    Likes Received:
    0
    This is obvious, but... in single player, you are the server.

    Everything important is done on the server and sent to clients, so they all get the same information.

    Little, unimportant things like smoke puffs can be created on clients because even if they are different from the other players, it dosen't matter.
     
  9. Smoke39

    Smoke39 whatever

    Joined:
    Jun 2, 2001
    Messages:
    1,793
    Likes Received:
    0
    I see...

    So what if I had a simulated function that fired lasers in every direction. Only the person who fired them would see/be affected by them?
     
  10. Dragonfly_of_Forgery

    Dragonfly_of_Forgery long gone

    Joined:
    Jun 12, 2001
    Messages:
    409
    Likes Received:
    0
    Um... it depends. Simulated functions are (I think) still called by the host, so if the host is told to send the lasers to all clients then everyone will see them. Otherwise only you will.

    There are a lot of other things to do with replication besides simulated functions.

    Heres some bits copied from the great big tutorial:

    And some other stuff:

    Don't know if any of that is useful or understandable... go read the full tutorial.

    ...

    Can any of you play a net game with the Seekers Pack 5 and tell me what works and what dosen't?
     
  11. Smoke39

    Smoke39 whatever

    Joined:
    Jun 2, 2001
    Messages:
    1,793
    Likes Received:
    0
    Fish Sticks

    Eugh... That's a bit funky... Where's the whole tutorial?

    I might've been able to test your seekers pack on our LAN today since my friend is coming over, but my mom's laptop is, like, broken. It's the only other decent computer we have, other than mine.
     
  12. Dragonfly_of_Forgery

    Dragonfly_of_Forgery long gone

    Joined:
    Jun 12, 2001
    Messages:
    409
    Likes Received:
    0
    I don't know where I got the full tutorial but if you ask I'll email you it. Or does anyone else know where to get it? It seemed to come from megagames.com but I don't know anything.

    Hey, Postal knows all about this net stuff and he's making WAR network compatible. Wouldn't it be nice if he popped in and taught us a bit?

    For example (of what to teach us),Do I need to change the Clientfire and Clientaltfire functions to get my more interesting fire modes working in net play?

    I need someone to test Seekers. Over the internet is fine. I just need it tested. I will try hosting a game and see if anyone joins, but my ping is wayy out there....
     
  13. Smoke39

    Smoke39 whatever

    Joined:
    Jun 2, 2001
    Messages:
    1,793
    Likes Received:
    0
    Marmalade

    Right now I'm concentrating on just getting Pain done (Ablosquilmawa is gonna be REALLY wierd, YEAH!). I still need help, though. Help me (if you wanna see Pain, that is...)! I'll do something, uh... wierd if you do! Yeah, I'll do something really wierd for you as a reward. Ah, I need a picture of cheese I can stick in these as rewards... I'm gonna go make one.
     
  14. Smoke39

    Smoke39 whatever

    Joined:
    Jun 2, 2001
    Messages:
    1,793
    Likes Received:
    0
    Cheese!

    I made one!
     
  15. Bytekeeper

    Bytekeeper Last of the Brunnen G

    Joined:
    Jul 15, 2001
    Messages:
    181
    Likes Received:
    0
    Hi there,

    Simulated functions are methods of the class which can be called by the client too. This means, if the you make an simulated tick ie. the client will call the tick for himself, and the server will call that tick for himself too. None of both send something to the other side, it just makes the client able to call that function.
    It's IMHO also requiered if you want to call a method on the client from the server-side.
    A simulated function will only be executed for
    ROLE >= ROLE_simulatedproxy

    -
    Bytekeeper
     
  16. Smoke39

    Smoke39 whatever

    Joined:
    Jun 2, 2001
    Messages:
    1,793
    Likes Received:
    0
    All this network blargg is confusing me...
     
  17. Euphoric Beaver

    Euphoric Beaver impeccably groomed

    Joined:
    Apr 19, 2001
    Messages:
    3,158
    Likes Received:
    0
    So why would I want to use these simulated functions?
     
  18. Smoke39

    Smoke39 whatever

    Joined:
    Jun 2, 2001
    Messages:
    1,793
    Likes Received:
    0
    It has something to do with all this network blargg. It's either necessary for network compatibility, or it just makes the game faster in multiplayer.
     

Share This Page