[wpdev-commits] xmlscripts/scripts door.py,1.9,1.10 wall_clock.py,1.4,1.5
Brought to you by:
rip,
thiagocorrea
From: Richard M. <dr...@us...> - 2004-07-01 21:43:38
|
Update of /cvsroot/wpdev/xmlscripts/scripts In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv26504 Modified Files: door.py wall_clock.py Log Message: Updates, doors should not close on people now! Index: door.py =================================================================== RCS file: /cvsroot/wpdev/xmlscripts/scripts/door.py,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** door.py 26 May 2004 13:07:19 -0000 1.9 --- door.py 1 Jul 2004 21:43:28 -0000 1.10 *************** *** 225,229 **** # Change the Door id and resend item.id = door[1] ! item.moveto( pos.x + door[2], pos.y + door[3] ) item.update() --- 225,229 ---- # Change the Door id and resend item.id = door[1] ! item.moveto( pos.x + door[2], pos.y + door[3], pos.z ) item.update() *************** *** 262,266 **** # Change the door id and update the clients around it item.id = door[0] ! item.moveto( pos.x - door[2], pos.y - door[3] ) if item.hastag('opened'): item.deltag( 'opened' ) --- 262,266 ---- # Change the door id and update the clients around it item.id = door[0] ! item.moveto( pos.x - door[2], pos.y - door[3], pos.z ) if item.hastag('opened'): item.deltag( 'opened' ) *************** *** 284,301 **** return ! # Find the door definition for this item for door in doors: if door[1] == item.id: ! pos = item.pos ! # Change the door id and update the clients around it ! item.id = door[0] ! item.moveto( pos.x - door[2], pos.y - door[3] ) ! if item.hastag( 'opened' ): ! item.deltag( 'opened' ) ! item.update() ! # Soundeffect (close) ! item.soundeffect( door[5] ) --- 284,321 ---- return ! """ ! # NOTE! ! # We need to put in a form of character checking for the location ! # where the door closes, this way the door doesn't close ON people. ! """ ! blocked = 0 for door in doors: if door[1] == item.id: ! chars = wolfpack.chars( item.pos.x - door[2], item.pos.y - door[3], item.pos.map, 0 ) ! for char in chars: ! if char.pos.z == item.pos.z: ! blocked = 1 ! elif char.pos.z < item.pos.z and char.pos.z >= ( item.pos.z - 5): ! blocked = 1 ! elif char.pos.z > item.pos.z and char.pos.z <= ( item.pos.z + 5): ! blocked = 1 ! if blocked == 1: ! item.addtimer(CLOSEDOOR_DELAY, "door.autoclose", [ int(item.gettag('opencount')) ], 1) ! else: ! # Find the door definition for this item ! for door in doors: ! if door[1] == item.id: ! pos = item.pos ! # Change the door id and update the clients around it ! item.id = door[0] ! item.moveto( pos.x - door[2], pos.y - door[3], pos.z ) ! if item.hastag( 'opened' ): ! item.deltag( 'opened' ) ! item.update() ! ! # Soundeffect (close) ! item.soundeffect( door[5] ) *************** *** 319,321 **** def onTelekinesis(char, item): return onUse(char, item, 1) - --- 339,340 ---- Index: wall_clock.py =================================================================== RCS file: /cvsroot/wpdev/xmlscripts/scripts/wall_clock.py,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** wall_clock.py 26 May 2004 13:07:20 -0000 1.4 --- wall_clock.py 1 Jul 2004 21:43:28 -0000 1.5 *************** *** 56,58 **** char.message( time ) ! return 1 \ No newline at end of file --- 56,58 ---- char.message( time ) ! return 1 |