Scripts / Replenishable Shield

Author
Message
GubbyBlips
5
Years of Service
User Offline
Joined: 14th Jan 2019
Location:
Posted: 18th Mar 2022 22:19
Anyone need a replenishable shield system for GG Classic?
Mostly intended for donating to the MAX community, but
.......... BROKEN IN MAX ..............
Works horribly GREAT in GGClassic.
PM
bluemeenie195
5
Years of Service
User Offline
Joined: 28th Oct 2018
Location:
Posted: 19th Mar 2022 11:05
I'm always up for a cool new script GubbyBlips.
Thanks
PM
MK83
GameGuru TGC Backer
17
Years of Service
User Offline
Joined: 10th Jun 2006
Location: Greeneville, TN USA
Posted: 19th Mar 2022 11:52
Quote: "Anyone need a replenishable shield system for GG Classic?"
Cool idea!!
AMD Phenom x4 9850 2.70 Ghz , 6 Gb ram, 2GB EVGA Geforce GTX 750, Win 10 x64 Passmark score: 3091



PM
GubbyBlips
5
Years of Service
User Offline
Joined: 14th Jan 2019
Location:
Posted: 19th Mar 2022 16:50
I hear ya guys. Your votes are good enough for me.

Let me give ya a quick run down; I made the script in GGClassic but intended it to be a MAX asset included in MAX - that is if it's not hated by whomever would choose to allow it's entry into there. So for Classic, I cut a window in a barrel texture so it's transparent, as a test asset, and in GGClassic, it's all working very well.

A very nice and super model creator generously agreed to make a special shield to go along with the script for MAX. Now I put the whole thing in MAX, but discover that the MAX AI is shooting through the transparently textured (object). I've tried all the collision types, but it's still a bust. So the shield seems useless there. Is this because of my ignorance on model settings? Is the MAX AI just not impressed with this shield and shield angry?! ( Ignores transparency, or... detects the slightest portion of player exposure... )

So I gotta do two things... for Classic- basically find a shield.
I have been using modified barrels (the texture) but that's a pretty bland shape.

=== >> So asking ? Do you have the "Classics" assets downloaded? << ===

And secondly I should still get verified permission to supply a modified texture to either the barrel or an object in the "Classics" collection. The shield object can be almost anything, but no quite- it's default orientation is crucial to success.
PM
GubbyBlips
5
Years of Service
User Offline
Joined: 14th Jan 2019
Location:
Posted: 19th Mar 2022 16:54
BTW, I'm going to work on a (very simple) level that I can make into executable (standalone). So that all of this is better clarified and testable, if you want to try that. So hold out for a bit...
PM
AmenMoses
GameGuru Master
8
Years of Service
User Offline
Joined: 20th Feb 2016
Location: Portsmouth, England
Posted: 19th Mar 2022 21:16
Why does it matter what the entity is?

Surely if the shield is 'active' (i.e. in the players possession) then you detect player health reduction and simply reduce the shield by that amount and re-instate the player health back to what it was until the shield is depleted?
Been there, done that, got all the T-Shirts!
PM
GubbyBlips
5
Years of Service
User Offline
Joined: 14th Jan 2019
Location:
Posted: 19th Mar 2022 22:59 Edited at: 19th Mar 2022 23:46
Hi AM.
The shield is an actual physical game asset. You carry it, can drop it, pick up other shields, find a recharge machine to recharge it, etc. If you have it active, it's literally in front of you and blocks enemy fire. It's not a metaphorical (health only) shield- if that's what you was hinting at?

=.=.=
Edit... @ AM maybe I get it now? lol Went into MAX again for a few to test Classic entities, and came back with the word.
Oh, okay, fake a shield is what you are saying? A little disappointing to require that work-around, but that would actually probably do the trick. I'll see how it goes... and will require some more time.
=.=.=

In Classic things are fine and dandy. I used a transparent barrel I cut out a window out of and a SCIFi pack transparent object to test with-- both working nicely. MAX is not being nice about it, I can't stop the AI from shooting through this particular transparent shield that someone kindly designed for the script.
See... https://forum.game-guru.com/attachment/29791
PM
GubbyBlips
5
Years of Service
User Offline
Joined: 14th Jan 2019
Location:
Posted: 20th Mar 2022 00:23
@AM
Back yet again. Actually... as I was going through this pretty complex script already... to find where to add this new fake shield behavior...
Hmmm... there's a definite issue with faking a carried shield. The whole idea is that it works as a carried shield- held in front of you, not a fully enclosed force-field.
So let's say the shield is being held, is active and charged up and everything. But wait- there's someone behind you shooting at you. If you are holding a real shield- at your front, it will not protect you from people shooting you in the back! Darn it!

Hmmm... yeah. Stumped w/ MAX unless someone presents entity properties solution. Do you know anything about transparent collisions in MAX? Could I find an invisible wall and place in front of the shield?
Anyhow, Classic still works...
PM
bluemeenie195
5
Years of Service
User Offline
Joined: 28th Oct 2018
Location:
Posted: 20th Mar 2022 13:44
Yeah, sounds really cool.
Can't wait to play around with it.
PM
AmenMoses
GameGuru Master
8
Years of Service
User Offline
Joined: 20th Feb 2016
Location: Portsmouth, England
Posted: 20th Mar 2022 14:10
Tbh I am surprised it works in GGC!
Been there, done that, got all the T-Shirts!
PM
Pirate Myke
Forum Support
13
Years of Service
User Offline
Joined: 31st May 2010
Location: El Dorado, California
Posted: 20th Mar 2022 16:13
Well after playing with this in GGMax, Finally was able to import the hud as DBO. I used the bare hands folder as a template at its default settings.
Setup a map and set the weapon to the player in FP.
Placed a zombie at some dist in one direction, set the armed response guy in an other direction.
Press test game.
The shield hud animations are working and the shield is with the hands. Gunspec.txt settings need to be adjusted for position (Typical weapons setup).

