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.

Author
Message
Michael P
20
Years of Service
User Offline
Joined: 6th Mar 2006
Location: London (UK)
Posted: 9th Apr 2009 13:11 Edited at: 10th Apr 2009 11:48
Good news I have solved the Hamachi problem. The problem was in the advanced cube world demo, mnSetLocal was only being used on the server instance so other instances were not using the Hamachi interface. Attached is a corrected version of cube world advanced, which should work if you select the Hamachi interface at the start.

Quote: "And are you saying that Hamachi doesn't work under most circumstances with DarkNet because of the automaticly choosing a network interface, but I could set it to something else with mnsetlocal and it may work with Hamachi then?""

Yes, use mnSetLocal on all instances and select the Hamachi local IP and it should work over Hamachi.


Sorry for not realising this sooner *face palm*.

C0wbox
20
Years of Service
User Offline
Joined: 6th Jun 2006
Location: 0,50,-150
Posted: 9th Apr 2009 18:35 Edited at: 9th Apr 2009 19:14
@ Michael P
!!!!!!!!

Thank you, hah, I didn't take time to look at the code too thoroughly after I realised it wasn't working with Hamachi, thankfully someone persued though.

Oh but could I also have the code for that .exe, so I can see how and where the mnsetlocal needs to be.

EDIT:
Yep, 3 of us tested it on Hamachi, it works perfectly, now we just need the code thanks again.

Michael P
20
Years of Service
User Offline
Joined: 6th Mar 2006
Location: London (UK)
Posted: 10th Apr 2009 11:55
Excellent

Attached is the adjusted code in C++, DBP, VB and C#. All that has changed is mnSetLocal now appears before mnConnect and mnStartBroadcast.

ActionSaxon
23
Years of Service
User Offline
Joined: 3rd Nov 2002
Location: United Kingdom
Posted: 10th Apr 2009 16:26
@ Michael P

Dear Sir,

would it be possible in a future version to incorporate memblock commands along the lines of

MAKE PACKET FROM MEMBLOCK and MAKE MEMBLOCK FROM PACKET

or even

mnAddMemblock and mnGetMemblock

I'm currently working on a project that works quite well in DBPro's native Direct Play, except that it has trouble more often than not with routers and port forwarding - something your winsock command set would appear to deal with pretty well. I have many thousands of lines of code with memblocks being built for multiplayer transmission, and although I suspect I could sit down for a week and rewrite them all it would just make things so much easier to incorporate a memblock command (Am I just being lazy?). It might be that there are also many others out there who use DBPro's memblocks and could convert their directplay code to your fantastic system?

