Giter Site home page Giter Site logo

wowdevtools / blender-wmo-import-export-scripts Goto Github PK

View Code? Open in Web Editor NEW
37.0 12.0 18.0 627 KB

Script addon for Blender featuring World of Warcraft World Model Object (WMO) editing functionality.

License: GNU General Public License v3.0

Python 100.00%

blender-wmo-import-export-scripts's Introduction

Blender WMO import/export addon

Actually this addon is much more than a usual import/export Blender plugin. Besides core functionality of importing and saving edited WMOs, this addon is also a powerful editor supporting nearly all features of World of Warcraft World Model Object (WMO) files. Written in Python using Blender API.

DEPRECATED!!!

This repository is deprecated in favor of WoW Blender Studio, a more recent continuation of this addon. https://gitlab.com/skarnproject/blender-wow-studio. WoW Blender Studio is intended to be used with the most recent versions of Blender. The code on this repository only supports Blender 2.79b. No support for this version will be given.

What is World Model Object?

World Model Object or just WMO is a special compound 3D structure used in the game World of Warcraft for making buildings, dungeons and other big complicated 3D objects. It does not only contain traditional 3D model parts as geometry, UV maps, materials and so on; but it does also support features like liquids, complex lighting system, portal culling system and much more.

WARNING: The code on this repo is work in progress

This repo only exists for development purposes, not for deploying versions to users. File corruption may occur if you by chance pull some unfinished or broken code. The last "stable" verson is available on http://model-changing.net (Model Changing Network) and is supplied with how-to documentation.

Donation

The provided software is available completely free of charge, however if you want to support me, here is my PayPal account: https://www.paypal.me/sergeishumakov2015

Currently supported features

  • Geometry editing. The script allows the user to edit WMO geometry, UVmaps and create outdoor and indor groups.
  • Material editing. The addon supports all features of WoW material system. A user is able to create materials, set textures, change used shaders, blending modes, flags etc.
  • Vertex colors.
  • WMO portals. The script addon supports all features of WMO portals, except antiportal creation.
  • WMO fogs.
  • WMO liquids. The liquid system is fully supported including UV editing for lava and tile flags.
  • Collision.
  • Render batches.
  • Lightmaps.
  • Quick WMO panel. A UI interface aimed to ease the process of WMO creation.

Credits

Developers:

  • happyhack (original addon version)
  • Miton (portals and other contributions)
  • Skarn (current developer)
  • Supora (initial vertex color import/export support)
  • p620 (multiple help with complicated coding tasks)

Testers:

  • Balkron
  • Amaroth
  • Supora
  • Kadzhamit
  • gratural
  • Vellear
  • intra & others.

Special thanks to Deamon and fallenoak for information on batches and portals and all other http://wowdev.wiki contributors.

Planned features

  • Transport convex volume planes
  • Doodadset editing. (If the m2 plugin arrives by that time)

Installation and usage:

http://www.model-changing.net/files/file/56-wmo-importexport-blender-scripts-updated-25022016/ (relevant to last officially released version)

blender-wmo-import-export-scripts's People

Contributors

mitongit avatar skarndev avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

blender-wmo-import-export-scripts's Issues

Baking portal relations

For some reason portals never work for me at first attempt.

I create portal linking 2 WMO groups (applies to both indoor-indoor and indoor-outdoor relation), select portal and click on Bake portal rels. Then I export and test WMO, and portal never works.

What is weird is that if I click on Bake portal rels. again and re-export WMO, suddenly portal works. I always need to re-bake portal relations and re-export WMO after first to WMO export to make portals work.

Legacy collision is not always material 255

Sometimes Blizzard uses normal materials for invisible geoemtry used for legacy collision in most vanilla WMOs. As a result, when imported the export logic regards those pieces of geometry as visible, batch type C. Possible ways to resolve: a) not importing legacy collision at all (bad and radical), b) creating a special vertex group for bugged legacy geometry and let user decide what to do with it.

