Massassi Forums Logo

This is the static archive of the Massassi Forums. The forums are closed indefinitely. Thanks for all the memories!

You can also download Super Old Archived Message Boards from when Massassi first started.

"View" counts are as of the day the forums were archived, and will no longer increase.

ForumsJedi Knight and Mysteries of the Sith Editing Forum → healing cog
healing cog
2001-07-06, 7:37 AM #1
hi. i need a healing cog.

a cog that activates when you enter a sector and it slowly heals you up.

and i need intructions on how do use it in the lvl after i ahve the cog.
The Gas Station
2001-07-06, 10:26 AM #2
any1?
The Gas Station
2001-07-06, 10:32 AM #3
You need to ask this question over in the Cog Forum.

[This message has been edited by Jim14 (edited July 06, 2001).]
"It's best to keep your mouth shut and look like an idiot than to open it and prove it"
- Robert Fletcher
2001-07-06, 1:00 PM #4
I asked a buddy of mine this say question a long time ago. Its simple. I dont remember it much, but I think all you gotta do is simply tell it which sector and how much to add.

Code:
#
# This script was made by Red (theensers@mindspring.com)
#
# Copyright (c) Red 1998
#
# 4/8/98 [Red] Cleaned up the Script, and added the ability to change the amount of mana added.
#
# Thanks a bunch Robert Huebner/Jeff Walters

# ========================================================================================

flags=0x40

symbols

thing       powerup                          local
thing       player                           local
int         bin=14                           local

message		startup
message		pulse

sector		tank		      	# The Bacta Tank (sector).

flex		healInterval=1.0		      # How often heath is added in seconds.
flex		heal=5.0			      # How much health is added per pulse.

thing		victim		local		# actors and players affected.
int		type		local
int		mana=25.0			      # How much mana is added per pulse.

end

# ========================================================================================

code

# ........................................................................................

startup:
	if(tank > -1) SetPulse(healInterval);
	return;

# ........................................................................................

pulse:
	victim = FirstThingInSector(tank);
	while (victim != -1)
	{
		type = GetThingType(victim);
		// If we have an actor (2) or a player (10)
		if ((type==2) || (type==10))
		// Heal and add Mana
		{
			HealThing(victim, heal);
			ChangeInv(player, 14, mana);
		}
		victim = NextThingInSector(victim);
	}
	return;

# ........................................................................................

end


------------------
Give yourself up to God as a living sacrafice.
It's not about you, it's about HIM. Its not your life, it's HIS.
Take up your cross daily and walk with HIM.
Have no fear, for the LORD is with you.

Christianity is the only religion in the world where God reaches down to us 'cuz we can't reach up to Him. Aren't you glad He reaches down to us?

_-=MaTRiX=-_
In my mind I can see your face, as Your love pours down in a shower of grace. Some people tell me that Your just a dream, but my faith is the evidence of things unseen.

Once upon a time God spoke to me, and then I was never the same again.

_-=MaTRiX=-_
2001-07-06, 3:54 PM #5
yea, now that you mention it i guess i should have posted it in the cog forums...

and thanks for thatr cog script, but i don't know how to modify it or even use it in the lvl, that is y i need ppls help
The Gas Station
2001-07-07, 6:57 AM #6
You don't need a new cog. Use the LEC sector damage cog and put in a negative value for the damage. That way it will heal you when you enter the sector.

------------------
"Sometimes nothing can be a real cool hand."
Have Lightsaber Will Travel
Have Lightsaber Will Travel JK Editing tips, troubleshooting information, resources and more.
www.swgalaxies.net For all your Star Wars Galaxies needs
The Massassi A SW Galaxies Player Association
2001-07-07, 11:15 AM #7
umm, where can i find this damage cog? and how do you do things like assign it os you heal in a certian sector.
The Gas Station
2001-07-07, 12:10 PM #8
Man, you sound like a newbie. Did you even know you could assign cogs in Jedi Knight?

Look, just when your in JED, hit F7, then click Add Cog or New Cog or whatever it says down in the corner. Then it gives you the list of all of the cogs that comes in Jedi Knight.

