Product Chat / Why does this happen?

Author
Message
Earthling45
7
Years of Service
User Offline
Joined: 3rd Sep 2016
Location: Zuid Holland Nederland
Posted: 21st Jan 2017 00:58
With the upcoming EBE update i've started to make doors in different styles with a doorpost attached so placing it is becomes very easy.
In the same way i also want to make several windows in different styles, but there are a few problems that i encounter, and have encountered before in other assets, also in the game from Wolf.

This problem is the enormous drop in fps as you can see near the end of the video, at first i thought the shaders, but switching of SAO and Bloom did not result in a better framerate like before with a building from megapack one.
So i'm really wondering what is causing it?

The second problem is the collisionbox.
I've added collisionbox = 1 to the FPE and it works as you can see in the video, but after opening the door, there is no collisionbox anymore, also not after closing the door.
Without that line in the FPE, it is temporary off when the door is open, after closing the door, the collision works again.
Is there a way to solve this or is there only this work around like simply remove that line?






Attachments

Login to view attachments
OldFlak
GameGuru TGC Backer
9
Years of Service
User Offline
Joined: 27th Jan 2015
Location: Tasmania Australia
Posted: 21st Jan 2017 02:29
Hi Earthling45,

The default door.lua needs fixing

Here is a modified version I use for my doors.

hth

Reliquia....


Intel(R) Core(TM) i3-4160 @ 3,60GHz. 8GB Ram. NVidia GeForce GTX 750. Acer 24" Monitors x 2 @ 1920 x 1080. Windows 10 Pro 64-bit.

Attachments

Login to view attachments
PM
Earthling45
7
Years of Service
User Offline
Joined: 3rd Sep 2016
Location: Zuid Holland Nederland
Posted: 21st Jan 2017 03:23
Hi reliquia,

Thanks for this fix.
Teabone
Forum Support
17
Years of Service
User Offline
Joined: 8th Jun 2006
Location: Earth
Posted: 21st Jan 2017 03:32 Edited at: 21st Jan 2017 23:05
OH I thought I was the only one encountering this issue.. and It thought it was something i was doing wrong.
Twitter - Teabone3 | Youtube - Teabone3 | Twitch - Teabone3 | TGC Assets - Store Link

i7 -2600 CPU @ 3.40GHz - Windows 7 - 8GB RAM - Nivida GeForce GT 740
OldFlak
GameGuru TGC Backer
9
Years of Service
User Offline
Joined: 27th Jan 2015
Location: Tasmania Australia
Posted: 21st Jan 2017 05:48 Edited at: 21st Jan 2017 05:56
Hi Earthling45, you are welcome

By the way if you want to adjust so it is activated a little farther away from the door play with the '85' in this section of the code.

In the door script it is 100.

And feel free to rename it what ever you want and include with your models and games.
If you change the name make sure you change function _int and _main to match or it won't work.

So if you named it 'deuren.lua' change these lines to:



Reliquia....
Intel(R) Core(TM) i3-4160 @ 3,60GHz. 8GB Ram. NVidia GeForce GTX 750. Acer 24" Monitors x 2 @ 1920 x 1080. Windows 10 Pro 64-bit.
PM
Earthling45
7
Years of Service
User Offline
Joined: 3rd Sep 2016
Location: Zuid Holland Nederland
Posted: 21st Jan 2017 14:13
That is quite a difference, it is quite certain that this problem relates to the collision box.
Somehow it destroys the fps when one is near an entity, if this is sorted it will mean a huge performance gain for GameGuru in my opinion.

I've made a new video in which the same happens, but only with the door opened.



A crazy question maybe, but it is possible to do something similar like is done with trees? i mean only the door itself has collision?
Because than it can be a simple box.
Earthling45
7
Years of Service
User Offline
Joined: 3rd Sep 2016
Location: Zuid Holland Nederland
Posted: 21st Jan 2017 15:23
Instead of directly placing the files in the entity bank, i've now imported them in order to only place one collision box for the door itself without the doorpost.
I've tested it and it does make no difference, this i did with door.lua, will test this tonight or tomorrow again with sb_door.lua.
However, my prediction is that it will solve the collision box, but not the drop in fps which occurs at a certain position in relation to the door.

Attachments

Login to view attachments
smallg
Community Leader
18
Years of Service
User Offline
Joined: 8th Dec 2005
Location:
Posted: 22nd Jan 2017 00:15
ive had this before with some other entities and it was caused by the collision being constantly called - only seems to affect certain models though.
if the sb_door above doesnt help then try this version of the script and see if it still drops the fps
lua guide for GG
https://steamcommunity.com/sharedfiles/filedetails/?id=398177770
windows 10
i5 @4ghz, 8gb ram, AMD R9 200 series , directx 11

