Graal Forums  

Go Back   Graal Forums > Development Forums > NPC Scripting
FAQ Members List Calendar Today's Posts

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 02-09-2002, 06:40 AM
Wes2000 Wes2000 is offline
Registered User
Join Date: Dec 2001
Posts: 57
Wes2000 is on a distinguished road
Send a message via AIM to Wes2000
Unhappy Please Help If You Can

Hey, im having some trouble with my hammer for mineing...

// NPC made by Wes2000
if (playerenters) {
tx={1,0,1,2};
ty={0,1.5,3,1.5};
tilex={9,10,6,6,7,8,11,11};
tiley={130,130,129,130,128,128,128,129};
setshape 1,32,32;
}
if (playertouchsme) {
toweapons Hammer;
}
if (weaponfired){
this.tx=playerx+tx;
this.ty=playery+ty;
TileCheck();
}

function TileCheck(){
putx=int(this.tx[playerdir]);
puty=int(this.ty[playerdir]);
b = board[putx+64*puty];
bx = b % 16;
by = int(b / 16);
//-----------------------------------GETS TO HERE---------
if (bx in tilex&&by in tiley){
disableweapons;
disabledefmovement;



the problem- It goes fine for up and left, but it wont work on the right and bottom walls

1- I know the tile set part is right because all the tiles work if i hit them facing left.

2- I think the problem is in the
tx={1,0,1,2};
ty={0,1.5,3,1.5};
but im not sure

3- for left and up it finishs the script (i didnt post it all just the buggy part) but for right and down it gets to the line i put in...

Please help me if you can
__________________
Reply With Quote
  #2  
Old 02-09-2002, 11:35 AM
Wes2000 Wes2000 is offline
Registered User
Join Date: Dec 2001
Posts: 57
Wes2000 is on a distinguished road
Send a message via AIM to Wes2000
please anyone
__________________
Reply With Quote
  #3  
Old 02-09-2002, 10:25 PM
Poogle Poogle is offline
Registered User
Poogle's Avatar
Join Date: Jun 2001
Posts: 2,471
Poogle is on a distinguished road
Quote:
Originally posted by Wes2000
please anyone
Theres 1 in the Weapons folder uynder hammer.txt and check newfeatures2001.txt its in there around 1,?? and 2.?? I think its in 2.03 Check it even gives you a meneral script
Reply With Quote
  #4  
Old 02-09-2002, 11:42 PM
Wes2000 Wes2000 is offline
Registered User
Join Date: Dec 2001
Posts: 57
Wes2000 is on a distinguished road
Send a message via AIM to Wes2000
I dont want to take that one =/

Kai can you help me?
__________________
Reply With Quote
  #5  
Old 02-09-2002, 11:45 PM
joseyisleet joseyisleet is offline
Registered User
Join Date: Aug 2001
Posts: 378
joseyisleet is on a distinguished road
-=Josey=-
Even a dog who isn't happy can be handed a bone and still be unhappy. Sheesh, he just told you what to look at. If you think you know where the problem is (which you said you did), work on it. Don't just randomly ask for help from one person when your script doesn't work like it's supposed to. Myself, I'd just rewrite the whole thing and make sure it all works as I'm going along.
__________________
Account used by Josey and Howard.
Ali G: 'Is it cause i Black?'
Reply With Quote
  #6  
Old 02-09-2002, 11:48 PM
Wes2000 Wes2000 is offline
Registered User
Join Date: Dec 2001
Posts: 57
Wes2000 is on a distinguished road
Send a message via AIM to Wes2000
This is one of my first times posting a topic for help with a script =/ I have looked at it, messed with it, and changed it a lot but i still cant get it to work. Is it so wrong that I want my own script to work? I thought that this is what the board is for... its not like i havnt tried to fix it myself...
__________________
Reply With Quote
  #7  
Old 02-10-2002, 12:06 AM
Wes2000 Wes2000 is offline
Registered User
Join Date: Dec 2001
Posts: 57
Wes2000 is on a distinguished road
Send a message via AIM to Wes2000
Thanks Kaimetsu that helped me fix the problem =)
__________________
Reply With Quote
Reply


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

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 11:58 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.