View Full Version : Drawbridge Cog Request
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
DogSRoOL
03-29-2003, 12:24 AM
# 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).]
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
DogSRoOL
03-29-2003, 10:11 PM
If only I knew about the "SendTrigger" command... http://forums.massassi.net/html/confused.gif
------------------
May the forks be with you.
Powered by vBulletin® Version 4.1.5 Copyright © 2012 vBulletin Solutions, Inc. All rights reserved.