News | Forum | People | FAQ | Links | Search | Register | Log in
Mapping Help
This is the place to ask about mapping problems, techniques, and bug fixing, and pretty much anything else you want to do in the level editor.

For questions about coding, check out the Coding Help thread: https://www.celephais.net/board/view_thread.php?id=60097
First | Previous | Next | Last
 
First, thank you guys for trying to help, and I'm happy I found this board and happy that people still mod for these games.

I'm still having trouble with this HIERARCH flag though, and I've taken some screenshots to show exactly what I have. I made a new couple of test brushes to test this with as little unknown factors as possible. The brushes are indeed touching, but I can't help but thinking I need to "group" them somehow with a field, no? How can it know that the foundation must break THAT block on top of it, or, does it iterate through every single breakable_brush in the level, and automatically make the connections in code after determining which ones are adjacent? That seems unlikely to me, but definitely not impossible.

Here's what I have:

https://i.imgur.com/DVb9QwB.png 
Decompiler 
So... I figured I could look up one of those BSP decompilers, decompile a Hexen2 bsp back into a map, and just see how they did it (with the bookshelves, etc)

I tried "debsp.exe" (Has the Return to Castle Wolfenstein logo). That one says you need BSPC.exe in the same folder, so I found that, first. That one reports that it "Is not a valid RTCW map, but it decompiled the BSP into a MAP nonetheless." Except; no it didn't, there is no new map file there.

I tried "BSP2MAP.exe". That one takes a long time to run, and displays promising vertex information scrolling at lightspeed in the CMD window when I try to decompile a BSP map. But then it just gets to the end, tells me how many seconds had elapsed, and there is no map file there. I feel like it's quitting prematurely, or else I would imagine it would report in the CMD log that it had successfully exported a new file.

I then realized you can run BSPC.exe by itself (without debsp.exe), so I tried that. That one reports it attempted, by first allocating some memory, and then reports "ERROR: Odd lump size". No new map file.

Btw, I tried all these on:
-demo1.bsp
-village1.bsp
-village2.bsp
-village3.bsp
-village4.bsp
-village5.bsp

