Jump to content
  • Advertisement


  • Content Count

  • Joined

  • Last visited

Community Reputation

120 Neutral

About rnw159

  • Rank
  1. Thanks for the answers, I somehow avoided learning this stuff in school. You've helped me out a lot with this work.
  2. Well I have maybe 20 external libraries in this project. Is there any easy way to get already compiled libraries for other platforms? It takes ages to compile these libraries, and the ones that compile fast are always the hardest to use a cross compiler with.
  3. Thanks for the info. Back to the ARM compile for a second: Say the program uses Boost, will I need to recompile Boost under ARM (or a toolchain)? Or will I be able to compile the whole project using the version of boost already compiled and used in the project?      Thank you so much for the thorough response.
  4. So I'm trying to cross compile a large project on Ubuntu x86 for ARM unix and windows x86.    Questions:   For the ARM cross compile I have to compile all of the libraries it uses seperatly before using a toolchain to compile the whole project right? If not whats the proper procedure?   For the windows compile do I need to recompile all the libraries? Or will it be fine because its using the same cpu architecture?   What will a change in os mean for the work I have to do?   What will a change in cpu architecture mean?   What will a change in both mean?   Thank you for your help.
  5. This was the first encryption software I ever made. I make games more often. I made it for a friend who wanted it real fast and couldn't tell any better. One of the reasons I don't post here very often is that when I do, I always get some guy who knows the area 100x better than I do and shoots down my work. Also, I just realized that the code is in the rar file. I did not mean to put it there.
  6. Just realized that it may look strange to ask people to run an exe file just like that. So can one brave person run it, then post proof that it is safe?
  7. A friend asked me for a file encrypter a while ago, so I wrote one in console. He just told me that it has been really useful for him and I should consider giving it to other people. It just asked you to drag and drop the file on the screen, and it encrypts it with a key you can use to decrypt it from the same program. Anyway, it is rar'd with this post if you want it. [attachment=6713:Encrypt.rar]
  8. One cause may be if you're sending many small messages over TCP, they may not actually be transmitted until the outgoing stream buffer is of a certain size. setsocketopt - Check out TCP_NODELAY [/quote] Thanks this helped a lot! The problem I have now is that if I continually send data the lag gets greater and greater until I stop sending data for a few seconds. CAn you offer some help on this? *edit* Also it gets twice as laggy for every client I add. Any suggestions?
  9. I'm using non blocking because I'm sending game data. If select is what I need then I will look into it. Thanks! *edit* I have a new problem. The program works great in terms of successfully sending information. However, there is about a 10 second lag when I'm trying to send realtime information. This is being sent over local The server takes a long time to send the data after it has been received. and the client takes a long time to send the data to the server.
  10. Wow thanks, there are no tutorials for this anywhere. Is this method 100% reliable. I don't understand the part about reading each byte by the integer representing it. Can someone elaborate?
  11. Thanks thats great! Do you know any examples of this implementation? CAn I see some source code?
  12. void send(){ PlayerPosPacket packet; packet.x = x; packet.y = y; packet.player = id; //char szBuffer[1024]; //SendData((char const *)&packet); send(mySocket,(char const*)&packet,sizeof(packet),0); //send(mySocket, buffer, strlen( buffer ), 0 ); ZeroMemory(&packet, sizeof(packet)); } void recv(){ PlayerPosPacket recvPacket; int r = recv( mySocket, (char *)&recvPacket, sizeof(recvPacket ), 0); textprintf_ex(screen,font,0,0, makecol(0,255,0), -1, "x %d", recvPacket.x); if(r > 0){ x2 = recvPacket.x; y2 = recvPacket.y; textprintf_ex(screen,font,0,0, makecol(0,255,0), -1, "x %d", recvPacket.x); //ZeroMemory(&recvPacket, sizeof(recvPacket)); //allegro_message("here"); }else{} } The above code attempts to send the struct to another multi-client server I wrote. The server takes the data from one person and sends it to every other person except the one who send it in the first place. The problem is that I never receive the data I need to receive. I always receive either 0, or some other random number like 675390. Is there something wrong with my char* to struct. Please help me find the problem and fix it. It may be that I am missing some fundamental c++ skill that I somehow overlooked. (Although it is unlikely) *edit* What would be nice is an example of a client and a server sending a struct and then viewing the information. forgot to mention, this is nonblocking.
  13. Alright I tried all of your suggestions and non of them had any effect. The program always works fine until winsock2 is linked. Then, even when it is taken out, the problem persists. *edit* Alright, I just found out that my compiler is compiling it with: g++.exe -D__DEBUG__ maindawdaw.o -o "Project2.exe" -L"C:/Dev-Cpp/lib" -L"C:/SDL-1.2.14/lib" ../../lib/libws2_32.a -g3 -mwindows The obvious problem here is the -mwindows. How can I get it to compile without -mwindows? *edit* Manually changing the settings to console don't work. On compile the settings revert back to -mwindows.
  14. It's probably the case that your cout stream is not being flushed. Try printing to cerr instead, and try using std::endl instead of embedding a "\n" character -- Windows end line may not be \n alone. Another option is that you're building as a "win32 application" rather than a "console application" -- check your linker settings. Finally, console applications have to be started from the console/command line, rather than from within the debugger or the Explorer. Else they won't have the proper interactive TTY setup. (This is an oversimplification -- but for now, do it that way or you'll go crazy!) This has nothing to do with networking, btw. [/quote] Thanks, I will try that. I know the only correlation between this and networking in winsock2, but I thought this might be a problem that you had experienced before because people answering on this forum have probably used that library for a while.
  15. First I was using vc++. The program I showed earlier was made using dev to see if changing compilers would fix the problem.
  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!