Page 2 of 2 FirstFirst 12
Results 41 to 65 of 65

Thread: Anyone want to make a few tutorials ?

  1. #41
    Fanatic Member MoMad's Avatar
    Join Date
    Oct 2000
    Location
    Seattle, WA
    Posts
    625
    zlib can be found here:

    http://www.gzip.org/zlib/

    They will tell you what it is and what it does. And if you want a precompiled lib file just use the one in my filepack example up above
    :MoMad:
    Nice Sig!

    http://go.to/momad/ Status: Not Ready

  2. #42
    Frenzied Member ice_531's Avatar
    Join Date
    Aug 2002
    Location
    Sitting w/ Bob Status: -Next -To- Null- Friend: Philip
    Posts
    1,152

    Way to go!!!

    How bout takin a page from the kpd team (api-guide)
    make a graphics guide lol

    jus my lil suggestion better than reading a tutorial
    :::`DISCLAIMER`:::
    Do NOT take anything i have posted to be truthful in any way, shape or form.
    Thank You!

    --------------------------------
    "Never heard about "hiking" poles. I usualy just grab a stick from the nature, and use that as a pole." - NoteMe
    "Finaly I can look as gay as I want..." - NoteMe
    Languages: VB6, BASIC, Java, C#. C++

  3. #43
    Kitten CornedBee's Avatar
    Join Date
    Aug 2001
    Location
    In a microchip!
    Posts
    11,594
    If you want to change the bmp format so normal bmp viewers can't read it simply use another "magic number". ALL bmp files start with the number 'BMP ', so just change that to e.g. 'CMP ' and no normal image viewer will open the file.

    Of course this is extremly easy to hack. You could do it in a text editor.
    All the buzzt
    CornedBee

    "Writing specifications is like writing a novel. Writing code is like writing poetry."
    - Anonymous, published by Raymond Chen

    Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.

  4. #44
    Fanatic Member petrus's Avatar
    Join Date
    May 2002
    Location
    pBytes[sizeof(pBytes)/2]
    Posts
    553
    When i make games, i use a Main Loop, that loops once a milliesecond or something, and that loop could look like this:

    VB Code:
    1. 'Inside Main Loop:
    2. MovePlayer 'Sub that moves the player
    3. MoveObjects 'Sub that moves objects like bullets.
    4.  
    5. DrawObject 'Sub that draws the objects on a buffer
    6. DrawPlayer 'Sub that draws the player on a buffer
    7.  
    8. FlipBuffers 'Sub that makes BackBuffer to FrontBuffer

    And the MoveObject's sub could look like this:

    VB Code:
    1. 'Inside MoveObject Sub:
    2.  
    3. for i = 1 to UBound(GameObjects)
    4. GameObjects(i).X = GameObjects(i).X + GameObjects(i).speed
    5. next

    A speed that is positive will make the object move to the right, negative will move it to the left.
    ICQ: 128716725

  5. #45
    Addicted Member
    Join Date
    Dec 2001
    Location
    Great White North, ey?
    Posts
    202

    Wink

    Originally posted by CornedBee
    If you want to change the bmp format so normal bmp viewers can't read it simply use another "magic number". ALL bmp files start with the number 'BMP ', so just change that to e.g. 'CMP ' and no normal image viewer will open the file.

    Of course this is extremly easy to hack. You could do it in a text editor.
    I could do that, only make my file names so confusion that people won't know that file it is some thing like: "22034ffr4200.sndp" which would actually be a texture, although it is easy to open it if you know it's a picture file, just use the "open with" screen that comes up when you try to open a file with a strange ending, lol.

  6. #46
    Kitten CornedBee's Avatar
    Join Date
    Aug 2001
    Location
    In a microchip!
    Posts
    11,594
    I mean something slightly different. If you open a bmp in a text editor, the first 2 bytes will be BM, which is the so-called "magic number". Since the file ending is by no means a real information what kind of file this is, all files (or nearly all) have some signature that marks them as being what they are. If you change this to, for example, CN, no image viewer will open the file except yours, which knows what to expect.
    e.g. one of the bitmaps that comes with windows begins like this:
    BM¸C...

    If you change this to

    CN¸C...
    PSP will give you this error message: "This is not a valid BMP/DIB/RLE file".

    But since there is no actual information stored in these two bytes you can simply ignore them and load the file anyway.
    All the buzzt
    CornedBee

    "Writing specifications is like writing a novel. Writing code is like writing poetry."
    - Anonymous, published by Raymond Chen

    Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.

  7. #47
    Fanatic Member MoMad's Avatar
    Join Date
    Oct 2000
    Location
    Seattle, WA
    Posts
    625
    Take a look at the filepack class up above... it will accomplish the same task as zipping a file. And its very fast... so you can pack an entire folder to a single file (0AE987C4D.bla) or whatever...
    :MoMad:
    Nice Sig!

    http://go.to/momad/ Status: Not Ready

  8. #48
    Addicted Member
    Join Date
    Dec 2001
    Location
    Great White North, ey?
    Posts
    202

    Red face

    Ok, I have a picture where I changed the BM beginning to BMWX5, but I use the LoadPicture method to load in a picture, so how do I tell VB to Look for BMWX5, instead of BM?

  9. #49
    Kitten CornedBee's Avatar
    Join Date
    Aug 2001
    Location
    In a microchip!
    Posts
    11,594
    Only alter the first two chars, all others contain information!

    You can't tell LoadImage that. Unless you write your own loader (not that hard) you can only copy the file to a temporary file which has the first two bytes corrected, then load this temporary file.
    All the buzzt
    CornedBee

    "Writing specifications is like writing a novel. Writing code is like writing poetry."
    - Anonymous, published by Raymond Chen

    Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.

  10. #50
    Addicted Member
    Join Date
    Dec 2001
    Location
    Great White North, ey?
    Posts
    202

    Question

    If that's the case, then wouldn't it be easier to store all your pictures on a seperate form and save them to Disk when the program runs and delet them when the program ends?


    Wait, I have a lot of large size pictures and that wouldn't work for me, I guess I'll have to look into writing my own load picture sub, I'm using DX7, will this make my life easier or harder?

  11. #51
    Kitten CornedBee's Avatar
    Join Date
    Aug 2001
    Location
    In a microchip!
    Posts
    11,594
    It doesn't matter, your DX version has nothing to do with your image loader.

    You could also directly alter the file to be usable and alter it back once you're done loading, but this means the file is vulnerable for a short while.
    All the buzzt
    CornedBee

    "Writing specifications is like writing a novel. Writing code is like writing poetry."
    - Anonymous, published by Raymond Chen

    Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.

  12. #52
    Fanatic Member MoMad's Avatar
    Join Date
    Oct 2000
    Location
    Seattle, WA
    Posts
    625
    If you just want a simple hack, change the first 2 bytes of the file to something like "my" and change the extension to something like ".my"

    Also, when ur program starts, change the first 2 bytes back like this:

    VB Code:
    1. Dim im As String
    2. Dim bt As String
    3. im = App.Path & "\Data\09D2.my"
    4.  
    5. Open im For Binary Access Read Write Lock Write As #1
    6.   bt = "BM"
    7.   Put #1, 1, bt
    8. Close #1

    Of course, you can put that code in a function and call it for each file in your data folder.
    :MoMad:
    Nice Sig!

    http://go.to/momad/ Status: Not Ready

  13. #53
    Addicted Member
    Join Date
    Dec 2001
    Location
    Great White North, ey?
    Posts
    202

    Cool

    Yep, thanks that works. I used the same code again when the program ends to change the picture back to "My" again. It is very simple to hack, but that's alright.

  14. #54
    Fanatic Member MoMad's Avatar
    Join Date
    Oct 2000
    Location
    Seattle, WA
    Posts
    625
    im glad someone thinks im useful.
    :MoMad:
    Nice Sig!

    http://go.to/momad/ Status: Not Ready

  15. #55
    Good Ol' Platypus Sastraxi's Avatar
    Join Date
    Jan 2000
    Location
    Ontario, Canada
    Posts
    5,134
    Don't worry Momad I don't It's a nice cheap hack someone like me wouldnt've thought of!
    All contents of the above post that aren't somebody elses are mine, not the property of some media corporation.
    (Just a heads-up)

  16. #56
    Fanatic Member MoMad's Avatar
    Join Date
    Oct 2000
    Location
    Seattle, WA
    Posts
    625
    Well tis best to keep it as simple as possible.

    Hey guess what, i ran into a "MoMad" today and they think im the "Fake" MoMad,... check it out:

    http://www.megarad.com/modules.php?n...thread&tid=229
    :MoMad:
    Nice Sig!

    http://go.to/momad/ Status: Not Ready

  17. #57
    Good Ol' Platypus Sastraxi's Avatar
    Join Date
    Jan 2000
    Location
    Ontario, Canada
    Posts
    5,134
    Hehe... I know there will never be another Sastraxi... Google it, EVERYTHING on there is basically a resume of what I've done (please don't look at the sites, they all suck...)
    All contents of the above post that aren't somebody elses are mine, not the property of some media corporation.
    (Just a heads-up)

  18. #58
    Fanatic Member MoMad's Avatar
    Join Date
    Oct 2000
    Location
    Seattle, WA
    Posts
    625
    The thing is, ive been momad far longer than that momad. So I should be the real momad... how do you know which gets to be the real one and which is the fake one? cant we just share the damn name!! LOL. Yea, sastraxi is such a unique name. lol. I used to think momad was unique untill now... lol.

    Also, just wait a few years, there might be a whole groups of sastaxis (just cuz they dont have a website dont mean theyre not there)
    :MoMad:
    Nice Sig!

    http://go.to/momad/ Status: Not Ready

  19. #59
    Addicted Member
    Join Date
    Dec 2001
    Location
    Great White North, ey?
    Posts
    202

    Talking

    Maybe I should re-name myselft to Sastraxi just to annoy Sastraxi, lol! Thanks MoMad, you are very useful, so is everybody that gives answers.

  20. #60
    Frenzied Member Zaei's Avatar
    Join Date
    Jul 2002
    Location
    My own little world...
    Posts
    1,710
    There is some other Zaei out there (at least the name in AIM and hotmail was taken), whom I desire to hunt down and kill =). Silly, too, since I got this name by pulling letters out of a hat =).

    Z.

  21. #61
    Fanatic Member tim_l_012's Avatar
    Join Date
    Mar 2001
    Location
    Next to a Coffee Cup.
    Posts
    641
    Well, I would be happy to write a *gulp* large (but effective) tutorial on BitBlt. I have only really just learned it, but I think the best way to learn is to try different things, and warn others about the pitfalls you had along the way

    If you wan I can start writing one up,
    /: Tim :\____________________
    \: VB, HTML, ASP, VBScript, QBASIC, JavaScript :/

  22. #62
    Good Ol' Platypus Sastraxi's Avatar
    Join Date
    Jan 2000
    Location
    Ontario, Canada
    Posts
    5,134
    I can give some tips too, inserted in your BitBlt tutorial, if you want. Stuff like inverse masking [colour dip], semi-transparent (err.. to a point) blitting, and other effects.
    All contents of the above post that aren't somebody elses are mine, not the property of some media corporation.
    (Just a heads-up)

  23. #63
    Fanatic Member tim_l_012's Avatar
    Join Date
    Mar 2001
    Location
    Next to a Coffee Cup.
    Posts
    641
    Ok, well I'll get to work! should be ready in about 2 days...
    /: Tim :\____________________
    \: VB, HTML, ASP, VBScript, QBASIC, JavaScript :/

  24. #64
    Kitten CornedBee's Avatar
    Join Date
    Aug 2001
    Location
    In a microchip!
    Posts
    11,594
    Ahh, I'm unique except for this:
    Corned Beef and Slaw Sandwich
    Corned beef and coleslaw sandwiches baked in the oven.
    http://www.cookingcache.com/cornedbee...
    The URL is truncated, it's something like cornedbeefandslawfish
    All the buzzt
    CornedBee

    "Writing specifications is like writing a novel. Writing code is like writing poetry."
    - Anonymous, published by Raymond Chen

    Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.

  25. #65
    Fanatic Member MoMad's Avatar
    Join Date
    Oct 2000
    Location
    Seattle, WA
    Posts
    625
    :MoMad:
    Nice Sig!

    http://go.to/momad/ Status: Not Ready

Page 2 of 2 FirstFirst 12

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width