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.

ForumsCog Forum → Need a cog
Need a cog
2003-03-24, 9:37 AM #1
I need 2 cogs each is very important.

1. I need a cog that has two switches. When either is activated it will push a selected object on a vector. i want to be able to control how long the thrust is active and the speed if possible. then it will sleep for x amount of time and it will go back on another vector for the same time. the idea is to create a SHUTTLE craft that can carry people from point A to point B and back again if necessary without the use of KEYS .

2. i need a cog for sector damage. You can specify up to 5 sectors and it will damage you slowly BUT if you are touching a specific object you will not recieve damage. this way if your in the shuttle you can breath but if you leave the shuttle while in space you will slowly suffocate. these are both 2 very importan things and ifanyone can find something simlar or make them id be greatly appreciative

------------------
2003-03-24, 10:06 AM #2
You could use frames for the transport and use a generic elevator cog to move it.

------------------
"Häb Pfrässe, süsch chlepfts!" - The coolest language in the world (besides Cherokee)
"Häb Pfrässe, süsch chlepfts!" - The coolest language in the world (besides Cherokee)
2003-03-24, 10:41 AM #3
frames???

------------------
2003-03-24, 11:03 AM #4
Here is a cog you could use for the sector damage.
Code:
#Written By DSLS_DeathSythe
flags=0x240
symbols
#-----
message     startup
message     pulse
#-----
sector      dmg_sec1
sector      dmg_sec2
sector      dmg_sec3
sector      dmg_sec4
sector      dmg_sec5
#-----
thing       shuttle=-1
flex        dmg_spd=1.0
flex        dmg_amount=10.0
flex        nodmg_range=0.5
#-----
thing       player=-1     local
sector      plyr_sec      local
#-----
end
#-----
code
#-----
startup:

  player = GetLocalPlayerThing();
  SetPulse(dmg_spd);

return;
#-----
pulse:

  plyr_sec = GetThingSector(player);
  if((plyr_sec == dmg_sec1) ||
     (plyr_sec == dmg_sec2) ||
     (plyr_sec == dmg_sec3) ||
     (plyr_sec == dmg_sec4) ||
     (plyr_sec == dmg_sec5))
       {
       if(VectorDist(GetThingPos(player), GetThingPos(shuttle)) > nodmg_range)
         {
         DamageThing(player, dmg_amount, 0x1, player);
         return;
         }
       return;
       }
return;
#-----
end

Instead of the player having to be touching an object, he has to be close enough to the
shuttle wich should work almost the same.
Just adjust the nodmg_range to where you need it. If the player is within that range he shouldnt get hurt.
I havent tested it but it should work. Hope it is something you can use.

As for the other cog, it would be easier if you used frames like zagibu said.
Check the tutorials to see what they are.

------------------


[This message has been edited by DSLS_DeathSythe (edited March 24, 2003).]
Famous last words - "It seemed like a good idea at the time."
2003-03-24, 12:00 PM #5
Well, ever heard of doors or elevators? Do you know how they work? If so, add frames to your shuttle and move it using a (modified, if necessary) elevator cog.

------------------
"Häb Pfrässe, süsch chlepfts!" - The coolest language in the world (besides Cherokee)
"Häb Pfrässe, süsch chlepfts!" - The coolest language in the world (besides Cherokee)

↑ Up to the top!