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 → Hmm, question
Hmm, question
2001-06-12, 8:14 AM #1
How to make it where you shoot somebody, you still get a point, but they don't die, they just can't shoot for five second

------------------
"Huh? What wookiee?"
2001-06-12, 8:23 AM #2
OK, sounds hard. Here are some ideas. Name the projectile, and program it so when the projectile is in the same location as the victim, it makes their weapon delay a long time. But, then comes another problem. You have to get their name in a string or somethign too. So, Just tell me what u think about those options. Hope a better editor can help too.
2001-06-12, 11:19 AM #3
Is this good???
Code:
#BlahBlahBlah, helped by scott_karana

symbols

thing player local
thing victim local
message damaged

end

#-----------------------------

code

damaged:
victim=GetSenderRef(); #I may have the source and sender reversed...
player=GetSourceRef();
SetThingFlags(victim,0x200000);
SetPlayerScore(player,GetPlayerScore(player)+1);
Sleep(5);
ClearThingFlags(victim,0x200000)

Return;

end


That oughta do it.
Hey, I'm here! But who cares?
2001-06-12, 11:20 AM #4
The problem w/ my cog is that the victim still gets damaged, maybe a Capture verb would work?
Hey, I'm here! But who cares?
2001-06-12, 11:27 AM #5
I don't think you should try and use sleep();
That often stops working after the cog is use several times. have it call it in a timer or a pulse.

Also, to not have the victim get damaged I think you'd put that in the touched message and have it check to make sure it was the correct thing touching the victim.
Gravity isn't MY fault--I voted for velcro.
2001-06-12, 11:41 AM #6
Bravo Guys, that was some pretty nice work Scott.
2001-06-12, 3:47 PM #7
Hehe, sorry for being new to cog, but how to implement this?

Oh, BTW, I think I can make the damage 0 by editing the weapon and/or projectile template(s)

------------------
"Huh? What wookiee?"
2001-06-12, 4:06 PM #8
Hehe, sorry for being new to cog, but how to implement this?

Oh, BTW, I think I can make the damage 0 by editing the weapon and/or projectile template(s)

------------------
"Huh? What wookiee?"
2001-06-12, 11:07 PM #9
Karanea that cog maybe all wrong , I don't have time to write it all out right now , but I will tommorow.
2001-06-13, 2:38 AM #10
Now what will this cog control, the weapon?

I think I could fix the damage problem in the weapon template by setting damage to zero.

------------------
"Huh? What wookiee?"

↑ Up to the top!