Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Dark GDK / Online games

Author
Message
Hassan
15
Years of Service
User Offline
Joined: 4th May 2009
Location: <script> alert(1); </script>
Posted: 19th Nov 2009 17:00
Hello guys.

as you know, in online games, it's like when someone logs in, other players ( clients ) see him in-game, so my game was like, load/position world and the player, and in the game loop, i receive all players data and position them in the received position, but im wondering, if like, someone logs in, all clients have to load an object which is the one who logged in, is that true? it's like, whenever someone logs in your game will get some lag, but i never see such thing in other online games, how do they do it?

_Pauli_
AGK Developer
15
Years of Service
User Offline
Joined: 13th Aug 2009
Location: Germany
Posted: 19th Nov 2009 18:15
I think it is because all necessary player models are already loaded when you enter a game. That way only some number to identify the chosen character has to be send and the corresponding model is shown.
The dis-advantage in this is that no custom models can be used, because all players need to have the same models on their harddrive...

Now the plot thickens, the fps decreases, and the awesomeness goes through the roof.
Hassan
15
Years of Service
User Offline
Joined: 4th May 2009
Location: <script> alert(1); </script>
Posted: 19th Nov 2009 18:18 Edited at: 19th Nov 2009 18:18
how about the world and the objects and stuff? huge games like world of warcraft, hundreds, if not thousands of objects in the game, i doubt it's loaded everytime you run the game..since loading takes 5 seconds maximum

_Pauli_
AGK Developer
15
Years of Service
User Offline
Joined: 13th Aug 2009
Location: Germany
Posted: 19th Nov 2009 18:26
Well ok, in this case they use some kind of streaming-technology to load everything as needed. Other games with huge worlds like GTA4 do that even in singleplayer.
But I guess you won't be able to do this with DarkGDK unless you find a way how to perform DarkGDK commands in multiple threads...
I could also imagine a technique with creating models from memblocks and custom file formats, but anyway lots of work.

Now the plot thickens, the fps decreases, and the awesomeness goes through the roof.
Marsh0
15
Years of Service
User Offline
Joined: 18th Mar 2009
Location:
Posted: 19th Nov 2009 19:09
Only what you can see is loaded and as you move it loads more. Loading a object does not take 5 seconds. Also they are running on huge gaming servers and not your home computer.

Also at the loading screen when you first start the game a good deal of the work is done i imagine.
Hassan
15
Years of Service
User Offline
Joined: 4th May 2009
Location: <script> alert(1); </script>
Posted: 19th Nov 2009 20:04
So it's impossible to make such big online games, till now i made a level editor, which makes the buildings, and added them to the server files, and whenever someone logs the server sends him the building files, i made 20~ buildings and it's taking like 10 seconds, guess it's 100% impossible..

each 20 = 10 seconds

200 objects = 100 seconds
400 ( that might be enough to make a little city.. ) = 200 seconds
200/60 = 3.something
and terrain / players
i doubt someone would wait 4 minutes to play a game, which is bout a little city..lol

_Pauli_
AGK Developer
15
Years of Service
User Offline
Joined: 13th Aug 2009
Location: Germany
Posted: 19th Nov 2009 20:41
Yes that's right.
So the conclusion is you have to think about a better way to manage your in-game resources. Maybe divide your levels up into parts of a certain size. Then you have to think about a method to not let the player realize the loading of each part too much.

For example: in the case of a city, you could split it up into quarters or maybe just blocks. The player can act as usual inside the current area, but when he reaches the border something has to happen. Like the player has to take the subway to go to the next part of the city. You could let him go down some stairs to the underground. He would go in, the next part is loading, and he goes out in the part. Could be lots of things like a bridge, taking a cab, passing a tunnel,...
Well, that's just how I would handle it

Now the plot thickens, the fps decreases, and the awesomeness goes through the roof.
entomophobiac
22
Years of Service
User Offline
Joined: 1st Nov 2002
Location: United States
Posted: 19th Nov 2009 22:58
How about the number and size of all textures loaded? What format were the objects in and how large were they?

How many other things -- GUI, game logic, etc -- do you have loaded when the objects are sent to the graphics card?

