ToxinSuit

Tutorials and discussions about Mapping - Introduce your own ones!
User avatar
[NBK]DxTrEm3Fx
Experienced
Posts: 137
Joined: Wed May 09, 2012 5:56 pm
Location: Glendale, AZ

ToxinSuit

Post by [NBK]DxTrEm3Fx » Sat Jun 25, 2022 8:58 pm

Hello All,
I have placed some ToxinSuits in my map and was wondering if there is a way to shorten the duration of time it stays active while wearing it? When I pick up the suit in the game it stays active and never goes away. I can keep jumping in the slim without consequences. I want to add a timer to the duration say 30 sec. But I also want to suit to respawn after pick up. The code isn't really telling me anything and I do not see a duration time of effect in the properties.

Code: Select all

class ToxinSuit extends Suits;

#exec AUDIO IMPORT FILE="..\UnrealShare\Sounds\Pickups\ARMOUR2.WAV"  NAME="ArmorSnd"      GROUP="Pickups"

#exec MESH IMPORT MESH=ToxSuit ANIVFILE=..\UnrealShare\MODELS\Suit_a.3D DATAFILE=..\UnrealShare\MODELS\Suit_d.3D X=0 Y=0 Z=0
#exec MESH ORIGIN MESH=ToxSuit X=0 Y=100 Z=40 YAW=64 ROLL=64
#exec MESH SEQUENCE MESH=ToxSuit SEQ=All STARTFRAME=0  NUMFRAMES=1
#exec TEXTURE IMPORT NAME=AToxSuit1 FILE=MODELS\bToxSuit.PCX GROUP="Skins"
#exec MESHMAP SCALE MESHMAP=ToxSuit X=0.04 Y=0.04 Z=0.08
#exec MESHMAP SETTEXTURE MESHMAP=ToxSuit NUM=1 TEXTURE=AToxSuit1
Image

User avatar
Aspide
Experienced
Posts: 109
Joined: Wed Jun 09, 2021 12:13 am

Re: ToxinSuit

Post by Aspide » Sat Jun 25, 2022 9:11 pm

You'll have to create a new subclass of ToxinSuit with new behavior so it runs out after a specific amount of time, the original ToxinSuit isn't coded to run out after time, it behaves like a normal armor except that it protects you from slime.
Somewhere in Nevada...

User avatar
[NBK]DxTrEm3Fx
Experienced
Posts: 137
Joined: Wed May 09, 2012 5:56 pm
Location: Glendale, AZ

Re: ToxinSuit

Post by [NBK]DxTrEm3Fx » Sat Jun 25, 2022 10:35 pm

Aspide wrote:
Sat Jun 25, 2022 9:11 pm
You'll have to create a new subclass of ToxinSuit with new behavior so it runs out after a specific amount of time, the original ToxinSuit isn't coded to run out after time, it behaves like a normal armor except that it protects you from slime.
I will search for any tutorials on creating a new actor subclass. I'm pretty sure this will be out of my skill set. Thank you for the info I appreciate it.
Image

User avatar
Barbie
Godlike
Posts: 2394
Joined: Fri Sep 25, 2015 9:01 pm
Location: moved without proper hashing

Re: ToxinSuit

Post by Barbie » Sat Jun 25, 2022 11:48 pm

[NBK]DxTrEm3Fx wrote:
Sat Jun 25, 2022 8:58 pm
a way to shorten the duration of time it stays active while wearing it

Code: Select all

class MyToxinSuit expands ToxinSuit;

function BecomeItem() {
	Super.BecomeItem();
	LifeSpan = 10; // remaining life time in seconds
}
But this easy version does not give any hint when the Suit dissolves.
You do not have the required permissions to view the files attached to this post.
"Multiple exclamation marks," he went on, shaking his head, "are a sure sign of a diseased mind." --Terry Pratchett

User avatar
[NBK]DxTrEm3Fx
Experienced
Posts: 137
Joined: Wed May 09, 2012 5:56 pm
Location: Glendale, AZ

Re: ToxinSuit

Post by [NBK]DxTrEm3Fx » Sun Jun 26, 2022 3:17 am

Barbie wrote:
Sat Jun 25, 2022 11:48 pm
[NBK]DxTrEm3Fx wrote:
Sat Jun 25, 2022 8:58 pm
a way to shorten the duration of time it stays active while wearing it

Code: Select all

class MyToxinSuit expands ToxinSuit;

function BecomeItem() {
	Super.BecomeItem();
	LifeSpan = 10; // remaining life time in seconds
}
But this easy version does not give any hint when the Suit dissolves.
You are a Superhero thank you, Barbie. I appreciate your help. I've updated the time to 30 sec which should fit the timeline needed to grab the Nuke and make it back. I'm not too worried about when it dissolves.
Image