Attachments

Login to view attachments
Earthling45
7
Years of Service
User Offline
Joined: 3rd Sep 2016
Location: Zuid Holland Nederland
Posted: 22nd Jan 2017 02:24
Quote: "only seems to affect certain models though."


Yes, that is why i've imported the door this morningh and put one collisionbox at the door only.

This morning the sb_door.lua from Reliquia worked fine, only the framerate dropped dramatically as you can see in the latest video.
This happens when the player is near the door to some extent, but at a certain position in front of the door, it drops to only 5 frames.
Your version did not give me the prompt to open the door, nor was it able to be opened.
I've now switched back to door.lua and erased the line collision = 1 in the FPE, now collision works when the door is closed and there is no collision when the door is opened, but also not a dramatic drop in frames.
Belidos
3D Media Maker
8
Years of Service
User Offline
Joined: 23rd Nov 2015
Playing: The Game
Posted: 22nd Jan 2017 10:42
Quote: "This morning the sb_door.lua from Reliquia worked fine, only the framerate dropped dramatically as you can see in the latest video.
This happens when the player is near the door to some extent, but at a certain position in front of the door, it drops to only 5 frames."


Does the door have a bone?

If I remember right an entity has a bone, and you don't use the character_basix.fx in your fpe it will cause fps dps drops when you're close to and looking at the area of the bone.

You don't actually need to use bones to animate non-character entities, you just need to animate object rotation/location and record it in the modelling program, then it should work fine in ganeguru using the entity_basic.fx

i5, NV960 2GB, 16GB memory, 2x 2TB Hybrid, Win10.
i3 , Intel integrated graphics, 6GB memory, 512GB Generic SATAIII Win8.1.
Intel Celeron (duel Core), Radeon integrated graphics, 4GB memory, 180gB Generic SATAII, WinVista.
Q6600, Intel integrated graphics, 8GB memory, 512GB Generic SATAII, Win7.
Preben
19
Years of Service
User Offline
Joined: 30th Jun 2004
Location:
Posted: 22nd Jan 2017 12:11
Earthling45:

Try this in your .fpe:
collisionmode = 0

Did it fix the fps drop ?
( collision should still work ).
best regards Preben Eriksen,
Earthling45
7
Years of Service
User Offline
Joined: 3rd Sep 2016
Location: Zuid Holland Nederland
Posted: 22nd Jan 2017 12:46
Quote: " you just need to animate object rotation/location and record it in the modelling program, then it should work fine in ganeguru using the entity_basic.fx"


Yes that is how i did it, there is no bone attached to the door.
The animation is set in 3ds max with rotation.

I think smallg is right about the collision constantly being called, hence the framerate drop from 450 to about 130 with only one entity on the map near the player character.
There also seems to be a some sort of interference with both entities which brings the framerate down to almost zero if the player entity is really close to the door.

Earthling45
7
Years of Service
User Offline
Joined: 3rd Sep 2016
Location: Zuid Holland Nederland
Posted: 22nd Jan 2017 13:02
Quote: "Earthling45:

Try this in your .fpe:
collisionmode = 0

Did it fix the fps drop ?
( collision should still work )."


The collision does work when set to 0, but it blocks the entry because the collision does not move.
Earthling45
7
Years of Service
User Offline
Joined: 3rd Sep 2016
Location: Zuid Holland Nederland
Posted: 23rd Jan 2017 00:55


I need to stretch the glass texture, but it works.

I've gone back to door.lua and erased the line 'collisionmode = 1 in the FPE.
This is the best in my opinion because with these settings there is no drop in frame rate which is preferable during gameplay.
Preben
19
Years of Service
User Offline
Joined: 30th Jun 2004
Location:
Posted: 23rd Jan 2017 08:21
Quote: "The collision does work when set to 0, but it blocks the entry because the collision does not move."


Yes you need to use the original door.lua script , it will disable collision, and the door should work normally without the fps drop.

collisionmode = 0 , was more like a test , as i think the problem could be that Lee is regenerating a new collision mesh, when you set collision on in lua , so using 0 would just use the object current mesh and/or bones for collision, and no new collision mesh is needed, so no fps drop.


best regards Preben Eriksen,
Earthling45
7
Years of Service
User Offline
Joined: 3rd Sep 2016
Location: Zuid Holland Nederland
Posted: 23rd Jan 2017 08:59
Hi Preben, as you mention, the collision is disabled when the door is opened.
Without the line in the FPE the collision is enabled again after the door is closed again.
I have bought the interactive pack form Rolfy and i think his approach would be quite suitable, namely that the door closes automatically when the player moves away from the door.
I will ask smallg if he can do something similar with door.lua

