View Full Version : I have just seen something horrible...
DiaZ
8th September 2002, 23:37
In one of the maps I am working on, I made a small bathroom with a mirror on it, that certainly looks neat. It runs fine when I have started the map and have not killed anyone. But I noticed that going back to the bathroom after killing everyone on the map would have a severe impact on performance (19 fps...) I used r_showtris to see if I could see what was happening, and Oh my God. All the corpses on the map were being drawn. Who in the Wolfenstein development team came up with this idea? Well, my question is, could this be fixed with code, or am I forced to remove that nice looking mirror? I can't code myself, but well, if I knew it could be fixed, I can at least keep it knowing things will run better in the future. It's not only about that mirror, but actually it is a pretty pointless thing... :/
kat
9th September 2002, 00:44
<font size="2">that's a pretty old bug unfortuanately, I reported this to the powers that be but heard nothing so I guess they don't think it's important :sad:
It'a actually got nothing to do with the mirror, you can be in a box room in the middle of Caslte Wolfenstien and still get the problem.. Karlof wrote a fix for it in script but it completely removes the bodies from the map
http://64.91.236.18/cgi-bin/ultimatebb.cgi?ubb=get_topic;f=12;t=000093
http://www.map-center.com/cgi-bin/ultimatebb.cgi?ubb=get_topic;f=12;t=000255
there are some piccys posted further down, is that what you ment??
</font>
_________________
<font size="2">nothing to add your honour.... except... maybe quake3bits (http://www.quake3bits.co.uk)?? Is that alright??</font size="2">
<font size=-1>[ This Message was edited by: kat on 2002-09-09 01:53 ]</font>
<font size=-1>[ This Message was edited by: kat on 2002-09-09 01:58 ]</font>
Hewster
9th September 2002, 00:46
DiaZ,
mmm, I think you're problem may be bad vis / hinting ?
Make sure your mirror cannot 'see' too much of
the world, by carefully constructing structual
brushes, and hint brushes around your bathroom.
Tutorials can be found here:
http://www.nibsworld.com/rtcw/tutorial_detail_and_hint_brushes_part1.shtml
and here:
http://fps.brainerd.net/hintbrushes.htm
hope this helps
Hewster
<font size=-1>[ This Message was edited by: Hewster on 2002-09-09 01:47 ]</font>
DiaZ
9th September 2002, 00:52
The only thing the mirror can see is the bathroom itself (after seven years mapping I think I've learnt how to place hint and vis blocking brushes :] ) and it's obviously due to this bug. Guess I'll have to make the corpses disappear, that should be fairly easy to code... but it will take an important element out of my mod's gameplay :/
And what I mean by the mirror affecting it... well that's not it exactly... but a mirror generates a lot of extra polygons, so if we add those from the corpses, things get chuggy...
<font size=-1>[ This Message was edited by: DiaZ on 2002-09-09 01:58 ]</font>
Hewster
9th September 2002, 01:54
ok,
I see what you mean from those pic's
on the link kat....
Is this just a SP issue?
Hewster
Ghast
9th September 2002, 03:38
Do corpses lie around for players to trip over in MP? Medic! *G* Maybe in Enemy Territory when there are bots? Disolve your dead? Don't like SOF2 for its disappearing bad guys. You can hack a guy's face off, pick him up, hide him, but why? Hang around for awhile and they melt off to the same place gibs and wood splinters go, sometimes leaving behind perfectly good body armor??? Code your game so a grenade goes off if too many bodies spoil the fun?
<font size=-1>[ This Message was edited by: Ghast on 2002-09-09 04:50 ]</font>
<font size=-1>[ This Message was edited by: Ghast on 2002-09-09 04:52 ]</font>
Hewster
9th September 2002, 05:20
Right, this is a issue in SP and MP.
Although in MP test's I've carried out so
far, dead bodys never seem suffer from the
problem, although I may be wrong.
However smoke , wall-marks & dynomite do
(gibs, flames, panzer & air-strikes may also).
In other words every granade explosion is
drawn by the game, as well as the resulting
gibs & decals!
In a busy MP game this could amount to a lot
of extra polys that the game has to draw ?
I will do a more exhaustive tests when I can.
comments ?
Hewster
DiaZ
9th September 2002, 10:23
This has to be fixed. Do they notice they could reduce the system requirements by no less than 30%? I mean, have the bodies be still there, but don't draw them when they are not on the player's PVS, that is plain pointless.
kat
9th September 2002, 13:24
...However smoke , wall-marks & dynomite do
(gibs, flames, panzer & air-strikes may also).
In other words every granade explosion is
drawn by the game, as well as the resulting
gibs & decals!..
<font size="2">I think it relates to all 'dynamic objects'. As we know most of the effects can be switched off from the menu and the nature of MP means "I see dead people"â„¢ melt and respawn.
I agree that this is a major gaff to have missed as the wierd thing is you do showtris with before killing anybody they don't show up, it's only afterwards they do!?
I found the pics I originally posted in that link that goes to the wrong page (moved??) watch the FPS
http://www.btinternet.com/~kenbeyer/rtcw/rtcw1.jpg
http://www.btinternet.com/~kenbeyer/rtcw/rtcw2.jpg
http://www.btinternet.com/~kenbeyer/rtcw/rtcw3.jpg
http://www.btinternet.com/~kenbeyer/rtcw/rtcw4.jpg</font>
DiaZ
9th September 2002, 22:58
You see. That is a 51% performance loss! This has to go! You are right, it doesn't make sense, the dead and alive bodies are suppossed to be the same entity, how come they won't be drawn when they are alive???
By the way, I've added all those scripts to remove the dead corpses. I get 40 fps on the mirror area now - but gameplay is s bit messed up since my mod is stealth-based, and one is suppossed not to leave corpses where other guards can see them :/
kat
10th September 2002, 02:38
.....By the way, I've added all those scripts to remove the dead corpses. I get 40 fps on the mirror area now - but gameplay is s bit messed up since my mod is stealth-based, and one is suppossed not to leave corpses where other guards can see them :/
<font size="2">Oooo, sounds interesting..! any ETA??</font>
DiaZ
10th September 2002, 10:14
What do you mean?
kat
10th September 2002, 12:31
On 2002-09-10 11:14, DiaZ wrote:
What do you mean?
<font size="2">ETA = Estimated Time of Arrival</font>
DiaZ
10th September 2002, 14:44
Sorry, didn't know that :razz: estimated time of arrival... Long. I make all the maps and models myself (except the skins, will need help in that department soon :])... and I've started just 1 month ago...
<font size=-1>[ This Message was edited by: DiaZ on 2002-09-10 15:45 ]</font>
kat
10th September 2002, 16:23
...I make all the maps and models myself (except the skins, will need help in that department soon :])... and I've started just 1 month ago...
<font size="2">I know the feeling... been doing the same ting myself and there will be a lot of new voice content so it's ganna push the file size wayyyy upp there but it's something I think SP 'mods' have to do because of it nature.. single play</font>
DiaZ
10th September 2002, 18:39
Yeah, my mod is going to have tons of new contents as well, maps alone are huge, plus tons of new voices, textures, sounds, music, models... I am expecting something near 500 Mb uncompressed :smile: But at the end... a finished single player mod is something one can really feel proud of.
SCDS_reyalP
10th September 2002, 20:47
I have noticed that moving movers also get drawn from pretty much anywhere on the map. For example, I make a rotating fan out of a script_mover, and it shows up just about everywhere. Movers which are not moving suffer to some extent, but not as much (?)
Blood splats and explosion marks as well.
digibob
10th September 2002, 21:49
Did some digging around in the engine today... and... well, any entity which uses a brush model, can touch a bunch of leafs, but if this goes over 16 different leafs, the whole thing kinda falls apart, and the entity becomes visible from just about anywhere in the map, nothing you can do about it, obviously the larger the entity, the worse it gets.
EDIT: as for other stuff, bleugh.... SP has some rather interesting modifications to the engine which may cause the bodies to appear even if out of PVS, but i only had a small look over it...
<font size=-1>[ This Message was edited by: djbob on 2002-09-10 22:51 ]</font>
KoS
12th September 2002, 18:35
On 2002-09-09 00:37, DiaZ wrote:
I used r_showtris to see if I could see what was happening, and Oh my God. All the corpses on the map were being drawn. Who in the Wolfenstein development team came up with this idea? Well, my question is, could this be fixed with code, or am I forced to remove that nice looking mirror
OK As Kat already said this has nothing to do with mirror. Its bug in q3 engine that draw all killed ai models. There is no way to hinder this, nor by area portal or hints. The only way to fix this is you have to remove (killentity) all laying ai models. By the way; each laying ai models takes about 1000 polys in r_showtris.
In all my 4 aaw maps I removed ai models after they dyes. The way I did it is little tricky and takes lot job but it pays.
In short here is what I have done:
In GTK Radiant I placed following entities as edition to ai_soldier entity:
Target_relay -----Ă target_delay -------Ă target_kill ---Ă ai_soldier
Target_relay has following key values:
Targetname: remove_ai_soldier1
Target: delay_ai_soldier1
Target_delay has following key values:
Targetname: delay_ai_soldier1
Target: kill_ai_soldier1
Time: 30
Target_kill has following values:
Targetname: kill_ai_soldier1
Target: ai_soldier1
Ai_soldier has following key values:
Ai_name: ai_soldier1
Target_name: ai_soldier1
In ai script I have added following statement under (DEATH) on particular ai_soldier.
Death
{
alertentity remove_ai_soldier1
}
Now here is what happens when nazi is killed in RTCW game.
Upon ai_soldier1 death script trigger DEATH portion of this particular ai_soldier1 script.
Which is remove_ai_soldier1, which is name for target_delay entity in GTKRadiant
This entity being alerted alerts target_delay entity that delays its action for 30 second. After that time it alerts target_kill entity that immediately removes ai_soldier1 model from the game.
If I would not use target_delay in this process, target_kill will instantly remove ai model after game detects it is kill by the player. And because “falling death� animation is played after ai technically dyes in game, the ai will disappear in thin air, without even falling to the ground.
I hope this explains how I have approached this problem in my SP maps.
Ghast
12th September 2002, 19:43
Not needing modding for this is Very Cool! Would this be useful for having any model disappear after an enemy is engaged? I want to have a blocked tunnel on another part of the map become unblocked but only after final part of map & final enemies are encountered! *G*
DiaZ
12th September 2002, 22:59
Yeah, as I've said I've added those scripts to my map to make corpses disappear (in my case after 8 seconds, I find that long enough). I know the bug itself doesn't have anything to do with the mirror - but the r_speeds make me suspect all the corpses are being reflected on it, even though r_showtris doesn't show them being drawn on the mirror. When I look at the wall where the mirror is I don't see any corpses, yet the r_speeds are indicating they are being drawn :/
About unblocking part of a tunnel after some enemies are dead, it's possible. I'm not sure if target_kill works on solid entities but you could always have a script_mover with the clip texture over it that just goes away (moves to another position) when you kill the enemies... you can use an accum value to tell this script_mover that all the enemies you want to be dead are in fact dead.
KoS
16th September 2002, 12:27
Targert_kill should work on all entities you use in GTK Radiant including grouped clip brushes
digibob
16th September 2002, 14:52
It will NOT work on func_groups.
Ghast
16th September 2002, 18:19
sorry to go OT on this *G* So I could "kill" a big rock model and "move" its clip brushes, but will probably just keep nosing around in the SP .ai and any other file I can open with notepad, great stuff in there, I love RTCW!
kat
16th September 2002, 19:19
On 2002-09-16 19:19, Ghast wrote:
sorry to go OT on this *G* So I could "kill" a big rock model and "move" its clip brushes, but will probably just keep nosing around in the SP .ai and any other file I can open with notepad, great stuff in there, I love RTCW!
<font size="2">you can't 'group' entity objects together either, ie: if you tried to group a model with a script_mover it won't work... you have to create your script_mover and then use the model2 key...
what you may actually need to do is place the model in your map where you want it to go, take note of where it's center of origin is (the little wireframe cube) and then create a script_mover with it's origin in the same place as the model. You can then add to the SM's properties the key/value pair of 'model2' and 'filepath to model'. What you can do though is using the map placed model as a guide:-
- place all your clipping where you want it to go
- select them
- then select the script_mover already made
- right click and 'ungroup entity'
- whilst everything is still selected re-create the script_mover by right clciking and selecting 'script>script_mover'
- it'll also include the clip brushes as part of that new object.
you then need to trigger an 'alertentity' event to do what ever it is you need it to do (I'm not sure that a simple AE call will remove the entity in question)
It's worth noting that Md2's sometimes don't get lit properly in maps if they have to move great distances (djbob mentioned someting about this nanother post I think)</font>
Ghast
17th September 2002, 22:18
Thank you, read similar posts many many times but yours made more sense! Maybe I am just finally getting it? *LOL*
vBulletin® v3.7.3, Copyright ©2000-2008, Jelsoft Enterprises Ltd.