Commit Graph

  • a06fcdaa41 Fix Half-Life Blue Shift. They switched the Entities and Planes lumps. master William Fowler 2021-10-14 19:04:06 -06:00
  • 15a083a649 Add reading of mipmaps for Quake I and GoldSrc engines to Texture. William Fowler 2021-10-05 00:53:38 -06:00
  • b5809ba1ae Add UNITY define to Lightmaps, accidentally left out. William Fowler 2021-10-02 01:41:49 -06:00
  • 4727c72c5e Change IsNullOrWhitespace to IsNullOrEmpty, for compatibility with old Unity versions. William Fowler 2021-10-02 01:41:12 -06:00
  • 5995fac39b Clean up lump reading a bit. Make it possible to read lump data using just an offset and length rather than an entire LumpInfo. William Fowler 2021-10-02 00:35:31 -06:00
  • 9f6b4227a1 Add lightmaps and visibility. No logic yet for decoding or reading these. William Fowler 2021-09-28 13:53:07 -06:00
  • d1eb36d906 Add support for GoldSrc as a format distinct from Quake 1. William Fowler 2021-09-28 13:10:05 -06:00
  • e2c5967389 Some XML doc fixes William Fowler 2021-09-28 12:20:02 -06:00
  • 096cea0f84 Remove Nightfire case from Face's "Effect" field. Nightfire does not have this field. William Fowler 2021-09-28 12:17:22 -06:00
  • 530750e5d0 Add support for 007 Nightfire normals lump William Fowler 2021-09-28 12:03:50 -06:00
  • 83d23fe599 Small updates to readme file. William Fowler 2021-09-28 12:03:01 -06:00
  • 78fc8df013 Add constructor to TextureData to copy another TextureData using any given format. wfowler 2021-04-19 00:35:08 -06:00
  • d00dd9011f Add missing data access in Texture. Add constructor to Texture to copy another Texture using any given format. wfowler 2021-04-19 00:34:10 -06:00
  • 070a6565e0 Fix incorrect and missing data access in StaticProp. Add constructor to StaticProp to copy another StaticProp using any given format. wfowler 2021-04-19 00:33:14 -06:00
  • 459212a861 Add constructor to StaticModel to copy another StaticModel using any given format. wfowler 2021-04-19 00:30:39 -06:00
  • a9006409d4 Add constructor to Patch to copy another Patch using any given format. wfowler 2021-04-19 00:29:40 -06:00
  • 3c387857ea Add missing data access in Node. Add constructor to Node to copy another Node using any given format. wfowler 2021-04-19 00:24:33 -06:00
  • fba0316b23 Add missing data access in Model. Add constructor to Model to copy another Model using any given format. wfowler 2021-04-19 00:22:50 -06:00
  • 4dc63ce4f0 Add missing data access in Leaf. Add constructor to Leaf to copy another Leaf using any given format. wfowler 2021-04-18 23:54:27 -06:00
  • 1eeaafe083 Add constructor to LODTerrain to copy another LODTerrain using any given format. wfowler 2021-04-18 23:48:35 -06:00
  • cf8fa88ec3 Fix missing data access in Face. Add constructor to Face to copy another Face using any given format. wfowler 2021-04-18 23:47:04 -06:00
  • 5866e89190 Add constructor to Edge to copy another Edge using any given format. wfowler 2021-04-18 23:00:23 -06:00
  • 929979c70e Add constructor to DisplacementVertex to copy another DisplacementVertex using any given format. wfowler 2021-04-18 23:00:02 -06:00
  • 6ed69a62e5 Add neighbor information to Displacement. Fix incorrect and missing data access in Displacement. Add constructor to Displacement to copy another Displacement using any given format. wfowler 2021-04-18 22:59:36 -06:00
  • 6157256fe5 Add constructor to Cubemap to copy another Cubemap using any given format. wfowler 2021-04-18 22:03:52 -06:00
  • eec690e4e2 Add constructor to BrushSide to copy another BrushSide using any given format. wfowler 2021-04-18 22:03:27 -06:00
  • 960244bba5 Add constructor to Brush to copy another Brush using any given format. wfowler 2021-04-18 22:02:46 -06:00
  • 993c85dcaf Quake 2 has 19 lumps, not 16. wfowler 2021-04-18 02:29:00 -06:00
  • 6ea530b089 Make extension classes into partial classes to avoid naming conflicts with similar classes in other projects. wfowler 2021-04-18 02:27:06 -06:00
  • 2292bd9b3e Daikatana has 21 lumps, not 16. Add MOHAA lump referencing static models from leaves. wfowler 2021-04-16 01:59:06 -06:00
  • 37fc7c5a26 Add extensions to make constructing Vectors from byte arrays easier. wfowler 2021-04-15 20:55:44 -06:00
  • d5330228f8 Fix broken setter for TextureData.Reflectivity. wfowler 2020-09-24 22:59:30 -06:00
  • a641cf9b61 (CoD) Fix index and data type of LeafPatches lump wfowler 2020-04-20 02:56:06 -06:00
  • 67211b5cce Large refactor: Properties are named more consistently to .NET standards. They also have XML docs now. There are now properties in structs to directly get a referenced object rather than simply an index to it. This should hopefully be the last time there is such a large change in the API. wfowler 2020-02-22 04:29:01 -07:00
  • b05ff3aae7 Revert trimming leading "textures/" from texture names during sanitization. wfowler 2020-02-20 01:43:16 -07:00
  • a8eb0d7ecb Fix broken XML doc (whoops?). wfowler 2020-02-20 01:29:27 -07:00
  • d9517b9685 Add utility to sanitize texture names, cleans Quake 3 leading "textures/", and Source cubemap texture names. wfowler 2020-02-20 00:53:52 -07:00
  • 3c372e6647 Fix reading patch size for Raven BSPs. wfowler 2020-02-19 22:49:08 -07:00
  • 52f8793397 Fix getting displacement vertices for a displacement (what was I thinking?) wfowler 2019-12-14 21:46:43 -07:00
  • 48366f4f52 Refactor to use System.Numerics structs rather than my own. Removes Vector2d, Vector3d, Vector4d, Plane and Ray. Implement a standard API for .NET, Unity and Godot through extension methods. In general, use floats rather than doubles for things. wfowler 2019-10-10 02:47:42 -06:00
  • a388f58073 Quake references textures through TextureInfo rather than directly. Will 2019-09-19 13:05:09 -06:00
  • 8e7e402ded Fix number of vertices in power 3 displacements (by actually calculating them) Will 2019-09-19 13:04:29 -06:00
  • 864a6dab6b Refactors to reuse some commonly used code. This changes a lot. Refactor everything to use a base ILump interface, and a Lump class implementing it to use in place of regular List. Refactor lump structures to use an ILumpObject interface. Eventually Lump<T> will enforce T is ILumpObject, there are some other things to do first. Use Path class to simplify some code in BSP. wfowler 2019-07-16 02:55:07 -06:00
  • 43ebf69f01 Refactor TextureInfo into a struct wfowler 2019-05-29 21:57:51 -06:00
  • 2686563805 Fill out more CoD4 structures. wfowler 2019-05-13 00:12:56 -06:00
  • d4373ee192 Change license to CC0. Will 2019-04-20 01:31:19 -06:00
  • 7a79b6af1d Merge branch 'master' of https://github.com/wfowler1/LibBSP Will 2019-04-20 00:16:39 -06:00
  • 50199b5d36 Add build timestamp to Revision.cs. Will 2019-04-20 00:16:25 -06:00
  • 177ba08281 Godot: Fix parsing of colors Will Fowler 2019-03-21 10:17:33 -06:00
  • bdc0c8695b Initial support for Godot engine. wfowler 2019-03-21 00:40:37 -06:00
  • bd0a1056f2 Fix exception if the BSP we're trying to read is actually too small to read. wfowler 2018-12-31 15:05:36 -07:00
  • a07c8e86cf Properly revert Revision.cs when building, and add build configuration information to Revision.cs. wfowler 2018-12-31 15:04:48 -07:00
  • e2a88ef860 Add proper plane "Type" calculations for formats that need it. wfowler 2018-12-01 20:44:51 -07:00
  • be109e0590 Fix brain fart reading shader names in MoHAA. wfowler 2018-12-01 18:55:59 -07:00
  • 27736ef13f Add partial support for Titanfall. So far I'm not sure this format can be decompiled like the others. Need to do more research and reverse engineering. Will 2018-12-01 16:20:44 -07:00
  • 76feb5046e Ridiculously massive refactor: All lump structures store their source data as a byte array now, so even unknown parts of structures are stored when they were discarded before. This means lumps can be read and written without losing any information. New extension methods for Vector2d, 3d and 4d, Vertex, Plane and Color to get their components as bytes for easy storage. Add support for most Call of Duty 2 structures. There's still some missing. Will 2018-11-22 19:28:03 -07:00
  • cab099b6f1 VertexExtensions: Read more data for a vertex. Also add support for CoD2 (more to come on this later) Will 2018-11-17 22:13:04 -07:00
  • 69295945bb Fix for reading Contagion and Vindictus maps. Will 2018-11-17 21:51:39 -07:00
  • 2f068b0086 Bump minimum Unity version to 3.4.0 Part 2 wfowler 2018-10-08 23:23:02 -06:00
  • 5c53f4f1ca Bump minimum Unity version to 3.4.0. This is the oldest version you can download on Unity's website anyway. Also: CoD2 has 39 lumps. More on this later. wfowler 2018-10-08 17:58:39 -06:00
  • 853831da7a Merge branch 'master' of https://github.com/wfowler1/LibBSP wfowler 2018-10-08 16:52:08 -06:00
  • af76a7b6b2 Optimize memory usage in BrushSide a bit. wfowler 2018-10-08 16:51:35 -06:00
  • 1617ffe6f0 Vertex: Use Color32 instead of Color. Will 2018-09-23 23:08:52 -06:00
  • c8b31cc302 Vertex: Bump OLDUNITY version threshold to pre-5.6.0. Will 2018-09-23 22:43:20 -06:00
  • 0e4b9491e3 Make TextureInfo serializable, and use fields instead of properties. wfowler 2018-08-27 00:44:33 -06:00
  • 5becc7dac4 Rather large refactor: Most changes were just small adjustments for coding style. Made "using" statements for Unity, rather than non-Unity compiles. So in Unity "Vector3d" is an alias for "Vector3", instead of the other way around. Restrict CountAttribute and IndexAttribute to apply to properties and fields only. Removed Rect and RectExtensions, Rect was never used anywhere and was leftover from a long-gone part of this project. Remove unnecessary "this" references and refactor Int32, Single, etc. to int, float, etc. (I might have missed a few of these). Refactor MAPBrushSide to use a TextureInfo rather than duplicating many fields. Make Terrain and Displacement formats use two-dimensional arrays rather than arrays of arrays. Rename UIVertex to Vertex. wfowler 2018-08-25 17:43:28 -06:00
  • 1014184f24 Call of Duty (1): Add support for various map structures based on my most recent reverse engineering. Other minor cleanup. wfowler 2018-08-05 16:38:27 -06:00
  • 015829f2e2 UIVertexExtensions: Make extension methods work like they do for reference types. Add vanilla static methods that do the same things, for compilers that don't support extension methods on "ref" parameters. wfowler 2018-07-31 17:55:06 -06:00
  • f251bb8137 Whoops, the Partition and Vertex classes need to be Serializable too. wfowler 2018-07-27 01:50:26 -06:00
  • bceac9031a Add "isManVis" flag to MAPBrush. wfowler 2018-07-26 07:55:28 -06:00
  • a8f939e5f8 Initial support for MoHAA LoD terrains: Rename MAPTerrain to MAPTerrainEF2. Add MAPTerrainMoHAA and LODTerrain. Add LODTerrain lump to BSP. wfowler 2018-07-26 05:13:30 -06:00
  • 249aaa2b77 Add a bit of error checking to the detection of Source entity connections. This will make the parser more robust against false positives. wfowler 2018-07-21 21:39:46 -06:00
  • 2f726b15bf Add MoHAA static models wfowler 2018-07-20 03:38:47 -06:00
  • caa7856fed Whoops, don't escape with backslashes here also. wfowler 2018-07-14 23:59:45 -06:00
  • c8a4bcb22d Fix a problem with entity processing that was throwing on a (probably) broken entity in MoHAA's m3l2.bsp. wfowler 2018-07-14 21:28:02 -06:00
  • 7fc89ecd4f Rename Face.textureScale to Face.textureInfo. wfowler 2018-07-14 20:24:22 -06:00
  • bba8a899ba Fix NullReferenceException when constructing TextureInfo. wfowler 2018-07-13 02:22:15 -06:00
  • 1a7203637d Add more fields to DisplacementInfo. Also fix a Unity-compile oversight. Again. wfowler 2018-07-09 02:32:11 -06:00
  • d9bfd2e3d2 Whoops, missed this one. wfowler 2018-07-09 02:04:00 -06:00
  • 2b5f61946f Fix compiling in Unity 2017 and 2018 versions. wfowler 2018-07-09 01:58:30 -06:00
  • e990e8d6d0 Add a bunch of Plane extensions for dealing with Quake engine planes in Unity. Fix a couple small mistakes elsewhere. wfowler1 2016-08-30 19:13:22 -06:00
  • 45c4de4094 Add texture scale information to TextureInfo. This is only useful in MAPBrushSides, BSPs compile the scales into the axes themselves. wfowler1 2016-08-30 19:11:05 -06:00
  • aa144a0f4c Small optimization to SplitUnlessInContainer in StringExtensions. wfowler1 2016-08-30 19:05:50 -06:00
  • 56c496c419 Fix getting head revision when checked out as a submodule. Will 2016-03-18 01:51:32 -06:00
  • 4641f37c1f Fix a mistake preventing the revision field from being filled. Also record the sha1 of the head revision. Will 2016-03-18 01:40:32 -06:00
  • 458c535809 Merge branch 'master' of https://github.com/wfowler1/LibBSP Will 2016-03-18 00:46:23 -06:00
  • 16b95973dd Add a Revision class containing a revision number, retrieved from GIT at build time. Will 2016-03-18 00:46:14 -06:00
  • 324edbf5f9 Fix a warning in BSP class. Will 2016-03-18 00:44:33 -06:00
  • ef5454bf92 Add a todo reminding me to do MoHRadiant terrain. Will 2016-02-20 16:50:56 -07:00
  • 902b1f9f49 Fix reading vertices of EF2 maps. Will 2016-02-20 05:38:25 -07:00
  • fbb56a52fd Visual Studio does funny things with CSPROJ files. Will 2016-02-20 03:31:22 -07:00
  • 2700decfe3 Merge branch 'master' of https://github.com/wfowler1/LibBSP Will 2016-02-20 03:27:51 -07:00
  • f9bd13ae35 Add support for EF2 terrainDef structures. Will 2016-02-20 03:27:32 -07:00
  • 87cd9fb2bb Fix reading Call of Duty maps. Will 2016-02-18 22:02:22 -07:00
  • c11ac46c78 Unbreak Left 4 Dead 2. (Oops) Will 2016-02-15 19:32:43 -07:00
  • 10efe43efd Fix reading v6 Static Props in Vindictus. Will 2016-02-15 14:20:54 -07:00
  • b8c883fd75 Refactor of BSP and BSPReader to enable lump structures to know what version of lump they represent. Will 2016-02-15 02:57:10 -07:00
  • 75ee1e44f1 Fix issues reading Game Lump in Vindictus maps. Will 2016-02-13 21:30:37 -07:00
  • bdde60d78c Resolve issues of decimal formatting in non-English locales. Will 2016-02-11 21:22:13 -07:00
  • 4a35493246 Fix brush side vertex reading from MAPBrushSides in files. Will 2016-02-08 02:44:50 -07:00