Product Chat / Decals with physics?

Author
Message
GubbyBlips
5
Years of Service
User Offline
Joined: 14th Jan 2019
Location:
Posted: 7th Oct 2019 01:26
Anybody know how it could be possible to put in decals on map and use
the engine physics (gravity, collision, etc) active with them?
Is there some kind of setting for that? Thanks.
PM
AmenMoses
GameGuru Master
8
Years of Service
User Offline
Joined: 20th Feb 2016
Location: Portsmouth, England
Posted: 7th Oct 2019 20:10
Um, decals have no thickness or mass so they aren't going to work for that, what you could do is have a real entity with a decal (or better still a particle) positioned on it. Like this:
Been there, done that, got all the T-Shirts!
PM
GubbyBlips
5
Years of Service
User Offline
Joined: 14th Jan 2019
Location:
Posted: 7th Oct 2019 20:51
Pretty funny, but cool looking!
Sounds like you are talking about real quantum mechanics and photons!
So what's the difference between decals and particles?
How do you create a particle?
So... you are moving a standard object, and pasting the particle onto it?
PM
smallg
Community Leader
18
Years of Service
User Offline
Joined: 8th Dec 2005
Location:
Posted: 7th Oct 2019 20:53
nice video, the hinges on the hanging board are a nice touch
lua guide for GG
https://steamcommunity.com/sharedfiles/filedetails/?id=398177770
windows 10
i5 @4ghz, 8gb ram, AMD R9 200 series , directx 11
AmenMoses
GameGuru Master
8
Years of Service
User Offline
Joined: 20th Feb 2016
Location: Portsmouth, England
Posted: 7th Oct 2019 21:21 Edited at: 7th Oct 2019 21:23
Here's the script.
Been there, done that, got all the T-Shirts!

Attachments

Login to view attachments
PM
GubbyBlips
5
Years of Service
User Offline
Joined: 14th Jan 2019
Location:
Posted: 7th Oct 2019 22:47
Radical!
Now here's another question; I am using the MoveForward command,
and I would like to detect collision on the forward direction.

I've had success with an entity that was moved dynamically (x,y,z),
but the forward direction is at any angle independent to x,y,z.

How would that look? I checked in on your physlib.lua and found
GetViewVector() and function P.ObjectPlayerLookingAt
These seem to be exactly what we need (if born unto an entity) for this quest.

So, something like this for any object using forward angle to raycast
in that direction would be a great function to have!
Something like CollisionCastForward(e,distance)
Any ideas?
PM
GubbyBlips
5
Years of Service
User Offline
Joined: 14th Jan 2019
Location:
Posted: 7th Oct 2019 22:53 Edited at: 7th Oct 2019 23:29
It would also probably be the ~opposite~ of doing;
/////////////////////////
getRealWorldYangle( xa, ya, za ) -- Euler in degrees, returns radians
////////////////////////
or...
////////////////////////
P.GetViewVector()
return rayX, rayY, rayZ
;;;;;;;;;;;;;;;;;;;
function P.ObjectPlayerLookingAt( dist, force )
local dist = dist or 2000
local force = force or 0
/////////////////////////
or...

the Function for turn to coordinates;
function RotateToPoint(e,x,z)

if g_Entity[e] ~= nil and x > 0 and z > 0 then
local destx = x - g_Entity[e]['x']
local destz = z - g_Entity[e]['z']
local angle = math.atan2(destx,destz)
angle = angle * (180.0 / math.pi)
if angle < 0 then
angle = 360 + angle
elseif angle > 360 then
angle = angle - 360
end
SetRotation(e,0,angle,0)
return angle
end
end

hmmm....? so how to transform that?!
PM
JC LEON
14
Years of Service
User Offline
Joined: 22nd Apr 2010
Location:
Posted: 8th Oct 2019 09:28
Amen i could sell my soul to the devil to have your skills
PC Specs:
AMD QUADCORE 880K @4.5GHZ, 32GB RAM DDR3 1600, M/B ASUS A88XM-PLUS
SVGA NVDIA 1660GTX 6GB , SSD KINGSTON A400 1TB, 2X HHD SEAGATE BARRACUDA 4TB
PM
Duchenkuke
GameGuru VBOTB Developer
8
Years of Service
User Offline
Joined: 7th Jun 2016
Location: Germany
Posted: 10th Oct 2019 08:21 Edited at: 10th Oct 2019 10:09
Quote: "Amen i could sell my soul to the devil to have your skills"


............................


this forum is not fun anymore... pls just stop!!
Damn it, man.
JC LEON
14
Years of Service
User Offline
Joined: 22nd Apr 2010
Location:
Posted: 10th Oct 2019 09:46
hihhiihihi
PC Specs:
AMD QUADCORE 880K @4.5GHZ, 32GB RAM DDR3 1600, M/B ASUS A88XM-PLUS
SVGA NVDIA 1660GTX 6GB , SSD KINGSTON A400 1TB, 2X HHD SEAGATE BARRACUDA 4TB
PM

Login to post a reply

Server time is: 2024-10-06 22:22:06
Your offset time is: 2024-10-06 22:22:06