Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Recent content by hardkor1001110

  1. hardkor1001110

    Remove Spaces from integers

    for saving Integers it is much cleaner to open the file in BINARY mode and use PUT to store the data, which just lumps the data unformatted into the file and expects you to know the byte length of the individual pieces of data you store and read them in correctly. WRITE formats the file for you...
  2. hardkor1001110

    When two pics hit

    No matter how you decide to handle the raindrops, you will be running through a loop, right? And at some point you will be creating a rain drop with a size and velocity, color, or whatever. It is simple to calculate how many times the raindrop will need to be advanced downward before it hits the...
  3. hardkor1001110

    When two pics hit

    guess I wasn't very clear. I meant discarding the check all together. :) I know this is ridicously complex for the given problem, but I like to learn new ways of constructing dynamic routines without the use of IFs... Say you have a constant number of raindrops in the game and you measure time...
  4. hardkor1001110

    When two pics hit

    looks like a good idea to me. I forgot about needing to check if the raindrops went off the screen. I wonder if a simple algorithim could be used to assign a life to each raindrop which would allow it to live only to the bottom of the screen or slightly below (if you can PSET off the screen, I...
  5. hardkor1001110

    When two pics hit

    actually I meant to say subtract 1 from the Y coordinate when you hit the first non zero point. but there is a "gotchya", that will only work if you increment your raindrops by 1 downward each loop, which I'm guessing you're not doing if the game is in an old style. you can just find...
  6. hardkor1001110

    When two pics hit

    hmm, I don't know the most efficient way to do this but here's one that I think might be pretty good: put Chubby in a black box that's a litte taller than him so theres some room above his head but only one pixel wider on either side. then scan down with a for loop starting at the upper left...
  7. hardkor1001110

    Sine, Cosine, Tangent

    sorry are you trying to get the inverse cos, tan or sin? you can get an inverse tangent with theta=radians f = ATN(TAN(theta)) f = f * (180/PI)
  8. hardkor1001110

    Sine, Cosine, Tangent

    Sounds like you just need to convert the angle to radians, which is what those functions accept - theta = (angle / (180/PI)) COS(theta)
  9. hardkor1001110

    Skinnable project

    I made a near perfect clone of the MSN Explorer with less than 10 hrs work using bitmaps. You can use a Timer with the WindowFromPt API to to trigger hover events and the Picture_MouseDown events to handle your clicks. You can use a borderless form and the SendMessage API to simulate a click on...
  10. hardkor1001110

    Need a way to speed up QBasic

    hmm... i'd make a test program that just reads or writes with buffers so you can get the hang of it first before trying to use them to do anything. the PRINT statements in your loop will also slow it down a LOT. you can read in any kind of variable of any size from disk. just think of it as a...
  11. hardkor1001110

    Need a way to speed up QBasic

    wait a sec - forget that RTRIM thing. I just pulled that out of nowhere, it would work for data that has no " ", which is usually what I'm working with, but is not a good idea for random data or your typical program data..
  12. hardkor1001110

    Need a way to speed up QBasic

    after reading logiclrd's post you should have a better idea why the code is slow. if you don't understand here's a simplified buffer: BUFFER$ = STRING$(4096, 48) GET #1,, BUFFER$ BUFFER$ = RTRIM$(BUFFER$) which would bring in 4096 bytes from disk much much faster than reading it in one byte...
  13. hardkor1001110

    get computer name from user name (or other way around)

    hmm... so do you have admin priveleges? if not use SESSION_INFO_10. check on MSDN to make sure you have the right structure for this type. yes it did work, but not 100%, it was mixed from machine to machine, which I think has something to do with what domain you're running on, our network has...
  14. hardkor1001110

    Pixel Color

    you should give the man a star for that one. thanks here too strong... I can use that too. I'll still just read the bytes from disk for 24 bit bmps though.
  15. hardkor1001110

    get computer name from user name (or other way around)

    strongm answered this question for me here: thread222-92023 The technique works well when you have Administrative priveleges but if you don't and you have to use session 10 then the results were mixed on our network, which is a statewide WAN, but maybe you'd have better success if you're on a...

Part and Inventory Search

Back
Top