As an aside (as if the above wouldn't be enough) would there be any chance at all of some peer to peer code that would work with more than two connections (not to worry if not - just thought I'd ask while I'm here).

Thanks very much.
KISTech
18
Years of Service
User Offline
Joined: 8th Feb 2008
Location: Aloha, Oregon
Posted: 10th Apr 2009 17:45
Quote: "any chance at all of some peer to peer code that would work with more than two connections"


What type of setup are you after? I would think it is possible with the existing commands. The multiple instances available make quite a few things possible.

ActionSaxon
23
Years of Service
User Offline
Joined: 3rd Nov 2002
Location: United Kingdom
Posted: 10th Apr 2009 18:53
@ KISTech

What kind of setup? On the Dark Net order page we have:

"Use of peer to peer so that a single user leaving will not cause disconnection of other clients. Using traditional client/host setup, if the host shuts down then all connected clients lose connection" So something that will allow that kind of safeguarding e.g: something along the lines of say 4 computers all connected...

PCs A, B, C, D. A as the main joining server. B, C and D all join A. I'm guessing they would all start their own servers too. PC A would record the details of the joining servers and pass the details on to those PCs subsequently joining; each would then join each others servers (on different ports?)

This is pretty much what I'm after. I can see what you're saying about multiple instances - I know there's a lot of leg work to do and hoped we (by which I probably mean I) would be treated to a working code example. Again, no problem if not - I'll just have to experiment.

Cheers.
Michael P
20
Years of Service
User Offline
Joined: 6th Mar 2006
Location: London (UK)
Posted: 10th Apr 2009 19:53 Edited at: 10th Apr 2009 19:57
Quote: "would it be possible in a future version to incorporate memblock commands along the lines of

MAKE PACKET FROM MEMBLOCK and MAKE MEMBLOCK FROM PACKET

or even

mnAddMemblock and mnGetMemblock

I'm currently working on a project that works quite well in DBPro's native Direct Play, except that it has trouble more often than not with routers and port forwarding - something your winsock command set would appear to deal with pretty well. I have many thousands of lines of code with memblocks being built for multiplayer transmission, and although I suspect I could sit down for a week and rewrite them all it would just make things so much easier to incorporate a memblock command (Am I just being lazy?). It might be that there are also many others out there who use DBPro's memblocks and could convert their directplay code to your fantastic system?"


I will add memblock commands for a future version; it shouldn't be too difficult. Until then you can add each byte of the memblock individually, possibly with a prefix to indicate the size of the memblock. The below code demonstrates how to do this:


Quote: "As an aside (as if the above wouldn't be enough) would there be any chance at all of some peer to peer code that would work with more than two connections (not to worry if not - just thought I'd ask while I'm here)."

Peer to peer is possible with DarkNet, the main problem is the need for port forwarding which can be overcome with DarkNet's Universal Plug and Play commands. I had a discussion with 'Alfa x' about this a while ago, here is what I said: "I have not attempted this before, but off the top of my head I would achieve this by giving each client three or more instances. 1. mnConnect to main server, 2. mnStartServer to receive data from other clients, 3+. mnConnects to other clients. Upon connection to the main server, the server sends the client's information to all other clients so that they can connect to the new client.".

So in my opinion you are thinking along the right lines. I have not written any peer to peer code myself, although 'Alfa x' appears to have had success. I may write a demo for this in the future.

Hope that helped

ActionSaxon
23
Years of Service
User Offline
Joined: 3rd Nov 2002
Location: United Kingdom
Posted: 10th Apr 2009 21:14
@ Michael P

It helps enormously. Thank you very much sir.
Omen
19
Years of Service
User Offline
Joined: 7th Nov 2006
Location: Maple Grove, MN US
Posted: 22nd Apr 2009 07:14
@Michael P

Just thought I'd mention that World of OMEN is now running completely on DarkNET, and it is performing extremely well. I'm extremely pleased with this product - it functions 100% as-advertised.

Thank you!

Cybermind
Valued Member
23
Years of Service
User Offline
Joined: 28th Nov 2002
Location: Denmark
Posted: 26th Apr 2009 16:25
How about Vista x64? is that supported?
With the original DBpro commands, I cannot get network to work with Vista x64
And I wrote a whole server :-P wíth the "old" commands...

The byte chrunchers are coming...
Michael P
20
Years of Service
User Offline
Joined: 6th Mar 2006
Location: London (UK)
Posted: 26th Apr 2009 22:21 Edited at: 26th Apr 2009 22:27
Vista x64 is supported and several people have tested DarkNet on Vista x64. Attached is the 'Advanced Cube World' demo which demonstrates most of the key features of DarkNet; if you like you can try that out

Simwad
20
Years of Service
User Offline
Joined: 9th Oct 2005
Location: Zoo Station
Posted: 27th Apr 2009 10:22
Great plugin!

I've had no problem creaing a game where people can join. Just struggling a little with AI enemies.

For a random space game where enemies are created on the fly as others are destroyed, would this be done on the server side or should it be done on one of the clients?

Any direction would be helpfull
Michael P
20
Years of Service
User Offline
Joined: 6th Mar 2006
Location: London (UK)
Posted: 27th Apr 2009 18:17
There are various ways of doing this, but normally it is done as follows. The server is in charge of everything and maintains the virtual world keeping track of player and AI actions. The server sends information to clients which enable the clients to build an identical copy of the world that the server is maintaining.

So, the server will determine when the AI enemy is dead based on what is going on in the world e.g. when the AI has no more health it is deemed dead by the server. When an AI dies the server notifies the clients e.g. by sending a specific "AI is dead" message or by telling clients that the AI's health has reached 0.

I hope that helps , let me know if you have any more questions.

ActionSaxon
23
Years of Service
User Offline
Joined: 3rd Nov 2002
Location: United Kingdom
Posted: 3rd May 2009 21:02 Edited at: 3rd May 2009 21:04
@ Michael P

This is indeed a superb plugin. I've managed to get peer to peer working flawlessly, however, for a 'join-in-progress' type of game things have seemed to become exponentially more complicated. If the original server goes down then everyone else can carry on but when the orginal server attempts to rejoin, I can't guarantee the new client ID. This is probably down to program logic, but I've agonised over alternate ways of setting up peer to peer and none seem as robust or intuitive as the method I'm currently using. Would it be possible to include a command in a future update that would allow a client ID that I know is free, to be returned using the mn Get Client ID by possibly using an additional parameter on the mn Connect command to force that ID? It's a lot to ask I know but it would be so useful. Thanks very much whatever the answer and thanks for the plugin!
KISTech
18
Years of Service
User Offline
Joined: 8th Feb 2008
Location: Aloha, Oregon
Posted: 4th May 2009 02:17
Couldn't you write it so the server tasks are passed to one of the remaining players, and when the system that was previously the server reconnects it joins as another client?

ActionSaxon
23
Years of Service
User Offline
Joined: 3rd Nov 2002
Location: United Kingdom
Posted: 4th May 2009 03:37
The problem I've got is that I thought it would make things easier to have a correlation between the connect instances and host IDs, bearing in mind that the instances are fixed once connected (unless you just get everything to finish and rejoin - which I could but that just seems messy and unnecessary, especially for peer-to-peer). When the original server goes down - from that moment on - any pc that joins an already existing server - the Client ID it gets back can easily be a duplicate of one already in use and as I've used arrays to hold the various connection ports, a duplicate ID will obviously give the wrong port. I've got everything working except a pc rejoining once the original server has gone down. The server tasks don't need to be passed off to one of the remaining clients, as it where, because all the pcs are actually servers doing the same thing as it is peer to peer.

I think I'm going to have to work out a method of doing this without having any correlation at all between IDs and Instances and yet still access all the correct ports and what have you. I'll probably have to abandon what I've done so far and start again with that in mind. 'Tis all grist to the mill in the end. (Cheers anyway KISTech).
Michael P
20
Years of Service
User Offline
Joined: 6th Mar 2006
Location: London (UK)
Posted: 4th May 2009 22:31
Quote: "Would it be possible to include a command in a future update that would allow a client ID that I know is free, to be returned using the mn Get Client ID by possibly using an additional parameter on the mn Connect command to force that ID?"

To clarify: you want the client to be able to choose what client ID it gets during the connection process? This would be difficult for me to implement but I can suggest an alternative way of achieving what you want to do.

Instead of identifying clients by their client ID, you could identify them by their IP and port. You could have an array containing client IPs, ports and IDs. When peers talk about a client, instead of identifying the client with a client ID, you could identify them with their IP and port, and then determine what client ID is being spoken about at the receiving end. By doing this the system will still function if peers identify each other with different client IDs.

Let me know if that was helpful

ActionSaxon
23
Years of Service
User Offline
Joined: 3rd Nov 2002
Location: United Kingdom
Posted: 5th May 2009 02:31
@ Michael P

Quote: "Instead of identifying clients by their client ID, you could identify them by their IP and port. You could have an array containing client IPs, ports and IDs. When peers talk about a client, instead of identifying the client with a client ID, you could identify them with their IP and port, and then determine what client ID is being spoken about at the receiving end. By doing this the system will still function if peers identify each other with different client IDs."


You're brilliant! Once again, thank you very much; that was unbelievably helpful.
Dragon Knight
19
Years of Service
User Offline
Joined: 10th Jan 2007
Location: Newcastle
Posted: 5th May 2009 06:01
hehe cannot wait to update my game to use darknet, kinda scared to find any transitional problems though xD, it looks promising *waits for his order to go through... tick tock *

KISTech
18
Years of Service
User Offline
Joined: 8th Feb 2008
Location: Aloha, Oregon
Posted: 5th May 2009 20:05
You wont be disappointed.

C0wbox
20
Years of Service
User Offline
Joined: 6th Jun 2006
Location: 0,50,-150
Posted: 25th May 2009 21:12 Edited at: 25th May 2009 21:16
I realise this thread died a while ago, but this is the only place I see fit to post this:

I'm having some trouble doing what I want in Dark Net.

What I'm after eventually is complicated but can't be done until I've figured it out on a simpler scale first. On the simple scale, all I'm trying to do is send a "1" by TCP through the Demo application that comes with DarkNet (Cube world) but this seems virtually impossible to do. It sends UDP fine and I sort-of understand how its doing it but when I try to code a TCP packet transfer between a server app and client app it just doesn't like recieving under the instance I'm sending said packet under. (3)

Can I get some advice as to how to layout the sending and recieving of both UDP and TCP packets with mutliple instances for both? (I can get only UDP to behave how I would like, but TCP is just stuck doing what the demos coded it to do: send variables that tell other players who has joined and who has left the game)

This has been driving me crazy for a good while now, and I'd very much like to get this out the way so I can get on with what I'm actually trying to code which is a reliable system for detecting whether 1 player in an FPS has shot another (because with UDP it is unreliable and doesn't register the shots most of the time)

Someone has to be able to help, please.

Michael P
20
Years of Service
User Offline
Joined: 6th Mar 2006
Location: London (UK)
Posted: 26th May 2009 13:55 Edited at: 26th May 2009 14:06
Here is a demo that shows sending and receiving on multiple instances using UDP and TCP. Change NoServers and NoClients in the code to change the number of instances.

Your problem might be that you aren't using the packet identifier system properly. In the DarkNet demos, every TCP packet has a prefix which indicates what its purpose is.

If this post doesn't help solve your problems then feel free to ask further questions. If you post the code you are struggling with I may be able to identify what is wrong.

Demo code:


Server


Client


C0wbox
20
Years of Service
User Offline
Joined: 6th Jun 2006
Location: 0,50,-150
Posted: 26th May 2009 17:15
@ Michael P
Thanks man, I will certainly have a look at this and see if I can figure out what I'm doing wrong. (I'll likely go over it today or tomorow.)

GIDustin
18
Years of Service
User Offline
Joined: 30th May 2008
Location:
Posted: 21st Jun 2009 21:44 Edited at: 21st Jun 2009 21:49
@ Michael P

Still waiting for your voice commands release. I can't wait!

Until then I thought I would try to get UPnP working on my game, but the documentation doesn't state anywhere the steps to take. I downloaded the recent DarkNet (whatever is available as of 5 minutes ago) and "mn Start UPnP()" is not a valid command. It keeps thinking I mean "mn Start" but messed up the parameters...

Any chance you could look into that?

A happy customer
- GIDustin

Edit: NM. Found the UPnP "Demo" for the commands list, and needed to restart my editor for the commands to register. /facepalm
GIDustin
18
Years of Service
User Offline
Joined: 30th May 2008
Location:
Posted: 21st Jun 2009 22:27
New Problem. When running the UPnP demo on my computer, I get an error:

An error occurred in mnUpdateNat whilst retrieving current port mappings (NULL) at line 56....

Attached is a screenshot of my router stating that UPnP is enabled. Any ideas?

- GIDustin
Michael P
20
Years of Service
User Offline
Joined: 6th Mar 2006
Location: London (UK)
Posted: 21st Jun 2009 23:58
Universal Plug and Play is probably not enabled on your computer. On XP it isn't by default, and this guide shows how to enable it.

GIDustin
18
Years of Service
User Offline
Joined: 30th May 2008
Location:
Posted: 22nd Jun 2009 06:58
@Michael P

Followed the guide and got my UPnP to start working. Tried the UPnP demo again and it listed all the port maps on the router (31 of em) after about 15 seconds, but when it tried to add the new one it errored out:

adding a port map to the connection (!= S_OK)

Since there were several port maps already listed (Mostly X-Fire and World of Warcraft) I know that the connection works...

Any ideas?
Michael P
20
Years of Service
User Offline
Joined: 6th Mar 2006
Location: London (UK)
Posted: 22nd Jun 2009 10:40
Some routers reject port maps if the specified information is invalid e.g. the IP 192.168.1.5 may not be appropriate for your network. It is also possible that the local IP and port or external port are already in use.

Try changing the parameters of mnAddPortMap, that should solve the problem.

Alfa x
19
Years of Service
User Offline
Joined: 1st Jul 2006
Location: Colombia
Posted: 10th Aug 2009 22:43
Quote: "hehe cannot wait to update my game to use darknet, kinda scared to find any transitional problems though xD, it looks promising *waits for his order to go through... tick tock *
"


Quote: "You wont be disappointed.
"


Of course not.
Michael P
20
Years of Service
User Offline
Joined: 6th Mar 2006
Location: London (UK)
Posted: 27th Aug 2009 14:07
DarkNet website
There is now a website for DarkNet which is aimed at those considering whether or not to purchase DarkNet.

This website can be found at:
http://www.DarkNetworking.net

v1.1.6
v1.1.6 has recently become available and you can download it in your order history.

For more information on the latest version of DarkNet watch out for an article in the September TGC newsletter.

Moving from v1.1.4 to v1.1.6
This is relatively straightforward. By default, everything is the same as it was in v1.1.4 e.g. graceful disconnect is disabled.

You only have to worry about the following:
-mnGetTCPRecvSize has been renamed mnGetTCPRecvSizeA.
-mnGetErrorCode now returns long long int instead of int.
-mnGetErrorMode now takes an error mode parameter and is used to determine whether an error mode is on or off.
-mnConnect and mnPollConnect can now return -2 indicating that the server rejected the connection request. This normally means the server is full.
-mnSetFunction, the thread ID of function parameters is no longer passed by reference.

General
DarkNet has been optimised and restructured. There isn't much that hasn't improved in efficiency, so you should notice some kind of performance increase.

The documentation has been completely rewritten and is much more useful and easy to use.

The demo code has been updated and now includes 16 demo projects written in C++, DBP, C# and VB.NET.

There are also several bugs that have been fixed:
- Packet commands may not always display correct error message when there is not enough memory in packet to add or get data.
- Packets may not always have variables such as client ID set properly.
- Server/clients could not continue to transfer data in UDP mode 2 and 1 after 49.7 days of being connected.
- Vulnerability where certain situations could cause the server to display an error message or be unable to receive UDP data.
- mnFinish would not re-enable UDP on the specified instance.
- mnToggleAffinity, mnGetAffinity, mnSetAffinity, mnGetPriority and mnSetPriority were not working.

Improved Error System
You can now have more than one error mode enabled at the same time using mnToggleErrorMode. mnGetErrorMode has changed as a result.

Save error mode has improved so that you don't have to check the return values of commands to determine if an error has occurred. Instead you can use mnGetErrorFlag to determine when an error has occurred. You can use mnSetErrorFlag and mnClearErrorFlag to toggle error state and control what mnGetErrorFlag returns.

A clError (C++) and mnError (.NET) exception class now exists. When exception error mode (new) is enabled DarkNet functions will throw an exception of this type when an error occurs. The exception class is used internally to DarkNet; you now have the option to integrate your applications with the same error system that DarkNet uses. The documentation explains how to do this.

mnGetErrorMode now takes an error mode parameter and is used to determine whether an error mode is on or off.

There is demo code showing how to use the new error system.

Command list:


Packet Commands
Several new commands exist which make DarkNet packets more useful and dynamic.

mnErase can be used to erase a portion of the packet whilst mnInsert can be used to insert space into the packet, which can then be filled with an mnAdd command (e.g. mnAddInt).

A new command mnCreatePacketFromPacket exists which is faster than mnCreatePacket + mnEqualPacket. It has the same result as using those two commands.

There are several new string commands which operate similarly to their packet counterpart: mnCreatePacketFromString, mnComparePacketString, mnEqualPacketString.

mnChangeMemorySize can be used to change the memory size of a packet without wiping its contents (mnSetMemorySize wipes the contents of the packet).

mnAddMemblock and mnGetMemblock have been added for DBP users so that memblocks can be used with packets.

mnEncrypt now allocates new memory if not enough is available.

Command list:


Networking Commands
Several new networking commands have been added.

mnFlushRecvUDP and mnFlushRecvTCP can be used to empty the packet queue whilst mnGetTCPStoreAmount and mnGetUDPStoreAmount can be used to determine the number of packets in the queue. Note: packet queue refers to the queue of packets waiting to be received via mnRecvUDP or mnRecvTCP.

mnChangeBufferSizeTCP can be used to change the maximum possible size of an incoming TCP packet whilst the instance is active. This operates on a per client basis. mnGetTCPRecvSizeB exists to retrieve buffer sizes on a per client basis.

mnSetAutoResizeTCP can be used to set no limit on the maximum possible size of incoming TCP packet. The buffer size will increase as necessary. This operates on a per client basis.

mnGetTCPBytes is similar to mnGetTCPPercent except it retrieves the number of bytes worth of partial data (data that does not make up a complete packet).

mnDisableTCPHandshake can be used to disable the TCP handshake process. When this process is disabled DarkNet can communicate with applications not written with DarkNet. mnGetTCPHandshakeEnabled exists to check whether TCP handshake has been disabled.

mnSetTCPMode can be used to change the TCP mode to the new postfix mode which adds specified bytes of data to the end of each packet, and checks for these bytes at the end of incoming data to determine when a complete packet has been received. mnGetTCPMode exists to determine the TCP mode.

mnSetTCPPostfix can be used to set the postfix used with the postfix TCP mode. mnGetTCPPostfix exists to determine what the postfix is.

mnSetTCPMode and mnDisableTCPHandshake make communication via HTTP possible. Demo code exists to demonstrate this.

Graceful disconnecting is now possible using mnShutdownClient, mnEnableGracefulDisconnect and mnGetGracefulDisconnectEnabled. This allows clients to disconnect but data transfer to complete successfully.

mnSetSendTimeout and mnGetSendTimeout exist to protect the server from malicious clients. After the send timeout expires, if a packet has not been sent the client is forcefully dropped. This prevents blocking send operations from blocking permanently.

There is a new UDP mode (4) UM_CATCH_ALL_NO, UDP mode catch all, no out of order which is used in exactly the same way as UDP mode catch all but out of order packets are discarded.

All UDP modes now have procedures to ensure that data transfer can continue forever. Previously UDP modes 1 (per client) and 2 (per client, per operation) would stop working if a client did not disconnect after roughly 49.7 days.

mnDisableNagle and mnGetNagleEnabled can be used to disable the Nagle Algorithm which may improve TCP performance for some applications.

mnConnect and mnPollConnect can now return -2 indicating that the server rejected the connection request. This normally means the server is full.

Command list:


Firewall Commands
Roughly 90 new firewall commands have been added which allow full control over windows firewall.

Command list:


Sound Input/Output Commands
Roughly 50 new sound input/output commands have been added which allow sound data to be input, sent and played. This facilitates voice communication.

Command list:


HavokDelta6
16
Years of Service
User Offline
Joined: 22nd Aug 2009
Location: United Kingdom
Posted: 27th Aug 2009 20:10
I personally will be sticking with multisync, i think the TGC waited too long to jump on the networking bandwagon, same with the database plugin.

hope it works for you guys though

Oh i'll do it later -.-
kaedroho
18
Years of Service
User Offline
Joined: 21st Aug 2007
Location: Oxford,UK
Posted: 27th Aug 2009 20:45
You dont know what your missing...

HavokDelta6
16
Years of Service
User Offline
Joined: 22nd Aug 2009
Location: United Kingdom
Posted: 27th Aug 2009 21:03
i can take a guess though, and not that much... i mean multisync will do it, and well, i've got apps running on a few private servers, and its great

and considering Darkbasics multiplayer functions havnt worked since well they were integrated (i have 5.4 and updated it so may predate this)

i can assume its nothing to get exicted about. as that was like 2 years ago.

Oh i'll do it later -.-
KISTech
18
Years of Service
User Offline
Joined: 8th Feb 2008
Location: Aloha, Oregon
Posted: 28th Aug 2009 00:27 Edited at: 28th Aug 2009 00:31
The difference is DarkNet was developed by a 3rd party, as opposed to the DirectPlay that DBP has always had. DarkNet started out much like Multisync, and then more and more got added on until it became a full-featured networking library.

Picture Multisync with,

- TCP and UDP (I know Multisync has UDP now, but it didn't when I was using it.)
- 3 different UDP modes
- Packet encryption

and those are just the points that sold me on it. There's been a bunch more added since. That's not to say there's anything wrong with Multisync, far from it. At the time I was using it though, it was TCP only.

Quote: "same with the database plugin"


Which one?

HavokDelta6
16
Years of Service
User Offline
Joined: 22nd Aug 2009
Location: United Kingdom
Posted: 28th Aug 2009 01:12
ah sorry i thought this was an offical one

is this one free or? obvously i'd like to try before i buy if its not.

GCSE results:
2 a's 3 b's AND
5 (FIVE) a*'s ^_^
KISTech
18
Years of Service
User Offline
Joined: 8th Feb 2008
Location: Aloha, Oregon
Posted: 28th Aug 2009 01:37 Edited at: 28th Aug 2009 01:38
DarkNet is being sold through TGC, so it is official, but it's still a 3rd party plugin.

Check http://www.darknetworking.net. I don't think there's a free trial, but there is enough information on that site to satisfy whatever questions you might have.

Quote: "Quote: "same with the database plugin"

Which one?"


Nevermind, I missed the sticky for the new plugin.

OldPMan
TGC Store Seller
17
Years of Service
User Offline
Joined: 10th Aug 2008
Location:
Posted: 6th Dec 2009 19:18
a question ...
I noticed the impact.
the effect on the darknet SCREEN FPS ()

transmission packet does not affect the speed, impact inaction.
I personally, if I have:
if TcpPacket> 0
then 60fps
else
then 40fps or 30fps
WHY ?????????????????
endquestion



.....already beside..... for all
OldPMan
TGC Store Seller
17
Years of Service
User Offline
Joined: 10th Aug 2008
Location:
Posted: 6th Dec 2009 19:47 Edited at: 7th Dec 2009 23:54
i use:
Dark Data
DarkNet
Styx
Dark Shader
BlueGUI
EZrotate Enhanced
DarkBASIC Professional Enhancements Expansion Pack
Dark AI
Dark Physics
Dark Lights
matrix utility
Can any one of these plugins to influence the work DARKNET?

.....already beside..... for all
Michael P
20
Years of Service
User Offline
Joined: 6th Mar 2006
Location: London (UK)
Posted: 6th Dec 2009 21:11
It is probably the memblock commands causing the slow down.

OldPMan
TGC Store Seller
17
Years of Service
User Offline
Joined: 10th Aug 2008
Location:
Posted: 7th Dec 2009 08:06 Edited at: 7th Dec 2009 16:52
Hi Michael my English is very bad though sorry

you do not correctly understood me when a packet arrives and the condition
if TcpPacket> 0 then the number of frames 60
and when the condition is not satisfied staff drops to 30-40 fps.

ie when the darknet packages handled everything well, as soon as packages stopped coming speed drops to half.

For example:
I have no use darknet - 60FPS
with darknet during the transmission of packets on the LAN - 60FPS
with darknet without transmission of packet on the LAN - 30FPS (just TcpPacket = 0 and the result of the fall of fps half - :
)


edit:
I realized what was happening.
and the server and client were on the same computer.
I put NICE SLEEP 1, before the SYNC to the server and everything was fine.

Thank you very much Michael, I'm all happy


.....already beside..... for all
BubbleOne
16
Years of Service
User Offline
Joined: 5th Dec 2009
Location: Australia
Posted: 7th Dec 2009 14:17
How can I determine my external IP with DarkNet ?

Unlimited potential!
OldPMan
TGC Store Seller
17
Years of Service
User Offline
Joined: 10th Aug 2008
Location:
Posted: 9th Dec 2009 20:57 Edited at: 10th Dec 2009 09:24
I found that inside a function DARKNET an error A
TRANSITION "GOTO" and body "DO LOOP" everything works fine.
DARKNET NOT WORK inside a function?
WORKGOSUB)

NOT WORKFUNCTION)

