Page 1 of 1

[Library] TagInterface .NET

Posted: Sun Jan 22, 2006 9:24 pm
by kornman00
Download Update
TagInterface .NET Library by Kornman00

TagInterface.dll - v1.0.6 : .NET 1.1
TagInterfaceV2.dll - v2.0.0 : .NET 2

This provides a generic way to interface with blam engine tags.
The TagInterface assemblies hold the code for loading\saving things.

This is a modeified version of the code I started using
in my personal halo IDE tool almost a year ago (removed loading from map files code)

TagInterfaceDoc.chm has the current info of all the types in TagInterface.dll.

Only 2 or 3 method signatures have changed when upgrading to .NET 2, so I didn't
see the need to create a whole new chm file for it. Also V2.dll hasn't been offically tested, though
no functionality code has been changed drasticly so it should be OK.

Also added a new field called 'Skip' to work with non-byte swapped fields



BlamInterface .NET Library by Kornman00

BlamInterface.dll - v0.2.0.0 : .NET 1.1 (need to build the project to get this DLL)

BlamInterface has some examples of setting up the Tag group collections for a certain game, and defining
tag group definitions for a certain game. The csproj file for this class library was made with VS.NET 2003, but
like always, can be upgraded to the newest verion of VS.NET
Included Tag Groups:
-bitmap
-gbxmodal (although refered as model in the code)
-model_collision_geometry
-model_animation
-sound
-unicode\string_list
-structure_bsp*

* Note: There is bad definition data in this group. Appeas to be a few bytes off in the main definition data (child blocks should be fine though)
Although you could use this for Halo2 tag definitions (they would have to have the same file structure as Halo1 source tag definitions), more people would probably end up using it for CE, so I just posted it here.

Sample code for loading a tag definition:

Code: Select all

static void Main(string[] args)
		{
			BlamInterface.Halo1.model_group model = new BlamInterface.Halo1.model_group();
			Console.WriteLine("Loading...");
			TagInterface.EndianReader tagdef = new TagInterface.EndianReader(@"C:\Program Files\Microsoft Games\Halo Custom Edition\tags\untitled tag.gbxmodel", TagInterface.EndianState.Big);
			tagdef.Position += 64;
			model.Load(tagdef);
			Console.WriteLine("Done");
			Console.WriteLine(model.GetShader(0).Shader.Value);
			Console.ReadLine();
		}
All you have to do is supply the field info (no offsets or annoying shit like that) and it will be able to do things like loading\saving for you.

I got tired of all the hacks people made in their code for accessing tags, decided it was time to set somethings straight.

Posted: Mon Jan 23, 2006 12:05 am
by Veegie[Temp]
Fix the sbsp definition data ;X

Posted: Mon Jan 23, 2006 6:19 am
by kornman00
Veegie wrote:Fix the sbsp definition data ;X
Learn to program.

Posted: Tue Feb 07, 2006 9:41 pm
by kornman00
Uninstalled mambo, so you have to get from this part of my site now:
http://kornner.epgservers.net/downloads/Source/