I just want to see how their ents are set up. :(

I'm a little confused why these decompilers all failed to create a map file? 
 
So building a map, its a castle there is so many different paths you could take, iam trying to make the level more of an open sandbox that gradually opens up rather than a linear design.

maybe thiniking hiding 3 orbs you need to destroy to bring down a forcefield on the final area.

would it be so bad if entire side areas were just devoted to getting better weapons?

Maybe hide keys in the map just so you can access the vault or armory for the best secrets.

kinda dont really care about rocket jumps either, if you want to speed run it by all means go for it.

What would you do gameplay wise with a very open ended map? 
 
The hexen 2 .bsp format is slightly different than quake, I'm guessing that none of the Quake BSP decompilers will work on it. (RTCW is Quake 3 engine which is also different).

What should work is if you grab my Q1/H2 compile tools from <a href="https://ericwa.github.io/ericw-tools/>here</a>. Extract them copy the bsp's to the same directory, and open a command prompt in the same directory, and run:
"bsputil --extract-entities demo1.bsp"

This should generate a demo1.ent file that you can open in a text editor to check out the entities. 
SgtStabs 
also thinking of coding variables, i had this really cool way of chaining scripted variable outcome events in duke3d via a shooter and breakables that activate when broken.

so you set up a nail shooter, far away of the map, and put breakable brushes in the shooters path, as the shooter activates it will take out brushes in the chain, some are just duds to delay activations, then you add in 2 doors that close / open based on your postion in the level, which will give the variable outcome when one door closes blocking a chain and opens another door with a different script chain with the variable outcome. 
Target And Targetname 
I feel very stupid.

Thank you for that tool - (I actually already had it downloaded today, but was unaware of the extract entities command)

After finding the shelf entities and looking at how they were set up I made the realization:

Previously, since I knew - for sure - that breaking certain brushes in Hexen 2 could, in turn, potentially break MULTIPLE brushes, I automatically assumed that they used the HIERARCH flag. Because there are more than just two ents involved, I assumed the target/targetname combo was inadequate.

I was wrong - Breaking a shelf (i.e. "shelf1"), just targets multiple ents, all with the same targetname ("shelf1").

Oh boy...

So they never used HIERARCH, at least, not in demo1.bsp

I will assume, for now, that the HIERARCH code doesn't actually work, but, if I come across a spot where it is indeed used in-game (which I could now verify with your ent export), then I'll post back here. (Note: ORDERED *does* work, and is used. It can be seen on the bridge in demo1.bsp)

Thank you!

On another note, would that mean I am out of luck on the bsp-to-map decompilers? Even if not to examine ents, I might need to look at how something else was done later on. (I know this can be an iffy subject, but the goal here is only learning, rather than stealing or modifying Raven's work) 
Sgtstabs 
here is example of variable outcomes

if you walk over the yellow qsymbol before the red quake symbol, you will change the outcome, if you walk over the red tile first you will get a different outcome
no external coding, just chain reactions made from stock map tools.

http://www.quaketastic.com/files/variablestest.map 
SgtStabs 
few overlooked fixes with this new version

depending on which quake symbols you stand on first will decide whether a shambler or vore will spawn.

no external code aside some quoth tools.

http://www.quaketastic.com/files/variables.map 
Hexen 2 - Ambient Sounds, Other Than The Listed Ones? 
Another Hexen 2 mapping question --

My level has a mix of physical geometry torches (with i.e. light_flame_small_yellow sitting on top), and the full "model" torches which include the torch itself and the flame all in one model.

For both the full model torches, and the light_flame_small_yellow (etc) versions, their light value can be manually adjusted, which I have taken advantage of.

However, the full model torches emit no sound - only the geometry torches emit the torch sound. (actually, of course, it is the light_flame_small_yellow that is hard-coded to emit the torch sound)

I noticed this while playing single player Hexen II also, and always thought it was weird. The full 3D model torches were dead silent, and the torches creates with geometry + the flame model on top made sound.

Naturally I assumed I can just add a "sound_ambient" and add a torch sound, near all of my silent torches. However, the ambient sounds you can choose from in sound_ambient seem hard-coded too... They don't include all of the sounds in the game:

"soundtype" values :

1 - windmill
2 - dripping, echoing sewer water sound
3 - dripping water with no echo
4 - subtle sky/wind
5 - crickets / night sounds
6 - birds
7 - raven caw
8 - rocks falling
9 - lava bubble
10 - water gurgle
11 - metal
12 - pounding
13 - random moans and screams
14 - creaking
15 - chain rattling

Is there any way I can get around this, and have those silent 3D model torches emit sound also? 
Sound_ambient 
Set key|values:
soundtype | 0
noise1 | "raven/flame1.wav" 
Actually 
Just place an entity and rename it to FireAmbient.

Be sure to caputalize the F and the A. 
 
Ahh.....I don't suppose you have seen an error like this before?

https://i.imgur.com/i8XMJCV.png

Not knowing how to make a blank Entity, the first thing I noticed was that even BSP/geometry has a classname - "worldspawn". I made a new cube, and renamed worldspawn to FireAmbient. The block stayed as a blocked, so I immediately deleted it.

Then I tried the "raven/flame1.wav" method. First I tried it without quotes, then with quotes. Both attempts gave me that error above when I tried to run my map - and since I assumed the problem was those torches, I removed them, but the error stayed. It could be a coincidence but it's probably more likely that I've done something (wrong) that the editor/engine didn't like.

I noticed you can open up the .map file in Notepad, but I couldn't see anything that looks corrupt or wrong, like an "empty" entity or anything, but then again I might not know what to look for error-wise. :( 
 
And unfortunately I have no backup of the map. I can open it up in the map editor, but I can't run it in game currently 
Precache 
The engine needs to have the sound precached before you can use it (ya I know why not just precache on the fly, Darkplaces does). Typically something like light_small_flameyellow will precache its flame model and sound. Put one in and see if that helps. Also don't use quotes.

To make any point entity:
Add something like info_null
Rename it to desired function name, in this case, FireAmbient.
Not sure what editor you are using but should be able to edit the entity name regardless if it is in the fgd or not. 
Wait! 
You didn't rename the only brush entity named worldspawn did you? If so, then your map has no actual map. Check the .map in nofepad and see if the top emtity is named worldspawn. Worldspawn is what all the non-entity brushes use. 
 
Ah! Ya, you renamed worldspawn. Worldspawn precaches all the models and sounds so thats why you have a precache error.

Um, not sure how you did that. What editor are you using?

You may need to in the editor:
Copy all map contents
open a new map
Paste

To get worldspawn back. 
We're Back! 
https://i.imgur.com/1VGZAlF.png

I opened it in Notepad again and checked the top/first entity - yes, you were right - the top entity looked like this, in my map:

//BSPMAPTYPE0001
{
"wad" "demo1.wad"
{

I changed it to

//BSPMAPTYPE0001
{
"wad" "demo1.wad"
"classname" "worldspawn"
{

And the map works again :)

The editor I'm using is called "BSP" by Yahn Bernier. To be honest, I like the editor a lot. I haven't had many issues with it until just then. I find it easier to create and manipulate brushes than in Hammer, which I used to use for Half-Life/Half-Life 2, and EXCEEDINGLY easier to create and manipulate brushes than in UnrealEd 1.0, which I used to use for Unreal and Deus Ex.

Normally, in this ("BSP") editor, I click on a thing to highlight it, and I can edit its fields in the properties window on the left, and (I assume) it only changes that single entity. I created a new, floating block, selected only that block, and renamed its classname to FireAmbient. After realizing that nothing happened (the block remained a brick-textured block), I deleted it. Somehow I suppose that messed up worldspawn for the entire map. :)

Here is a shot of the editor:

https://i.imgur.com/rPohgvA.png

In the past, I had tried setting up some other editors first, for Hexen II - I know one of them I definitely tried to set up was called QuArK. I couldn't get it set up properly. "BSP" was the only one I finally figured out how to set up for H2. 
Cool 
I tried to find BSP Editor one day but couldn't find it. Where did you download it?

I just stick with JACK/Hammer. TB2 is pretty cool, though, you should try it.

Did FireAmbient work? 
FireAmbient 
Also, the "FireAmbient" entity way worked, however, I thought it might be better to use the method you suggested first, to give the actual torch soundtype: 0 and noise1: raven/flame1.wav

That way (with the raven/flame1.wav) didn't seem to work though, is there maybe another field that it needs to play the sound, like a sound_radius or something?

Also, is there any way you could suggest that I learn about all these hidden variables? It seems to me that it's important to know how to modify values beyond what the editor 'wants' you to see.

Thanks again for the help : ) 
BSP 
Source Code 
I've never actually played Hexen II (looks interesting tho), but the hcc source code contains all "entities".

Each entity is actually just a function name in the code. When a level is loaded, all entities are found and their corresponding function is ran. You probably won't find FireAmbient on any fgd or entity definition file because it was really only intended as a way to quickly add the ambient in the code fotr all the fire lights without as much copynpaste.

Source can be found here: http://www.insideqc.com/h2tut/h2started.htm

sound.hc has the code for sound_ambient. 
 
No joke Hexen 2 is one of my all-time favorite old games. I liked Hexen 1, but I actually have a lot more fun playing Hexen 2. I think it has to do with that in Hexen 1, a lot of the levels/worlds start to feel like abstract ideas rather than actual, physical places. In Hexen 2, you have physical "real" landmarks, like a castle with a drawbridge, a mill, a pasture with trees, a medieval butcher's shop with a meat cellar, etc.

Some levels (like Winnowing Hall) in Hexen 1 had seemingly "real" locations too, but once you get to the HUB in H1, it's like: "This is the ice world" "This is the fire world". They just seemed a little abstract.

Furthermore, in the Quake engine, you can sprint around really fast (at admittedly ridiculous and unfair speeds if you exploit it - there is no stamina bar) and jump and dodge projectiles and stuff.

Most Hexen 2 levels have the format of: Bring you past a locked door, or puzzle that you can't solve yet, and also give you another pathway. The puzzle piece/key being down that pathway, which means you have to backtrack to the locked door after you find it.

Apparently, (I read some reviews) some people hated the backtracking and puzzles aspect of H2. They got frustrated, and either gave up and stopped playing, or cheated to skip past. I never had such problems. I think the first time I beat Hexen 2, I was like 12 and I did it without guides. Some puzzles I never understood the logic for, (there is one puzzle in the Egypt world where you have to align two wheels to constellations or something) but can be solved by guessing and checking.

i.e. A+A no, A+B no, A+C no ..... D+E no, D+F no, D+G "sequence complete!"

And personally I love the art style and enemies of H2. They all look awesome. And just like in Hexen 1, you feel very "alone". There's no NPCs or shops, just you, and a bunch of demons and weird puzzles in creepy locations. 
Core Function Calls? 
So I loaded up all of the .hc files in Visual Studio so that I can easily ctrl+F through all of them at once -

The definition of FireAmbient is :

void ()FireAmbient =
{
precache_sound ( "raven/flame1.wav");
ambientsound ( self.origin, "raven/flame1.wav", 0.50000, ATTN_STATIC);
};

Well, I know that I already have "origin" defined in my wall torch (it's automatically there), and I know that that second field is "sound1" which I've added too. I don't know what the 3rd field (0.50000 value) is, but I assume it's either something that controls the radius or volume (or both), and I assume ATTN_STATIC is for sounds that just constantly repeat (not sure), but I know the value for it is "3", but I don't know the field name that it goes to.

So I figured I would just look up the function definition for ambientsound() but it's just like... not in any of the files? And neither is sound(). There are plenty of CALLs to those functions, and the DECLARATIONs are there:

void (vector a, string b, float c, float d)ambientsound = #74;

-- but no definitions.

Btw, placing the separate FireAmbient entities works just fine, but I was hoping to get the ambient sound to work by coming straight from the torch entities instead -- really this is mostly for learning. Now that I know I can look at the code, things are much clearer, and if not for these core function defs missing, I assume I could've found out what those missing fields were. Any ideas? 
 
Also, just to avoid confusion:

sound_ambient() IS defined in sound.hc. But sound_ambient() calls something called ambientsound(), which is the one I can't find the definition for anywhere. 
Ambientsound() 
After googling a lot I finally found this piece of code in some Quake dev forum post:

ambientsound (self.origin, self.soundpath, self.vol, self.attn);

This would imply that those missing fields (3 and 4) I was looking for were simply "vol" and "attn". Unfortunately when I tried them -- I added "vol" "0.5" and "attn" "3", which are the same values that FireAmbient would use -- I got "VOL is not a field" "ATTN is not a field" in the Hexen 2 console upon loading the map.

Hmm.. 
First | Previous | Next | Last
You must be logged in to post in this thread.
Website copyright © 2002-2024 John Fitzgibbons. All posts are copyright their respective authors.