Jump to content


Photo

Tar Dll - Manage Tar Archives


  • Please log in to reply
15 replies to this topic

#1 msoft

msoft

    GMC Member

  • New Member
  • 54 posts

Posted 06 January 2007 - 12:10 AM

TAR DLL


With this DLL you can add all your resources to tar archives (for example with 7-zip) and then extract it when your game needs it.
Or you can create your own program to manage tar archives, because it can even add files.

It has not many functions yet, but I'll add more, if you like it (compress with gz, rename files, extract directory, ...).

There are two versions:

The GM6 version (with dll and scripts + example (help is in game information)): Download GM6

and the GM7 version as extension (+ example (help is in game information): Download GM7


Please report all bugs! And post your comments and suggestions to this dll!
-msoft
  • 0

#2 Chrishowarth

Chrishowarth

    GMC Member

  • Validating
  • 208 posts

Posted 06 January 2007 - 02:52 PM

Good idea! You could now try and extend it to .zip and .rar archives.

#3 mme

mme

    MME

  • GMC Member
  • 1012 posts

Posted 06 January 2007 - 10:00 PM

Very handy I might use this for an installer you should also include .cab, .zip, .rar, .tar.gz
  • 0
gmc_mdu2.pngrsa_gmc_sig.png

#4 msoft

msoft

    GMC Member

  • New Member
  • 54 posts

Posted 07 January 2007 - 02:18 PM

Thanks for the comments!
The next thing I'll try to include will be gzip compression (tar.gz). But first I have to find a good explanation about this algorithm. If you have some documents about gzip, zip, rar, bzip2 or cab, please send me a pm!
  • 0

#5 johng1970

johng1970

    GMC Member

  • New Member
  • 3 posts

Posted 26 January 2007 - 06:44 AM

Thanks for the comments!
The next thing I'll try to include will be gzip compression (tar.gz). But first I have to find a good explanation about this algorithm. If you have some documents about gzip, zip, rar, bzip2 or cab, please send me a pm!

<{POST_SNAPBACK}>

Another format to consider. Not really usefull to most people is the old CP/M .lbr format. The beauty of it is that its really quite simple. Files are stored like in the tar format, works off hte same basic concept as tar.... Combine all files into 1 gigantic file that can compress better using programs like gzip. The advantages as I see it for developers to use the .lbr format.... Not as many people know about .lbr format these days (not as popular), there fore, you could stash all your files in .lbr format and the chances of someone downloading your game and extracting your resources, changing your logos, documents, etc. and re-encoding them into the .lbr file, then trying to claim it as one of their creations, or hacking a registered version out of it.... Is much slimer than tar, which has easy to find utilities for extracting and adding files under windows and linux.
  • 0

#6 h0bbel

h0bbel

    GMC Member

  • New Member
  • 252 posts

Posted 26 January 2007 - 08:31 AM

Tar DLL ?

I don't have gm7 but it looks to me this executes a external program ?
  • 0
The empty archive bug should be fixed on my site.
Please use the "report bug" button on my site to report bugs, makes things clearer.

#7 NewDuck

NewDuck

    GMC Member

  • New Member
  • 54 posts

Posted 26 January 2007 - 12:24 PM

Good job, but how would you protect the archive? maybe you can make your DLL to support password protection on archives as well? even tho I am not sure if it's possible with Tar, cuz I don't know much about this archive type.
  • 0

#8 Scobbo

Scobbo

    GMC Member

  • New Member
  • 79 posts

Posted 11 February 2007 - 08:07 AM

Can it create a file, exactly like .tar but has another extension, like what id did with quake 3 arena had the .pk3 files which were identical to .zip?
  • 0

#9 SquareWheel

SquareWheel

    Square Wheel Games

  • New Member
  • 851 posts
  • Version:Unknown

Posted 11 February 2007 - 11:35 AM

I don't think Mark wants GM7 hosted anywhere besides his site. You should remove that file and link to the beta page.
  • 0
Cook Console | Editor Engine | Mass File Namer

All of my examples are publicly available and can be found at

#10 msoft

msoft

    GMC Member

  • New Member
  • 54 posts

Posted 11 February 2007 - 12:28 PM

Thanks for all the replies! I had not much time the last days, so i couldn't answer. If I have more time, I will continue this dll.

@johng1970: I will take a look at the file format from this lbr files. Maybe I'll include it.

@h0bbel: It doesn't execute a external file, it is only a dll. There are 2 versions: one for gm6 and one for gm7.

@NewDuck: As far as i know, password protection is not supported by tar archives.

@Cookinater: I do not host gm7, this is only the link to the gm7 version of the example (the gmk file)

-msoft

Edited by msoft, 11 February 2007 - 12:37 PM.

  • 0

#11 DFortun81

DFortun81

    The Fortunate One

  • GMC Member
  • 899 posts
  • Version:GM:Studio

Posted 11 February 2007 - 10:15 PM

This is a nice DLL. Add the functionality to password protect it and I'll use it for the project in my signature. Well, all of my projects that use external files for that matter.

-DF81
  • 0

dia_rpg_builder.png
Navigate to my personal website by clicking the image above.


#12 nic353

nic353

    GMC Member

  • New Member
  • 16 posts

Posted 03 April 2007 - 12:45 AM

I am not able to extract a file..?

The extracted file does not appear.

Is it possible to extract a directory or all files?
  • 0

#13 MrJackSparrow2

MrJackSparrow2

    GMC Member

  • GMC Member
  • 632 posts
  • Version:GM:Studio

Posted 19 March 2008 - 04:38 AM

I have successfully archived a directory, but how do you extract it? The only way I can get it to work is by extracting each file individually, which really defeats the purpose for me. Can I extract an entire directory AND keep its internal structure. (Meaning keep all the sub-directories and sub-sub-directories in order as they were archived?)
  • 0

#14 LRG

LRG

    GMC Member

  • GMC Member
  • 687 posts
  • Version:GM:Studio

Posted 22 March 2008 - 05:25 PM

yes, extracting a whole directory would be helpful...

EDIT: if I extract a file and then archive it after I'm done with it, does the archived file get replaced with the extracted file?
like this:
TarOpen("archive.tar",tar_read)
TarExtractFile("sound.wav","sound.wav")
TarClose()

sound_add("sound.wav",0,0)

TarOpen("archive.tar",tar_append)
TarAddFile("sound.wav")
TarClose()
Will the sound file get replaced?
i.o.w. how many "sound.wav" files would there be in archive.tar?

Edited by LRG, 23 March 2008 - 02:52 AM.

  • 0

...Coming to you May 1, 2012 or later...
Posted Image


#15 royboyjoytoy2

royboyjoytoy2

    GMC Member

  • New Member
  • 308 posts

Posted 10 April 2008 - 01:12 AM

I would really like to see some sort of compression (like gz or bz2). This is a very useful dll and compression will help save a lot of space if you are keeping all your resources in an archive.
  • 0
"The world will soon see the most successful game ever."

#16 ash47

ash47

    O_o

  • GMC Member
  • 1347 posts

Posted 22 April 2008 - 10:01 AM

i will try this and i already did use 7zip.

;)

edit: doesnt work at all.

http://gmc.yoyogames...howtopic=326729

that works 100% and it is fast!

:P

Edited by elite69, 22 April 2008 - 10:20 AM.

  • 0
Posted Image

Rate this topic: 0 | 1 | 2 | 3 | 4 | 5

PRESS IT
\/