irrNetLite 2.1 [BETA]
I hope I'll find some time during the next week or so to create a test application for that problem. Maybe I'll just modify one of the examples.
I think I didn't add "USE_IRRLICHT". Have to try that .
I think I didn't add "USE_IRRLICHT". Have to try that .
Dustbin::Games on the web: https://www.dustbin-online.de/
Dustbin::Games on facebook: https://www.facebook.com/dustbingames/
Dustbin::Games on twitter: https://twitter.com/dustbingames
Dustbin::Games on facebook: https://www.facebook.com/dustbingames/
Dustbin::Games on twitter: https://twitter.com/dustbingames
Good evening!
I got a pretty strange runtime error with irrnetlite. That occurs when at the end of the scope the SOutPacket is automatically deallocated. More specifically, i get pointed to the destructor of core::array, which is one of its members - haven't yet figured out why it segfaults.
Has anyone had the same issue before? I am using irrlicht 1.6 and the (latest?) irrnetlite version - as offered in the very first post of this thread.
Thanks for any suggestions & cheers,
p.
I got a pretty strange runtime error with irrnetlite. That occurs when at the end of the scope the SOutPacket is automatically deallocated. More specifically, i get pointed to the destructor of core::array, which is one of its members - haven't yet figured out why it segfaults.
Has anyone had the same issue before? I am using irrlicht 1.6 and the (latest?) irrnetlite version - as offered in the very first post of this thread.
Thanks for any suggestions & cheers,
p.
beer->setMotivationCallback(this);
Are you using the .lib version or including the files into the project manually?polylux wrote:Good evening!
I got a pretty strange runtime error with irrnetlite. That occurs when at the end of the scope the SOutPacket is automatically deallocated. More specifically, i get pointed to the destructor of core::array, which is one of its members - haven't yet figured out why it segfaults.
Has anyone had the same issue before? I am using irrlicht 1.6 and the (latest?) irrnetlite version - as offered in the very first post of this thread.
Thanks for any suggestions & cheers,
p.
ShadowMapping for Irrlicht!: Get it here
Need help? Come on the IRC!: #irrlicht on irc://irc.freenode.net
Need help? Come on the IRC!: #irrlicht on irc://irc.freenode.net
I had the same problem but didn't solve it. I created a workaround by exchanging the dynamic buffers (irr::array) by a static one (4k ... way more than I need). Works good ever since.polylux wrote:Good evening!
I got a pretty strange runtime error with irrnetlite. That occurs when at the end of the scope the SOutPacket is automatically deallocated. More specifically, i get pointed to the destructor of core::array, which is one of its members - haven't yet figured out why it segfaults.
Has anyone had the same issue before? I am using irrlicht 1.6 and the (latest?) irrnetlite version - as offered in the very first post of this thread.
Thanks for any suggestions & cheers,
p.
Dustbin::Games on the web: https://www.dustbin-online.de/
Dustbin::Games on facebook: https://www.facebook.com/dustbingames/
Dustbin::Games on twitter: https://twitter.com/dustbingames
Dustbin::Games on facebook: https://www.facebook.com/dustbingames/
Dustbin::Games on twitter: https://twitter.com/dustbingames
The problem may be that you built the static library with the irrArray.h that came with irrNetLite, but used it with Irrlicht with the irrArray.h that came with Irrlicht, similar to having the incorrect Irrlicht DLL/header files situation. You can try to rebuild irrNetLite with USE_IRRLICHT defined (Remember to include the Irrlicht headers and delete irrArray, string, etc that came with irrNetLite to be sure).polylux wrote:I built a static library with the included makefile. Plus I just found out that it behaves weird, like randomly sent/received data. Gotta have a look at that...
I hope that explains it a little better.
ShadowMapping for Irrlicht!: Get it here
Need help? Come on the IRC!: #irrlicht on irc://irc.freenode.net
Need help? Come on the IRC!: #irrlicht on irc://irc.freenode.net
Shame on me. I played around a little bit yesterday and it turned out that there were some pointers I didn't NULL out after deleting the objects, and therefore they were pointing at garbage. The debugger didn't really help me there . I can now re-start the server without problems, but as soon as I do a restart I am no longer able to connect to it.
I also tried that with one of the Examples and VC, same behaviour there. I added a key to the server that would simply delete the two objects that are also deleted before exiting the program and immediately re-create them. No crash on the server, but I couldn't connect to the server any more.
I also tried that with one of the Examples and VC, same behaviour there. I added a key to the server that would simply delete the two objects that are also deleted before exiting the program and immediately re-create them. No crash on the server, but I couldn't connect to the server any more.
Dustbin::Games on the web: https://www.dustbin-online.de/
Dustbin::Games on facebook: https://www.facebook.com/dustbingames/
Dustbin::Games on twitter: https://twitter.com/dustbingames
Dustbin::Games on facebook: https://www.facebook.com/dustbingames/
Dustbin::Games on twitter: https://twitter.com/dustbingames
Another question I have: is there a way to get the IP address of the server using irrnetlite or enet functions? I want to display the server's IP address on the "start net game" screen.
Dustbin::Games on the web: https://www.dustbin-online.de/
Dustbin::Games on facebook: https://www.facebook.com/dustbingames/
Dustbin::Games on twitter: https://twitter.com/dustbingames
Dustbin::Games on facebook: https://www.facebook.com/dustbingames/
Dustbin::Games on twitter: https://twitter.com/dustbingames
@Brainsaw this is hardly possible because a server can have multiple IPs. Dont know if enet supports it to query this infos.
Finally irrNetLite made it in the networklibsbenc test.
A new version (0.6) of this test: http://sourceforge.net/projects/networklibsbenc/
Some new testresults: http://sourceforge.net/apps/gallery/networklibsbenc/
Finally irrNetLite made it in the networklibsbenc test.
A new version (0.6) of this test: http://sourceforge.net/projects/networklibsbenc/
Some new testresults: http://sourceforge.net/apps/gallery/networklibsbenc/
-
- Posts: 1186
- Joined: Fri Dec 29, 2006 12:04 am
Something like this?Brainsaw wrote:is there a way to get the IP address of the server using irrnetlite or enet functions?
Code: Select all
char hostip[16];
enet_address_get_host_ip(&serverAddress, hostip, 16);
printf("%s\n", hostip);
I have a similar wrapper class to ENetPackets and my method for adding e.g. an integer to the packet is like this:
Code: Select all
void Message::addUnsignedInt(const unsigned int ui)
{
const size_t tokenSize = sizeof(unsigned int);
if (dynamicResize(tokenSize) < 0)
return;
unsigned int* const ui_ptr = (unsigned int* const)(&this->packet->data[this->read_write_head]);
*ui_ptr = ENET_HOST_TO_NET_32(ui);
this->read_write_head += tokenSize;
}
Does either the irrlicht array or your operators take care of this?
"Whoops..."
Hmm .. I tried the suggestions yesterday, and I still got "0.0.0.0" as IP address of the server. Still ... I got my computers name ("Bebop" on my Desktop and "DarkStar" on my Notebook). I there a way in irrnetlite or enet to get the IP address from the computer name? Thanks for your help.
Dustbin::Games on the web: https://www.dustbin-online.de/
Dustbin::Games on facebook: https://www.facebook.com/dustbingames/
Dustbin::Games on twitter: https://twitter.com/dustbingames
Dustbin::Games on facebook: https://www.facebook.com/dustbingames/
Dustbin::Games on twitter: https://twitter.com/dustbingames
-
- Posts: 1186
- Joined: Fri Dec 29, 2006 12:04 am