a_person
08-16-2004, 11:14 PM
Ok I need to get a cog that makes it when you use a bacta aswell as giving the health it also makes all the surfaces in the level get a face flag value of 2. After 10 seconds they all change back to thier origonal state. Here is a bacta cog to save you time.
# Jedi Knight Cog Script
#
# ITEM_BACTA.COG
#
# INVENTORY script - Bacta Tank
#
# [CYW & YB]
#
# (C) 1997 LucasArts Entertainment Co. All Rights Reserved
# ================================================== ======================================
symbols
sound bactaSnd=BactaUse01.WAV
thing player
message activated
end
# ================================================== ======================================
code
activated:
player = GetSourceRef();
if(GetInv(player, 40) > 0.0)
{
if(GetHealth(player) < 100)
{
// Print("Using Bacta");
jkPrintUNIString(player, 250);
PlaySoundThing(bactaSnd, player, 1.0, -1, -1, 128);
HealThing(player, 30.0);
ChangeInv(player, 40, -1.0);
if(GetInv(player, 40) == 0) SetInvAvailable(player, 40, 0);
}
}
Return;
end
Thanks.
------------------
~Nightfire Mod (http://www.nightfire.uni.cc)~
# Jedi Knight Cog Script
#
# ITEM_BACTA.COG
#
# INVENTORY script - Bacta Tank
#
# [CYW & YB]
#
# (C) 1997 LucasArts Entertainment Co. All Rights Reserved
# ================================================== ======================================
symbols
sound bactaSnd=BactaUse01.WAV
thing player
message activated
end
# ================================================== ======================================
code
activated:
player = GetSourceRef();
if(GetInv(player, 40) > 0.0)
{
if(GetHealth(player) < 100)
{
// Print("Using Bacta");
jkPrintUNIString(player, 250);
PlaySoundThing(bactaSnd, player, 1.0, -1, -1, 128);
HealThing(player, 30.0);
ChangeInv(player, 40, -1.0);
if(GetInv(player, 40) == 0) SetInvAvailable(player, 40, 0);
}
}
Return;
end
Thanks.
------------------
~Nightfire Mod (http://www.nightfire.uni.cc)~