PDA

View Full Version : Need help with indy 10



Diaboli
18-11-2006, 07:22 PM
I got BDS 2006, with the Indy 10 component package.

I am trying to use this to make my game, but i cant figure out how to make a function that automatically takes incomming data and runs packet-prosessing function.

I tried using a unending loop and using the idAntiFreeze component, but it didnt work (it froze anyway :P)

I then tried using the antifreeze when i wouldnt get any responce (to test if it worked, silly) and it didnt.

Does anyone have a solution for this? i know many ppl use the indy components, so somebody must have some smart way of handling this?

XTRiZ
18-11-2006, 09:46 PM
Hi,

try creating the indy objects in a separate thread, then it wouldn't freeze everything. Done a couple of things with Indy10, and it seems to work as it should.

rgds,
Peter

Diaboli
19-11-2006, 05:20 PM
eh.. can you give me an example?

I dont know how to make new threads, and havent seen any examples how to do it.. (i learn most of my programming from examples and trial and error)

jdarling
20-11-2006, 12:47 PM
Everything you wanted to know about threads:
http://eonclash.com/Tutorials/Multithreading/MartinHarvey1.1/ToC.html

Gotta love Martin Harvey's tutorial :)