Page 2 of 36

Re: (Object Asset) Empty Catacomb as Alcove

Posted: Sat Sep 29, 2012 5:13 am
by Batty
Here we go...
SpoilerShow
Image
I used Lmaoboat's positioning numbers to define 2 "logical alcoves" -- they have no visuals and do not replace the wall.
You have to click on the left or right edge of the alcove to place the left and right objects.

I'm pretty sure targetPos & targetSize refer to the placement and dimensions of the "click box" to add.
These numbers will probably need to be adjusted to fine tune it.

Keep objects like swords in mind because they may clip the sides if placed left/right.
I moved the boxes back a bit because items weren't sitting in as snugly as they do in the standard alcove.

Code: Select all

defineObject{
   	name = "dungeon_catacomb_alcove_left",
   	class = "Alcove",
   	anchorPos = vec(-0.4, 0.75, 0.3),
   	targetPos = vec(-0.5, 0.85, 0.2),
   	targetSize = vec(0.6, 0.5, 0.6),
   	placement = "wall",
   	replacesWall = false,
   	editorIcon = 92,
}

defineObject{
   	name = "dungeon_catacomb_alcove_right",
   	class = "Alcove",
   	anchorPos = vec(0.4, 0.75, 0.3),
   	targetPos = vec(0.5, 0.85, 0.2),
   	targetSize = vec(0.6, 0.5, 0.6),
   	placement = "wall",
   	replacesWall = false,
   	editorIcon = 92,
}
ok, can't seem to adjust it to fit 3 items nicely, swords clip a bit and you have to click too far left/right to place side items.

A solution that I like better is 2 items close to the center but no dead center item (sword is on left).
SpoilerShow
Image
I nullified the center box by changing targetSize to 0. For the side boxes, I moved the anchor position inwards and increased the targetSize.

Code: Select all

defineObject{
   	name = "dungeon_catacomb_alcove",
   	class = "Alcove",
   	anchorPos = vec(0, 0.75, 0.3),
   	targetPos = vec(0, 1.3, 0),
   	targetSize = vec(0, 0.5, 0.6),
   	model = "assets/models/env/dungeon_catacomb_empty.fbx",
   	placement = "wall",
   	replacesWall = true,
   	editorIcon = 92,
}

defineObject{
   	name = "dungeon_catacomb_alcove_left",
   	class = "Alcove",
      anchorPos = vec(-0.2, 0.75, 0.3),
   	targetPos = vec(-0.2, 0.85, 0.2),
   	targetSize = vec(0.8, 0.5, 0.6),
   	placement = "wall",
   	replacesWall = false,
   	editorIcon = 92,
}

defineObject{
   	name = "dungeon_catacomb_alcove_right",
   	class = "Alcove",
   	anchorPos = vec(0.2, 0.75, 0.3),
   	targetPos = vec(0.2, 0.85, 0.2),
   	targetSize = vec(0.8, 0.5, 0.6),
   	placement = "wall",
   	replacesWall = false,
   	editorIcon = 92,
}

Re: (Object Asset) Empty Catacomb as Alcove

Posted: Sat Sep 29, 2012 8:25 am
by Neikun
Very nice work, Batty. You've saved me from a lot of fiddling. :D

Re: (Object Asset) Empty Catacomb as Alcove

Posted: Sat Sep 29, 2012 8:48 am
by Blichew
Batty wrote:Here we go...
SpoilerShow
Image

Code: Select all

defineObject{
   	name = "dungeon_catacomb_alcove_left",
   	class = "Alcove",
   	anchorPos = vec(-0.4, 0.75, 0.3),
   	targetPos = vec(-0.5, 0.85, 0.2),
   	targetSize = vec(0.6, 0.5, 0.6),
   	placement = "wall",
   	replacesWall = false,
   	editorIcon = 92,
}

defineObject{
   	name = "dungeon_catacomb_alcove_right",
   	class = "Alcove",
   	anchorPos = vec(0.4, 0.75, 0.3),
   	targetPos = vec(0.5, 0.85, 0.2),
   	targetSize = vec(0.6, 0.5, 0.6),
   	placement = "wall",
   	replacesWall = false,
   	editorIcon = 92,
}

Code: Select all

defineObject{
   	name = "dungeon_catacomb_alcove",
   	class = "Alcove",
   	anchorPos = vec(0, 0.75, 0.3),
   	targetPos = vec(0, 1.3, 0),
   	targetSize = vec(0, 0.5, 0.6),
   	model = "assets/models/env/dungeon_catacomb_empty.fbx",
   	placement = "wall",
   	replacesWall = true,
   	editorIcon = 92,
}