Portal plane creation

When turning object to WMO portal, there is no possibility to set WMO groups which should be connected by portals. One needs to access every single portal, one by one, and set this by hand in object properties. This makes mass creation of multiple portals quite slow and annoying.

The another thing is that when picking WMO groups portal is to be connected to, there are another portals and different kinds of objects to pick from. There should be only WMO groups in drop down menu.

The last thing is that there is no default WMO group set when object is turned to portal plane. So right now, even when I've got only one indoor and one outdoor group, I've got to set them there anyway.

7.3 wmos

World\Wmo\dungeon\argusraid\7du_argusraid_citadelinterior01.wmo.wmo
World\Wmo\dungeon\argusraid\7du_argusraid_shivantemple.wmo
World\Wmo\dungeon\argusdungeon\7du_argusdungeon_karaborinterior01.wmo
World\Wmo\dungeon\argusdungeon\7du_argusraid_engineeringwing01.wmo
and some others crash on importing

[Proposal] Disable console spam

There is a console window:
tw19skg - imgur

Steps to reproduce:

  1. Follow steps from bug #6
  2. Export WMO mesh
  3. Wait a little

Excepted result: It will be spamming the same message every 2-3 minutes after export

[Bug] Hidden portal provides crash

Steps To Reproduce:

  1. Hide portal group (or disable portals in WMO-addon tab)
  2. Export

Expected result:
Export crash

Task:
Add an exception for that kind of action

Portal setting choices

When choosing which WMO groups are linked by a portal, drop down menu offers even meshes which are not WMO groups. This can produce very long list which is hard to search through, especially in WMOs with many portals.

LiquidType

Whole liquid type saving requires investigation. Suspectedly, 0x04 flag in root's MOHD chunk switches Liquid Type system to real DBC Liquid Types. If not set, local type ID is used.

Game Data Won't Load

Path to World of Warcraft folder is correct in the user preferences. Unable to load game data using WMO interface in Blender.

C:\Program Files (x86)\World of Warcraft\

Is the path used.

Portals are broken

On exporting, portals take this shape:
http://prntscr.com/efs1uv
Same shape as, if you make portal from standart plane.
Obviously, such a portal is working wrongly: at least one side of him are non trasparrent.

[Proposal] M2 Import\Export

Task:
Make a convert process for m2.

Steps:

  1. Import model.
  • it should contain as many objects as textures (1 object contains 1 texture)
  1. User don't need to make any operations with it
  • user don't need to make a Edge Split and other actions. Those actions should be in export process (silent mode)
  1. User edits model as he wants
  2. Export