There is a lot more going on than just the number of objects in the scene and there are a million different ways to build a pipeline for showing content in a cheaper way.

I bet WoW use all of those tricks and then some.
Cuddle Bunniezzz 12
15
Years of Service
User Offline
Joined: 14th Jan 2009
Location: Buffalo, NY
Posted: 20th Nov 2009 02:40
Well, the load speed depends on three things mainly, which can then be broken down into another few things.

-----
1. Server
A. Connection Speed (location is a factor here too)
B. # of clients connected
C. amount of data going in/out
D. The server computer's specs (CPU, RAM, etc).
2. Client
A. Connection Speed
B. amount of data comming in (data going out here isn't that much of a problem for the client vs. the server).
C. The client computer's specs
3. Game (the actual online game)
A. Size of program
B. Size of media that needs to be loaded (models, textures, etc).
-----

For connection speeds, it really depends on how you have data organized and transfered. And for game speeds it what the computer has to process.

What a lot of the big online games do is have multiple game servers, but have the permanent data be sent to one main server (like a login server). How the multiple server model works is that the client tries to connect to the closest server to them, if it fails, it goes for the next one in the line.

There are also games like warcraft 3's online play, they have you login to one server, then from there you can play games that are hosted by other clients (know as map hosts in WC3 terms). So all the first server does it manage the userdata (like if a user is logged in or not, or how many game they have won), and then have actual clients host the games. I creates a lot less server load.

http://www.darkgdk.us/ <- New community for DarkGDK coming soon!
Hassan
15
Years of Service
User Offline
Joined: 4th May 2009
Location: &lt;script&gt; alert(1); &lt;/script&gt;
Posted: 20th Nov 2009 07:09
Thanks for the info.

i've seen some games, that when you move, objects loads while you are moving, like when u start the game, it loads the objects close to you in X radius, when you move it starts loading the new objects in that radius, but all that happens while you are still moving, without any lags, how come?

entomophobiac
22
Years of Service
User Offline
Joined: 1st Nov 2002
Location: United States
Posted: 20th Nov 2009 09:38
One of the main issues here is what happens client-side and what happens server-side. Loading is a typical client-side task, meaning that the server only tells you where other players are -- your local client will still be responsible for loading everything.

Because of this, server speed isn't relevant when it comes to loading times. It's only the local client's effort.

You only need to send input to the server when you're doing something that you need permission to do. For example attacking an NPC, interacting with another player or running past another player. The rest is handled locally. And object loading is definitely handled locally -- the server can't tell your graphics card what to do; that's up to the client software.
Hassan
15
Years of Service
User Offline
Joined: 4th May 2009
Location: &lt;script&gt; alert(1); &lt;/script&gt;
Posted: 20th Nov 2009 09:55
yeah, i get that point, but how can the client still load objects without lag?

Isocadia
15
Years of Service
User Offline
Joined: 24th Jul 2009
Location:
Posted: 20th Nov 2009 13:52
Well, what you could do is save all the objects on the client side and make them load there pretty quick. Then when someone has custom content, make a message to the people that are in the range of that object if they want to download it, that way you only need to download custom content that is used near you, and when you downloaded it once, you never have to do that again.
Cuddle Bunniezzz 12
15
Years of Service
User Offline
Joined: 14th Jan 2009
Location: Buffalo, NY
Posted: 20th Nov 2009 22:13
You could also set an option for users to download custom content IF they want to.

Like Team Fortress 2 has an option where that you don't have to download the custom server content if you don't want to.

http://www.darkgdk.us/ <- New community for DarkGDK coming soon!
Isocadia
15
Years of Service
User Offline
Joined: 24th Jul 2009
Location:
Posted: 21st Nov 2009 12:18
Well, spore does that 2 with adventures, you download the content if you want to, if you don't, you just can't play that adventure.
Hassan
15
Years of Service
User Offline
Joined: 4th May 2009
Location: &lt;script&gt; alert(1); &lt;/script&gt;
Posted: 21st Nov 2009 14:16
So simply, i can't make such good / huge games using DarkGDK.

is it possible using DirectX? or do i still need to study WinAPI?

Login to post a reply

Server time is: 2024-11-20 09:40:04
Your offset time is: 2024-11-20 09:40:04