Raknet 3.7

BlitzMax Forums/Brucey's Modules/Raknet 3.7

Zeke(Posted 2009) [#1]
Hi. any possibility to update bah.raknet module to the newest 3.7 version?

this is my "modified" bah.raknet module, using raknet version 3.7 (latest)

i changed some methods because i wanted module use bitstreams like blitzmax:
bitstream.readint(variable) => variable=bitstream.readint()

also write/readstring didint work... so i made own methods...

and added:

Function GetRakNetVersion:Int()
Return bmx_GetRakVersion()
End Function

^^ function returns current raknet version*1000 (now: 3700)


but anyway.. this is only my modifications what i want to use...

here is my modified bah.raknet module: http://www.byrathon.com/raknet.rar

also small video where im using raknet: http://www.byrathon.com/npctest.wmv
(i dont want put this video to showcase because this is so early testing...)


Brucey(Posted 2009) [#2]
any possibility to update bah.raknet module to the newest 3.7 version

3.7 already? :-p
(It's a constantly moving target!!)

i changed some methods because i wanted module use bitstreams like blitzmax

Yes, it was a tough choice I made to structure it the way I did. The reason was that I wanted to keep the error handling available. Unfortunately, BlitzMax doesn't support optional Var parameters, which would have been my preferred method of implementing it.

A version function is very useful :-)


I'll see about updating soon.
Hopefully I won't find any new bugs to report to him this time - which is always a hassle, since I tend to think code that isn't working is more likely mine, rather than theirs... which means it usually takes much longer to track a bug down (as I'm testing the wrong code!)

Anyway... looks like nice game :-)


Zeke(Posted 2009) [#3]
cool.. also autopatcher system looks so cool and if that can be made to bmax module.... :P


Zeke(Posted 2009) [#4]
Updated to 3.712 version..
Note: This version is not network compatible with 3.7051 or earlier due to reordering of packet enumerations.
also added GetRakNetProtocolVersion() function...

http://www.byrathon.com/raknet_mod_3712.zip


(this is PURE raknet source copy) so if there was some Bruceys c++ code modifications.. they are gone.. but this is working..)

i hope brucey take a look for this mod.. and make official update... because this works pretty well.. :D


Stu_ovine(Posted 2009) [#5]
Excellent thanks.

But can I point out an outstanding error with the wrapper which hasnt received a comment yet. (http://www.blitzbasic.com/Community/posts.php?topic=82901#992079)


Zeke(Posted 2009) [#6]
hmm.. ok.. i will check that right now...


Stu_ovine(Posted 2009) [#7]
Can you see the error ?

:)


Zeke(Posted 2009) [#8]
ok. here is latest 3.713 version of bah.raknet
i think longs are working now.
also i made a new client/server example to /examples folder.

so here it is: http://www.byrathon.com/raknet.zip


Stu_ovine(Posted 2009) [#9]
That seems to have cured the LONG problem, but, you seem to have removed the string write functions from the update ?


The RAKNET docs recommend we use EncodeString and DecodeString it wuld be nice to have those wrapped too.

Your work is appreciated :)


Zeke(Posted 2009) [#10]
yea. i reverted back to bruceys svn source, and updated that to the latest raknet version. thats why there is no string functions..

i need more testing about strings.. i got it working and i used RakNet::RakString.. but there is some weird bugs, that need to be solved..


Stu_ovine(Posted 2009) [#11]
I see, In the meantime Ive copied Bruceys' old code in which is working ok. It not the efficient way but at least it works.

Its nice to have LONG working :) thanks.


Zeke(Posted 2009) [#12]
brucey can you take some time and look this my "updated" module... my modified module is similar just like you but its using latest 3.713 version and my 2 getraknetversion commands...if this is so "stable" to to your bah.raknet module..

i know there is still some things to work.. but.. your svn is outdated


Galaxy613(Posted 2010) [#13]
I'm looking to use RakNet for a project of mine, which version should I use, Brucey's or the one in your latest post Zeke?


Zeke(Posted 2010) [#14]
well i have updated bruceys module to the latest. 3.717... right now b's version is 3.611..

http://www.blitzmax.com/Community/posts.php?topic=88526#1005367 <= here is my latest "dev" version..


Zeke(Posted 2010) [#15]
ok. i have been updated latest module (bah.raknet) and you can get it from here: http://www.byrathon.com/raknet.zip (3.717)

Changes:
Added: WriteString/ReadString functions.

(and also write0/1 works too.. im no sure what was problem with reading bits earlier...)


Brucey(Posted 2010) [#16]
Is Read/Write Long working ok?

I also updated the client/server example to work with Unicode text messages. The examples tend to require CEGUI module for the nice dialogs.


Zeke(Posted 2010) [#17]
yep, Longs are ok..


VicToMeyeZR(Posted 2010) [#18]
Trying to build off this.

Building source
Compiling:_FindFirst.cpp
Build Error: failed to compile C:/BlitzMax/mod/raknet.mod/src/_FindFirst.cpp
Process complete


Any thoughts as to why the mod won't compile?

I have minGW installed.


VicToMeyeZR(Posted 2010) [#19]
And this is on my other computer

Building raknet
Compiling:_FindFirst.cpp
Compiling:WSAStartupSingleton.cpp
Compiling:AsynchronousFileIO.cpp
Compiling:AutoRPC.cpp
Compiling:BigInt.cpp
Compiling:BitStream_NoTemplate.cpp
Compiling:BitStream.cpp
Compiling:CheckSum.cpp
Compiling:CommandParserInterface.cpp
Compiling:ConnectionGraph.cpp
Compiling:ConnectionGraph2.cpp
Compiling:ConsoleServer.cpp
Compiling:DataBlockEncryptor.cpp
Compiling:DataCompressor.cpp
Compiling:DirectoryDeltaTransfer.cpp
Compiling:DS_BytePool.cpp
Compiling:DS_ByteQueue.cpp
Compiling:DS_HuffmanEncodingTree.cpp
Compiling:DS_Table.cpp
Compiling:EmailSender.cpp
Compiling:EncodeClassName.cpp
Compiling:EpochTimeToString.cpp
Compiling:ExtendedOverlappedPool.cpp
Compiling:FileList.cpp
Compiling:FileListTransfer.cpp
Compiling:FileOperations.cpp
Compiling:FormatString.cpp
Compiling:FullyConnectedMesh.cpp
Compiling:FullyConnectedMesh2.cpp
Compiling:FunctionThread.cpp
Compiling:Gen_RPC8.cpp
Compiling:GetTime.cpp
Compiling:gettimeofday.cpp
Compiling:GridSectorizer.cpp
Compiling:HTTPConnection.cpp
Compiling:IncrementalReadInterface.cpp
Compiling:InlineFunctor.cpp
Compiling:Itoa.cpp
Compiling:LightweightDatabaseClient.cpp
Compiling:LightweightDatabaseCommon.cpp
Compiling:LightweightDatabaseServer.cpp
Compiling:LinuxStrings.cpp
Compiling:LogCommandParser.cpp
Compiling:MessageFilter.cpp
Compiling:NatPunchthroughServer.cpp
Compiling:NatPunchthroughClient.cpp
Compiling:NetworkIDManager.cpp
Compiling:NetworkIDObject.cpp
Compiling:PacketConsoleLogger.cpp
Compiling:PacketFileLogger.cpp
Compiling:PacketizedTCP.cpp
Compiling:PacketLogger.cpp
Compiling:PluginInterface.cpp
Compiling:PluginInterface2.cpp
Compiling:RakMemoryOverride.cpp
Compiling:RakNetCommandParser.cpp
Compiling:RakNetSocket.cpp
Compiling:RakNetStatistics.cpp
Compiling:RakNetTransport.cpp
Compiling:RakNetTransport2.cpp
Compiling:RakNetTypes.cpp
Compiling:RakNetworkFactory.cpp
Compiling:RakPeer.cpp
Compiling:RakSleep.cpp
Compiling:RakString.cpp
Compiling:RakThread.cpp
Compiling:Rand.cpp
Compiling:ReadyEvent.cpp
Compiling:ReliabilityLayer.cpp
Compiling:ReplicaManager.cpp
Compiling:ReplicaManager2.cpp
Compiling:rijndael.cpp
Compiling:Router.cpp
Compiling:RPCMap.cpp
Compiling:RSACrypt.cpp
Compiling:SHA1.cpp
Compiling:SimpleMutex.cpp
Compiling:SocketLayer.cpp
Compiling:StringCompressor.cpp
Compiling:StringTable.cpp
Compiling:SuperFastHash.cpp
Compiling:SystemAddressList.cpp
Compiling:TableSerializer.cpp
Compiling:TCPInterface.cpp
Compiling:TelnetTransport.cpp
Compiling:ThreadsafePacketLogger.cpp
Compiling:UDPForwarder.cpp
Compiling:UDPProxyClient.cpp
Compiling:UDPProxyCoordinator.cpp
Compiling:UDPProxyServer.cpp
Compiling:VariadicSQLParser.cpp
Compiling:SendToThread.cpp
Compiling:SignaledEvent.cpp
Compiling:CCRakNetUDT.cpp
Compiling:getversion.cpp
Compiling:glue.cpp
Compiling:source.bmx
flat assembler  version 1.68  (1443283 kilobytes memory)
3 passes, 2157 bytes.
Compiling:common.bmx
flat assembler  version 1.68  (1443633 kilobytes memory)
3 passes, 13323 bytes.
Compiling:raknet.bmx
Compile Error: Module does not match commandline module
[C:/BlitzMax/mod/raknet.mod/raknet.bmx;26;19]
Build Error: failed to compile C:/BlitzMax/mod/raknet.mod/raknet.bmx
Process complete



VicToMeyeZR(Posted 2010) [#20]
Brucey..

I get that error with every single mod you have on your svn.

I copied all the mods to mod/bah.mod/modname.mod

whats going on here?


xlsior(Posted 2010) [#21]
Any thoughts as to why the mod won't compile?

I have minGW installed.


Did you install it *properly*?

- Can you rebuild *any* mods?
- what happens if you open a command prompt, and type the following:
gcc -v

Do you see any version information, or did you get a 'bad command or filename'?
- What OS are you running? Under Vista/Windows 7 the MinGW installation requires a few more steps than it did under XP to function properly


Brucey(Posted 2010) [#22]
If you have a look at the first post in this thread it mentions setting some Environment Variables - so that BlitzMax can find the MinGW installation.

:-)


VicToMeyeZR(Posted 2010) [#23]
ON my home computer, which is the second post, the MinGW does work correctly. My XP laptop, does not for some reason.

I actually found out that you have to use the "Build Modules" button, not the build file button (on my own I might add) since that little tidbit of information isn't found anywhere (yes I searched, and searched) This is probably why not to many new people pick up on this system. (Not your fault though...)

BTW thanks for all your great mods.

as an FYI. the raknet in your google SVN is still version 1.0
also, the CEGUI from the SVN gets an "EXCEPTION_ACCESS_VIOLATION" on the build modules command.

Again, thanks. I seem to have the idea now.


VicToMeyeZR(Posted 2010) [#24]
where did the mod go?