Fog :(

In short, he does not are exported. ((
This applies both as hand-made and re-exported standard WMO (MD_Goldmene, MD_Spidermine) They just not visible in game(in noggit too).
At creation fog, I took settings from Blizzard WMO, and pick in each mesh group name of my placed fog. Maybe i need do something else?

One more thing. When opening fog list, blender shows all scene meshes, not only fog meshes.
http://prntscr.com/eea7dv

[Bug] Texture path doesn't work correctly

Steps to reproduce:

  1. Create mesh
  2. Apply the texture with uv
  3. Type your texture relative path in scene properties:
    image
  4. Click on Texface to Material button
  5. Click on Fill textures button

Excepted result:
image
Your texture will have only own name without full texture path.

Orgrimmar2.wmo dont open in blender

when I try to import this wmo in blender I get this error =
here is the wmo
World.zip

here is the error
Traceback (most recent call last):
File ":\blender-2.78c-windows64\2.78\scripts\addons\io_scene_wmo_init_.py", line 163, in execute
import_wmo.import_wmo_to_blender_scene(self.filepath, self.load_textures, self.import_doodads, self.group_objects)
File "\blender-2.78c-windows64\2.78\scripts\addons\io_scene_wmo\wmo\import_wmo.py", line 56, in import_wmo_to_blender_scene
group.load_object(obj_name, import_doodads)
File "\blender-2.78c-windows64\2.78\scripts\addons\io_scene_wmo\wmo\wmo_group.py", line 458, in load_object
mesh.polygons[i].material_index = material_indices[mat_id]
KeyError: 0

location: :-1

[Bug] In-Game crash without crash at export

Steps To Reproduce:

  1. Enable Vertex Color in any group
    image

  2. Your mesh must be with no vertex color in Vertex Paint window

  3. Export WMO

Expected result: Crash when your world loads (with no crash-window)

Can't export blender project to WMO

I am using Blender 2.79 and I am trying to export a blender project to WMO format, I did not succeed for the following error.
Is there a way to fix this error?

image

[Proposal] Add humanscale creator

Task:
Make the [Add HumanScale] button which will generate humanscale-model. That will be very helpful for fast-checking your model proportions.

Proposal for performance:
You can make only 3d-box which will have the same size with humanscale (x-y-z dimensions)

0205f0b

Vertex shading indoors

In indoor group has vertex shading off, client will crash. If vertex shading is on, but none is set to actual geometry, client will crash.

I'd suggest turning vertex shading on and assigning some default color value to all verticles for all indoor groups on export, if they have vertex shading turned off or if they don't have vertex shading assigned to all verticles, so one doesn't have to do this by hand.

[Proposal] Add some import properties

Idea:
make Import WMO function more customizable.

How to implement:
make checkboxes for lights, portals, fogs and water. It will be very useful for fast importing of huge wmos.

Example:

vddw3b6 1

Mesh's Group ID's

When exporting to WMO, groups are getting unpredictable and uncomfortable ID. They takes ID's in order when they are added to scene (can make sure, by reimport WMO, turning off "Alphabetically" in Outliner and verify ID's names and his order in list) It is particularly important, that the ID's will change each time, after addition new meshes. Maybe you should change order list on export WMO's groups, from last to first, or he can be alphabetical.

[Proposal] Application of ambiant color on doodads

Instead of setting color manually, one by one, on each doodad, it will be helpful to apply the same color from geoset to all selected doodads. Not automatically on all doodads, because if we have some exteriors m2, they will be colored like the inside.

Error on export

Attempting to export an object as WMO when in vertex paint mode causes an error. The same applies to edit mode and possibly other modes than object mode in general.

[Request] Remove vertex data spam

Steps To Reproduce:

  1. Select any group
  2. Click on Quick Collision button several times

q8g3qsr

Expected result:
Your group will have lots of vertex data groups

There are no bug but it causes few problems with vertex-data-work (Vertex Color/LightMap assignment)

Task:
Make the Quick Collision function as a replacer of vertex data (only one vertex data group)

Portal creation

When selected mesh is turned to WMO portal by using To WMO portal in Convert selected drop down, there appears panel with possibilities to pick 2 WMO groups linked by created portals in left panel. The problem is, that WMO group picking in that panel does not work (picking a group does nothing). You need to go to properties of created portal and set WMO groups there by hand. Clicking on pippette there does only one thing - it produces an error.

Also, I'd like to see addon setting up portals with some default groups on its own.:

  1. There is 1 outdoor and 1 indoor group? Portal should get set to those 2 on its own.
  2. There is 1 or more outdoor and 1 or more indoor group? Portal should get set to 1st found outdoor and 1st found indoor group on its own by default.
  3. None of 2 above? Portal should get set to the first 2 groups which are found. To none if none is found, obivously.

This would save up a LOT of clicking.

Doodadset saving

Preserving doodadset does not set names for doodads correctly. One same model is used instead.

[Bug] Empty select crash | Picker

Steps to reproduce:

  1. Use Add Water
  2. Click on Picker icon
  3. Select the empty place in your scene (not mesh)

2017-03-06_23-39-37

Excepted result: console crash

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.