SCRSHT

EDIT:
EXCUSE ME MY MISTAKE I have TIRED. YOU're RIGHT.
NOT GLOBAL VARIABLE RecvPacket /


.....already beside..... for all
Michael P
20
Years of Service
User Offline
Joined: 6th Mar 2006
Location: London (UK)
Posted: 9th Dec 2009 23:31
It is probably something to do with the packet parameter of mnRecvTCP, remember that DBP creates variables with no warning if they do not exist. So my guess is RecvPacket is not global.

Quote: "How can I determine my external IP with DarkNet ?"

I posted some code somewhere showing how to do this using Universal Plug and Play but unfortunately I can't find it , you use mnGetPortMapExternalIP.

This is a pretty unreliable way to do it, you are better to get a php script to tell you the IP and retrieve it using HTML. e.g. download www.whatismyip.com and extract the IP.

Alfa x
19
Years of Service
User Offline
Joined: 1st Jul 2006
Location: Colombia
Posted: 31st Dec 2009 00:05
@ HavokDelta6: There are many plug-ins developed by third parties, but the work "Dark", confuses people. Darknet started as MikeNet, later the TGC contacted Michael to sell DarkNet Thught them.

I can say to you without any fear to get wrong that DarkNet (MikeNet), is the best plug-in that you can find to networking in Darkbasic. (Faster also and more secure also)
SFSW
23
Years of Service
User Offline
Joined: 9th Oct 2002
Location:
Posted: 9th Feb 2010 05:58 Edited at: 9th Feb 2010 06:00
Posting this here is case it may help someone else (at least one other user had encountered the problem in this thread: http://forum.thegamecreators.com/?m=forum_view&t=157796&b=18 ). If you try to use the sound system in DarkNet, you may encounter this error when trying to setup/start the output device:

An error occurred in mnStartOutput whilst gaining access to an output device at line 117 of file ".\clOutputDevice.cpp". Error code 4.

It can occur intermittently and often only on certain systems. The problem seems to occur exclusively on systems with 5.1 audio. Regular stereo sound systems work fine, but if your PC has Dolby 5.1, you'll likely run into this crash. Until a work-around or fix is available, disabling 5.1 and setting your sound system to stereo will get things working again.

OldPMan
TGC Store Seller
17
Years of Service
User Offline
Joined: 10th Aug 2008
Location:
Posted: 11th Mar 2010 11:18 Edited at: 17th Mar 2010 09:49


.....already beside..... for all
GIDustin
18
Years of Service
User Offline
Joined: 30th May 2008
Location:
Posted: 18th Mar 2010 20:32
Michael,
Gonna keep this short as I am using my cellphone.
My game allows people to make custom maps. When joining a game using a map you dont have, the server will send it. I estimate the map sizes to about 3mb. I would also like a progress bar so all the players know you are downloading, much like starcraft/Warcraft 3. What would you suggest I use to send the file? I could pack it as one memblock, but then I don't have a way to access the progress. I could open the file and send byte by byte so I can do the math and work out a progress bar, but if multiple people are getting it at different speeds then I would have to jump around inside an open file which I haven't become comfortable with just yet.

Just wondering if you have any suggestions.

Thanks!

Michael P
20
Years of Service
User Offline
Joined: 6th Mar 2006
Location: London (UK)
Posted: 18th Mar 2010 20:45 Edited at: 18th Mar 2010 20:46
You can send the entire memblock and use mnGetTCPPercent or mnGetTCPBytes which will tell you how much of the packet that is currently being received has been received. These commands were introduced specifically for this sort of thing

GIDustin
18
Years of Service
User Offline
Joined: 30th May 2008
Location:
Posted: 18th Mar 2010 20:56
Quote: "You can send the entire memblock and use mnGetTCPPercent or mnGetTCPBytes which will tell y how much of the packet that is currently being received has been received. These commands wer introduced specifically for this sort of thing"


Awesome! That will help a lot.

And you could have just said "L2ReadDocumentation". :p

Login to post a reply

Server time is: 2026-06-13 01:41:00
Your offset time is: 2026-06-13 01:41:00