defineObject{
   	name = "dungeon_catacomb_alcove_left",
   	class = "Alcove",
      anchorPos = vec(-0.2, 0.75, 0.3),
   	targetPos = vec(-0.2, 0.85, 0.2),
   	targetSize = vec(0.8, 0.5, 0.6),
   	placement = "wall",
   	replacesWall = false,
   	editorIcon = 92,
}

defineObject{
   	name = "dungeon_catacomb_alcove_right",
   	class = "Alcove",
   	anchorPos = vec(0.2, 0.75, 0.3),
   	targetPos = vec(0.2, 0.85, 0.2),
   	targetSize = vec(0.8, 0.5, 0.6),
   	placement = "wall",
   	replacesWall = false,
   	editorIcon = 92,
}
Now all you have to do is:
1. make it the same for upper alcove,
2. set properties of both (all 4 actually as there are two on each) to have replaceWall = false (it might prevent clipping)
3. spawn two of them on the same wall,
4. spawn a keyhole or small button in the middle
5. onactivate = combineItems()

this might be easier to read (and implement) if each alcove could contain only one item (like you showed us the code on previous page)
and you've made yourself a transformation machine :)

Re: (Object Asset) Empty Catacomb as Alcove

Posted: Sat Sep 29, 2012 9:04 am
by Neikun
It's really easy to place a lock in the middle of the catacombs because of a lock's convenient 'height' parameter.

It'd be neat, once John's model editor gets further in it's devs, we could like turn a lever sideways. Should fit nicely that way.

Other fun things I want to try:
Pressure plate on a wall as a button.
"A button so big, you couldn't miss it!"

Re: (Object Asset) Empty Catacomb as Alcove

Posted: Sat Sep 29, 2012 10:33 am
by Blichew
Suggestion:
add height parameter to new button model, aswell as add width property so we can technically have a wall with 9 buttons :)

Re: (Object Asset) Empty Catacomb as Alcove

Posted: Sat Sep 29, 2012 12:22 pm
by Komag
we should maybe come up with a list of standard "large" items that are good to test in custom alcoves to see how they fit, like:
- ogre hammer
- boots of Valor
- etc
(I don't know if those need to be on the list, just random guesses)

Re: (Object Asset) Empty Catacomb as Alcove

Posted: Sat Sep 29, 2012 3:01 pm
by Neikun
Blichew wrote:Suggestion:
add height parameter to new button model, aswell as add width property so we can technically have a wall with 9 buttons :)
I've posted this on the feature request topic 8-)

Also, if you want some really funny looking antics, paste this into your items.lua
Play around with picking it up and throwing it.

Code: Select all

defineObject{
   name = "chocolate",
   class = "Item",
uiName = "Chocolate",
weight = 10,
   model = "assets/models/env/dungeon_pillar.fbx",
gfxIndex = 130,
   castShadow = true,
   animation = "assets/animations/env/healing_crystal_spin.fbx",
   particleSystem = "crystal",
   placement = "floor",
        repelProjectiles = true,
        hitSound = "impact_blade",
        editorIcon = 100,
}
I decided this needed a video.
http://youtu.be/IN8sL1GGUyM

Re: (Object Asset) Empty Catacomb as Alcove

Posted: Sat Sep 29, 2012 3:24 pm
by Batty
Blichew wrote:1. make it the same for upper alcove
Here, looks neat next to the bones:
SpoilerShow
Image
I put a sword along with the boots in the upper alcove. You can just see the hilt in the center if you look carefully.

However, if you mouselook:
SpoilerShow
Image
There's the sword! This makes mouselook relevant beyond just looking at the scenery. Might make for interesting situations such as:

"You said the sword of unrelenting slashing was in the upper alcove! Liar!"

"Um...well, did you mouselook?"

"Uhh...no... :oops: "

Just made another logical alcove and raised/shifted anchorPos & targetPos until it looked right:

Code: Select all

defineObject{
   	name = "dungeon_catacomb_alcove_upper",
   	class = "Alcove",
   	anchorPos = vec(0.5, 1.85, 0.3),
   	targetPos = vec(0.5, 1.85, 0.2),
   	targetSize = vec(0.6, 0.5, 0.6),
   	placement = "wall",
   	replacesWall = false,
   	editorIcon = 92,
}

Re: (Object Asset) Empty Catacomb as Alcove

Posted: Sat Sep 29, 2012 3:37 pm
by Neikun
That's a really cool idea!
Thanks, Batty.

Re: (Object Asset) Empty Catacomb as Alcove

Posted: Sat Sep 29, 2012 3:48 pm
by Batty
Neikun wrote:That's a really cool idea!
Thanks, Batty.
It's a good place to stash an important key because you can just see the key's sparkle effect if you look carefully.

Of course, some will enjoy examining everything in a dungeon carefully and others will find it annoying.