Thread: [Devo]Al-Kharid gate

Results 1 to 3 of 3
  1. #1 [Devo]Al-Kharid gate 
    Registered Member
    Darna's Avatar
    Join Date
    Jan 2008
    Age
    31
    Posts
    488
    Thanks given
    11
    Thanks received
    4
    Rep Power
    163
    Code:
    	case 2882:
    					if(c.playerHasItem(995, 10)) {
    						if (c.absX == 3267 && c.absY == 3227 || c.absX == 3267 && c.absY == 3228) {
    							c.deleteItem(995, 10);
    							c.fmwalkto(1, 0);
    						}
    						if (c.absX == 3268 && c.absY == 3227 || c.absX == 3268 && c.absY == 3228) {
    							c.deleteItem(995, 10);
    							c.fmwalkto(-1, 0);
    						}
    					} else {
    						c.DA().npctalking(c, 925, "", "NIE MA PRZEJSCIA ZA DARMO", "10 gp jak dla ciebie.", "");
    					}
    				break;
    Here is the code for Al-Kharid Gate. It works perfectly but char walks trough the closed gate... is there any way to autmatticly close and open??

    Reply With Quote  
     

  2. #2  
    Want a b00b job? PM me.
    Unity's Avatar
    Join Date
    Jun 2008
    Age
    30
    Posts
    711
    Thanks given
    7
    Thanks received
    11
    Rep Power
    298
    I'm just shooting the breeze here but have you tried using the variation of doors.cfg (old way of opening door) that is made on the server and have it open then close? Just an idea - no idea how to implement it...
    Reply With Quote  
     

  3. #3  
    Registered Member
    Darna's Avatar
    Join Date
    Jan 2008
    Age
    31
    Posts
    488
    Thanks given
    11
    Thanks received
    4
    Rep Power
    163
    I think about it ... it can be done by something like gatestate
    Code:
    if (dh.gatestate[d] == 0) {
    						// closed
    						newFace = dh.doorFaceOpen[d];
    						dh.gatestate[d] = 1;
    						dh.doorFace[d] = newFace;
    					} else {
    						newFace = dh.doorFaceClosed[d];
    						dh.gatestate[d] = 0;
    						dh.doorFace[d] = newFace;
    					}
    But how to make when he reach the point X the Gatestate change to 1

    Reply With Quote  
     


Thread Information
Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)


User Tag List

Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •