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 → Drawbridge Cog Request
Drawbridge Cog Request
2003-03-28, 11:17 AM #1
Hello, i am making a sort of Midevil Level, and i need a Cog that will make a Giant door (if i can get someone to make it, or i myself make it) to go down slowly for about 1 minute or so, then go back up, (switch of course to lower it)

Thanx

------------------
Dark-Vane
There's only one thing that im scared of, and it's Pixels... THERE EVERYWHERE!!!! AHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHH! *runs through a wall*
2003-03-28, 9:24 PM #2
# Drawbridge.COG
# by DogSRoOL
#
# spuds_61520@yahoo.com
# strings_of_gold@hotmail.com

symbols
Message Activated
Message Timer

Thing Drawbridge

Surface Switch0
Surface Switch1

flex MoveTime
flex WaitTime

int Active=0
end

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

code
Activated:
if(Active) return;
RotatePivot(Drawbridge, 1, MoveTime);
SetWallCel(Switch0, 1);
SetWallCel(Switch1, 1);
Active=1;
Return;

Arrived:
if(Active) SetTimer(WaitTime);
else
{
SetWallCel(Switch0, 0);
SetWallCel(Switch1, 0);
Active=0;
}
Return;

Timer:
RotatePivot(Drawbridge, 0, MoveTime);
Return;
# ........................................................................................

end


Since I had to use rotatepivot, you're frame setup will be much different. Use a ghost object to isolate the point you want the drawbridge to pivot arount (near the bottom). The first frame (frame0) should dictate the direction to close (-90 degrees, probably) and the next frame should dictate the opening direction (+90 degrees). It's a little complicated to understand at first. When you're done, delete the ghost object. You don't actually need it. If you need an example, let me know.

BTW, I hope this was for a SP game, because I don't know much about MP cogging.
------------------
May the forks be with you.

[This message has been edited by DogSRoOL (edited March 29, 2003).]
Catloaf, meet mouseloaf.
My music
2003-03-29, 2:30 PM #3
Its for a MP level, i have a Castle made out, im gonna add a moat around the castle, and it would add some nice detail if i had a working Drawbridge...unfortnately, im Terrible with Understanding Cogs..... [http://forums.massassi.net/html/frown.gif]

------------------
Dark-Vane
There's only one thing that im scared of, and it's Pixels... THERE EVERYWHERE!!!! AHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHH! *runs through a wall*
2003-03-29, 7:11 PM #4
If only I knew about the "SendTrigger" command... [http://forums.massassi.net/html/confused.gif]

------------------
May the forks be with you.
Catloaf, meet mouseloaf.
My music

↑ Up to the top!