Play results:
The gun with the gun or that type of weapon, can damage me thru the shield. As I would expect. Went looking for the blocking command, and could not find one. Used to be right mouse button in FPSC, But I dont recall this for a long time now.

Now the interesting thing with the zombie was that it could not damage me at all.

Research into the gunspec files may yield further clues to this.

So I would not say that what you are trying to accomplish is impossible, just maybe the physics system is not set up in this fashion to work with the player hud controls. I am guessing from a non programmer POV that the player HUD is always using ray-casting of some sort to do what it does.
Intel(R) Core(TM) i9-10900 CPU @ 2.81GHz, 32GB RAM, Nvidia RTX 2060 super 8gb, Windows 10 Home 64bit, Screen resolution 1920 x 1080

Intel(R) Core(TM) i5-8400 CPU @ 2.81GHz, 32GB RAM, Nvidia gtx1050ti 4gb, Windows 10 Home 64bit, Screen resolution 1920 x 1080. System Passmark 3774




GubbyBlips
5
Years of Service
User Offline
Joined: 14th Jan 2019
Location:
Posted: 20th Mar 2022 21:37
Alright. That's interesting. Tweaked a little, might work on sound slots when I get a chance.
If anyone wants this for Classic, I have edited the textures for a "Classics" folder asset you may be interested in?
If you already have those assets, I can share that- with permission from any authorized moderator here...
Do I need permission to share (just the altered texture) of a "Classics" entity?
PM
Pirate Myke
Forum Support
13
Years of Service
User Offline
Joined: 31st May 2010
Location: El Dorado, California
Posted: 21st Mar 2022 02:32
General rule of thumb is, if you did not make it dont post it. If it is a free asset, then you can point them to the thread or link.
Intel(R) Core(TM) i9-10900 CPU @ 2.81GHz, 32GB RAM, Nvidia RTX 2060 super 8gb, Windows 10 Home 64bit, Screen resolution 1920 x 1080

Intel(R) Core(TM) i5-8400 CPU @ 2.81GHz, 32GB RAM, Nvidia gtx1050ti 4gb, Windows 10 Home 64bit, Screen resolution 1920 x 1080. System Passmark 3774




GubbyBlips
5
Years of Service
User Offline
Joined: 14th Jan 2019
Location:
Posted: 21st Mar 2022 13:07 Edited at: 19th Jun 2022 23:15
Here's the scripts- but it does require a proper entity to behave like it should.
I used a few different things to test this in-- all explained ad nausea above,
but also the last thing was "Terminal E" for the shield and "Terminal A" for the recharger
in GG Classic "Classics" / SciFi/ Props. I modified the texture which is obviously CRUCIAL.
Those items are free supposedly, but the rights to post even a modified texture is still not certain?

If I get the green light, I will come back after work and supply those crucial components...

Attachments

Login to view attachments
PM
GubbyBlips
5
Years of Service
User Offline
Joined: 14th Jan 2019
Location:
Posted: 21st Mar 2022 13:19
"Classics" being used...
PM
bluemeenie195
5
Years of Service
User Offline
Joined: 28th Oct 2018
Location:
Posted: 21st Mar 2022 17:29
It works really well in classic.
I think the key is the thickness of the object your using. Once I figured that out it ran pretty smooth.
PM
GubbyBlips
5
Years of Service
User Offline
Joined: 14th Jan 2019
Location:
Posted: 22nd Mar 2022 02:38
"Once I figured that out it ran pretty smooth."
There is a "slow Player" physic line for when the shield is up... (red-neck style)
But honestly is that totally working, or does player sometimes bump into shield?

Forgot to mention SOUNDS...
There are calls for sound slots in the scripts to activate them, right now they are canceled out.
Just search for sound and you will find them- But a word of caution;

I'm not that familiar with sounds, or understand all orders of operation using them.
With sound I had a crash when using sound on both items together, but if I only used the charger with sound, it worked fine. You can experiment with that and let me know how that comes along? IE- don't do sound experiments in an important map that you just edited with lots of additions you haven't yet saved...
PM
GubbyBlips
5
Years of Service
User Offline
Joined: 14th Jan 2019
Location:
Posted: 29th Mar 2022 02:08
By request;
New, OLD Shield script; shield automatically drops from players hands when depleted of energy.
CANNOT be recharged-- find a new shield!

Actually this was the original behavior until I thought of having recharge stations added.
Take care folks!

.......... Try to pick up more than one shield? Maybe, maybe not. Not so fast!
.......... I think sounds are gone from this early one. Hope you can work those out?

Attachments

Login to view attachments
PM
bluemeenie195
5
Years of Service
User Offline
Joined: 28th Oct 2018
Location:
Posted: 29th Mar 2022 02:46
Can't wait to try it !
Thanks
PM

Login to post a reply

Server time is: 2024-04-25 13:52:42
Your offset time is: 2024-04-25 13:52:42