Everyone, thanks for the help with this.
This doing and trying certainly makes one learn a lot, yesterday i made use of skyscroll_basic.fx for the door and it gave a nice transparent effect.
Earthling45
7
Years of Service
User Offline
Joined: 3rd Sep 2016
Location: Zuid Holland Nederland
Posted: 7th Feb 2017 23:06 Edited at: 7th Feb 2017 23:08
I'll bump this thread instead of making yet another thread from doors and windows crazy earthling45

The windows you'll see in the video are added for download.
This does not contain an N map, you'll need to download the blank_N map which Lee has uploaded this morning.
With textures applied seperately through the .x file itself, it works good but that is of course not the prefered route.
So, i've made a texture atlas in paint.net and it seems to work.
The barrels were placed after i placed the windows and they are visible.

The problem however was that the windowframe was not visible through the glas, after i've redone the frame and made it into one mesh, the frame is also visible.

But on one side, the upper frame and corner are still not visible.
Solid inspector gave everything shiny with no errors in the model after i rechecked it.

So this post comes down to, does somebody have an idea on how to solve this and why it does happen?

Attachments

Login to view attachments
DVader
20
Years of Service
User Offline
Joined: 28th Jan 2004
Location:
Posted: 8th Feb 2017 19:01 Edited at: 8th Feb 2017 19:06
There's definitely an issue with transparent textures as I have similar issues. I saw your other post regarding this issue.

Here you can see the internal light.

Here it has vanished, but should still be visible towards the top.

This only happens when you have to move the mouse to follow the light. If you stand back so you can see the whole thing the light works fine. A very weird bug and I'm not surprised Lee has not got back to me as yet.


SPECS: Q6600 CPU. Nvidia 660GTX. 8 Gig Memory. Win 7.

Attachments

Login to view attachments
Earthling45
7
Years of Service
User Offline
Joined: 3rd Sep 2016
Location: Zuid Holland Nederland
Posted: 8th Feb 2017 20:44
Quite strange indeed, i'm without a clue on what would cause it.

But through my trying i did find a nice way for a scrolling board through the use of the sky scroll shader.

I'm going to abandon the glass for now because it will cast a shadow like a non-transparent model if it is incorporated into a model.

On the bright side, i've learned much by trying

LeeBamber
TGC Lead Developer
24
Years of Service
User Offline
Joined: 21st Jan 2000
Location: England
Posted: 9th Feb 2017 10:55
@DVader : Do you have access to the beta version to confirm it still happens with the latest (I've updated the overlay basic shader to allow light through transparent textures that use this shader such as the glass from the fixtures\windows folder).
PC SPECS: Windows 8.1 Pro 64-bit, Intel Core i7-5930K (PASSMARK:13645), NVIDIA Geforce GTX 980 GPU (PASSMARK:9762) , 32GB RAM

DVader
20
Years of Service
User Offline
Joined: 28th Jan 2004
Location:
Posted: 9th Feb 2017 14:07
It still does it in the beta. It seems the angle you look at it causes the light to vanish. Looking down is okay, looking up does not work.

There's also a weird issue with the light never showing through at all occasionally. I sent you a small demo map awhile ago showing the issue, it shows up as soon as you load it.


SPECS: Q6600 CPU. Nvidia 660GTX. 8 Gig Memory. Win 7.
BenjiBenjamin123
7
Years of Service
User Offline
Joined: 31st Jan 2017
Location:
Posted: 9th Feb 2017 15:51
Good work, guys!
PM
Earthling45
7
Years of Service
User Offline
Joined: 3rd Sep 2016
Location: Zuid Holland Nederland
Posted: 21st Feb 2017 18:33
New doors can be downloaded here
Earthling45
7
Years of Service
User Offline
Joined: 3rd Sep 2016
Location: Zuid Holland Nederland
Posted: 24th Feb 2017 17:22
And back to windows

I've got quite a good result now after redoing the window and making a new texture with lighter blue coloured glass.
Not as nice on the sunside as you can see in the picture, but when the window is placed, it looks rather good



This opens the window to have the ability to place windows which can be opened.
No more 'find key' but find a stairs to reach the window on the second floor or somehow get on the roof because there might be a skylight which can be opened.

Attachments

Login to view attachments

Login to post a reply

Server time is: 2024-04-18 04:49:34
Your offset time is: 2024-04-18 04:49:34