The insanely simple blender tutorial for Lugaru modders
-
- Posts: 1492
- Joined: Mon Mar 17, 2008 6:13 am
- Location: New Zealand
-
- official Wolfire heckler
- Posts: 2193
- Joined: Sun Aug 28, 2005 11:19 pm
- Location: Hamburg City
- Contact:
I think I could. But I won't post something that detailed without fixed texture mapping, sorry.Chainsaw man wrote:Since I dont know the first thing about creating 3D things...
do you think you could make me a Chainsaw?
Yes.Makrond wrote: Wait, I'm a little confused... can you have irregular quads or not?
I think there's a little confusion here: Quads are faces with 4 vertices. Cubes are die-shaped closed meshes.
You can have irregular quads, cubes, triangles and a lot of other meshes.
The restriction lies in the structure of meshes. For example, cones wouldn't work, neither would icospheres. But with a little ingenuity, you can build working alternatives.
-
- official Wolfire heckler
- Posts: 2193
- Joined: Sun Aug 28, 2005 11:19 pm
- Location: Hamburg City
- Contact:
Okay, as of v0.2 of the X2Solid tool, texture mapping works. There are some quirks to it though.
Look:
In a nutshell, the UVMap picture you use in blender needs to be mirrored vertically for Lugaru. Blender has an inverted Y-Axis for UV maps, that's why. I was too lazy to write code that deals with that, it's not really a problem though.
Have fun!
Oh, the 1:1 size for objects is 0.6666, just in case you wondered. At that size, the UV map is correct. At least for cubes.
Look:
In a nutshell, the UVMap picture you use in blender needs to be mirrored vertically for Lugaru. Blender has an inverted Y-Axis for UV maps, that's why. I was too lazy to write code that deals with that, it's not really a problem though.
Have fun!
Oh, the 1:1 size for objects is 0.6666, just in case you wondered. At that size, the UV map is correct. At least for cubes.
-
- Gramps, Jr.
- Posts: 4297
- Joined: Mon Dec 05, 2005 12:14 am
- Location: New Zealand
-
- official Wolfire heckler
- Posts: 2193
- Joined: Sun Aug 28, 2005 11:19 pm
- Location: Hamburg City
- Contact:
I don't know why, that's just how it is...Makrond wrote:Why don't cones and icospheres work? They're essentially made of triangles, right?
No sword yet... not sure where the problem is though... it's made entirely of triangles...
Okay, I'll give you an example of how to make a sword.
Cubes are represented here with an O, the one at (0,0,0) with an X. The (0,0,0) one has to contain (0,0,0).
You start with a cube at (0,0,0) that's made of quads, NOT of triangles:
Code: Select all
X
Code: Select all
X
O
Code: Select all
O
X
O
Code: Select all
OOO
X
O
Code: Select all
O
O
O
O
O
OOO
X
O
You can of course translate vertices, rotate faces and whatever, as I said.
When you're done, you convert all quads to triangles, do UV mapping, flip the normals, scale the model up (and apply rotations and scaling), export to .x, mirror your texture vertically, convert the .x to .solid, replace the Sword model and the Sword texture. That should work.
Edit: Forgot a few steps.
Edit: Terminology.
-
- official Wolfire heckler
- Posts: 2193
- Joined: Sun Aug 28, 2005 11:19 pm
- Location: Hamburg City
- Contact:
Also, does Lugaru crash with your .solid or is it just invisible? If it's invisible, you either forgot to scale it up or you haven't flipped the normals (or both).
I'd advise you to start with really simple meshes and save them before you triangulate. That helps a lot. So you get a simple mesh working in-game and iterate on it, you know? Instead of making a crazy 1000poly katana for 1 hour just to find out it makes the game crash.
I'd advise you to start with really simple meshes and save them before you triangulate. That helps a lot. So you get a simple mesh working in-game and iterate on it, you know? Instead of making a crazy 1000poly katana for 1 hour just to find out it makes the game crash.
-
- official Wolfire heckler
- Posts: 2193
- Joined: Sun Aug 28, 2005 11:19 pm
- Location: Hamburg City
- Contact:
Okay, here is a sword manufacturing tutorial in video form. This is the first take, so it's a little undecided and the mesh is a steaming pile of shit, but you get the idea.
http://rapidshare.com/files/118795232/swordex.avi.html
Edit: Also, I didn't put the handle to (0,0,0), which turned out to be a bad idea.
http://rapidshare.com/files/118795232/swordex.avi.html
Edit: Also, I didn't put the handle to (0,0,0), which turned out to be a bad idea.
-
- official Wolfire heckler
- Posts: 2193
- Joined: Sun Aug 28, 2005 11:19 pm
- Location: Hamburg City
- Contact:
So here's the CrazySword, a mesh for you to test. It's just for testing purposes, so don't mind the bad texture.
Screenshot:
ZIP comment:
Get CrazySword.zip at http://lugaruspace.50megs.com/models and follow the above instructions. Please report whether it works for you.
Screenshot:
ZIP comment:
Code: Select all
CrazySword for Lugaru, a test mesh by rudel_ic 08-05-31
Copy
CrazySword.solid to Lugaru/Data/Models
CrazySword.jpg to Lugaru/Data/Textures
CrazySwordblood.jpg to Lugaru/Data/Textures
CrazySwordbloodlight.jpg to Lugaru/Data/Textures
Backup
Sword.solid in Lugaru/Data/Models
Sword.jpg in Lugaru/Data/Textures
Swordblood.jpg in Lugaru/Data/Textures
Swordbloodlight.jpg in Lugaru/Data/Textures
Rename
CrazySword.solid in Lugaru/Data/Models to Sword.solid
CrazySword.jpg in Lugaru/Data/Textures to Sword.jpg
CrazySwordblood.jpg in Lugaru/Data/Textures to Swordblood.jpg
CrazySwordbloodlight.jpg in Lugaru/Data/Textures to Swordbloodlight.jpg
And then slash em with the CrazySword!
Odd... that works.
I have an interesting question: does the .x exporter triangulate meshes before export? Because if not that may be the problem...
EDIT: Huh... nope, that's not it...
I don't get it... it's made entirely of triangulated quads - even the point at the tip is a very small quad...
Awesome, found a free file hosting site...
Here is the .blend... maybe you can tell me where I went wrong...
I have an interesting question: does the .x exporter triangulate meshes before export? Because if not that may be the problem...
EDIT: Huh... nope, that's not it...
I don't get it... it's made entirely of triangulated quads - even the point at the tip is a very small quad...
Awesome, found a free file hosting site...
Here is the .blend... maybe you can tell me where I went wrong...