If you take that cog coding up there I gave ya, and save it as a .cog file, then you can put it in your level_dirctory\cog and you'll find it there when you push the F7 and do the whole bit, when you go to add, go to the top right corner and check the \cog director thats there.

------------------
Give yourself up to God as a living sacrafice.
It's not about you, it's about HIM. Its not your life, it's HIS.
Take up your cross daily and walk with HIM.
Have no fear, for the LORD is with you.

Christianity is the only religion in the world where God reaches down to us 'cuz we can't reach up to Him. Aren't you glad He reaches down to us?

_-=MaTRiX=-_
In my mind I can see your face, as Your love pours down in a shower of grace. Some people tell me that Your just a dream, but my faith is the evidence of things unseen.

Once upon a time God spoke to me, and then I was never the same again.

_-=MaTRiX=-_
2001-07-07, 1:12 PM #9
I think its 00_sectordamage.cog or something like that.

------------------
"Sometimes nothing can be a real cool hand."
Have Lightsaber Will Travel
Have Lightsaber Will Travel JK Editing tips, troubleshooting information, resources and more.
www.swgalaxies.net For all your Star Wars Galaxies needs
The Massassi A SW Galaxies Player Association
2001-07-07, 1:25 PM #10
Or you could try m5_healingsector.cog..
2001-07-07, 2:30 PM #11
how do i modify this cog so it wirks when you enter a sector?

Code:
# Jedi Knight Cog Script
#
# M5_HEALINGSECTOR.COG
#
# Creates some healing areas in M5
# Just enter the sector to be healed at the rate of
# 'healspeed' hitpoints per second.
#
# This makes a pinging sound telling other players that
# someone uses an Healing Area, so watch out... :-)
#
# [YB]
#
# (C) 1997 LucasArts Entertainment Co. All Rights Reserved

flags=0x40

symbols

sector      healingsc                        desc=heal_sect
flex        healspeed=3.0                    desc=heal_speed

int         player                           local
int         dummy                            local

sound       snd=Helthpu1.wav                 local

message     startup
message     pulse

end            

# ========================================================================================

code

startup:
   SetPulse(1.0);

   Return;

# ........................................................................................

pulse:
   player = FirstThingInSector(healingsc);
   while(player != -1)
   {
      // If we have a player (10)
      if(GetThingType(player)==10)
      {
         if((GetThingHealth(player) > 0) && (GetThingHealth(player) < 100))
         {
            HealThing(player, healspeed);
            dummy = PlaySoundThing(snd, player, 1.0, -1, -1, 0);
         }
      }
      player = NextThingInSector(player);
   }

   Return;

end


????
if it helps the sector that the cog is suposed to work in is sector 19...
The Gas Station
2001-07-07, 4:09 PM #12
If you want to talk cog code you need to post in the cog forum.

You will need to use an entered message instead of the pulse and startup stuff.

Why are you bothering with that. Just use the cog I told you to.

------------------
"Sometimes nothing can be a real cool hand."
Have Lightsaber Will Travel

[This message has been edited by MikeC (edited July 07, 2001).]
Have Lightsaber Will Travel JK Editing tips, troubleshooting information, resources and more.
www.swgalaxies.net For all your Star Wars Galaxies needs
The Massassi A SW Galaxies Player Association
2001-07-08, 3:33 AM #13
i donno how it all works and such... how do you modyfiy em?

------------------
If You Can't Beat It, Cheat It!
The Gas Station
2001-07-08, 5:47 AM #14
A cog is really just a text file. You can open/edit/create them in any text editor like notepad or wordpad.

------------------
"Sometimes nothing can be a real cool hand."
Have Lightsaber Will Travel
Have Lightsaber Will Travel JK Editing tips, troubleshooting information, resources and more.
www.swgalaxies.net For all your Star Wars Galaxies needs
The Massassi A SW Galaxies Player Association
2001-07-08, 7:31 AM #15
NM, mikeC, i got it to work, thanx for your help in that cod mike and thank you all for helping me.

all i did was press F7 and choose the cog you suggested mikeC and and typed in the sector and the dmage interval and a (-) number to add health to the player when he enters the sector.
The Gas Station

↑ Up to the top!