you probably put an integer value for the position since in the end it will be represented by an integer value (pixels) anyways, but that compromises any accuracy if you take many little steps so just use floats.
the pixel yeah but not the position
you need to keep the exact position because you keep on calculating with it it get very inaccurate if you round it.
so fix it to draw but not the position itself
get it?
if not tell me I will explain better after getting some sleep it is 4:20 in the morning and I am drunk....
I never did an precalc on sin and cos does it speed things up a lot?
well you check it all 18 ticks?
1000 ticks is one second, so just put some kind of sub into you loop going like this
VB Code:
function fps() as string
static framesPS
static lasttic as long
static count as long
count = count
if lassttick < GetTickCout then
lasttick = GetTickCount +1000
framesPS = count
count = 0
endif
fps = str(framesPS)
end function
(you can do it much better than that here but that should work and give you fps that don't change around all the time but only once a second.... (and than they will be more consistent too))
well here some little recent discussion about Frames per second measurement...
you can go for Zaeis version too, or use the code I gave in the other thread, it does not use statics, but it is in the loop so it's kind of the same thing. (one var less though because I made it a function and not just write to a global var this time)
now for my last question , if u dont mind , and its about tcp/ip connection.
i want that the remote computer will update data in real time
i mean , if the remote computer moved , i want the local computer to know without lag , which means i need to transmirt X,Y of the sprite about 30-40 times a second , is it possible ?
yeah it should be possible over network (internet also) but you will never be safe from lagging... you should ask in a new thread to get more qualified answers! (I really know crap about networking.)