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 03-28-2004, 07:21 AM
Gman4pwnu Gman4pwnu is offline
Banned
Join Date: Jan 2004
Posts: 434
Gman4pwnu is on a distinguished road
Send a message via AIM to Gman4pwnu
Collision detection in a movement script.

Best way to handle it? I tried checking for onwall in a for loop, no good.
Reply With Quote
  #2  
Old 03-28-2004, 03:28 PM
osrs osrs is offline
Graalian since 1998
osrs's Avatar
Join Date: Mar 2002
Location: Brazil
Posts: 2,724
osrs is on a distinguished road
Send a message via ICQ to osrs Send a message via AIM to osrs Send a message via MSN to osrs Send a message via Yahoo to osrs
I think onwall(x,y) would be the best way, it did not work with you because you probably didn't apply it correctly.

Edit: Finally a proper thread name
__________________
"Ability is what you are capable of doing. Motivation determines what you do. Attitude determines how well you do it."
Facebook: facebook.com/raysilvadotnet /
Reply With Quote
  #3  
Old 03-28-2004, 03:30 PM
Loriel Loriel is offline
Somewhat rusty
Loriel's Avatar
Join Date: Mar 2001
Posts: 5,059
Loriel is a name known to allLoriel is a name known to allLoriel is a name known to allLoriel is a name known to all
You need to use a better for loop, and probably more.
Reply With Quote
  #4  
Old 03-28-2004, 03:55 PM
osrs osrs is offline
Graalian since 1998
osrs's Avatar
Join Date: Mar 2002
Location: Brazil
Posts: 2,724
osrs is on a distinguished road
Send a message via ICQ to osrs Send a message via AIM to osrs Send a message via MSN to osrs Send a message via Yahoo to osrs
By the way, wich kind of movement script are you working, move command or x/y settings?
__________________
"Ability is what you are capable of doing. Motivation determines what you do. Attitude determines how well you do it."
Facebook: facebook.com/raysilvadotnet /
Reply With Quote
  #5  
Old 03-28-2004, 07:00 PM
Gman4pwnu Gman4pwnu is offline
Banned
Join Date: Jan 2004
Posts: 434
Gman4pwnu is on a distinguished road
Send a message via AIM to Gman4pwnu
x,y.

I didn't know you could do it with move command.
Reply With Quote
  #6  
Old 03-28-2004, 07:08 PM
TB3 TB3 is offline
Registered User
TB3's Avatar
Join Date: May 2001
Location: US of A State of VA
Posts: 658
TB3 is on a distinguished road
Send a message via Yahoo to TB3
Is your movement script for the player or for an npc?

For player you would use arrays with points to check around the player with a nifty for loop and alot more its realy complicated. Falados(Falcor) made one of the best that I had seen in a while.

If your using it on a npc use move command, or just use a copy of one built for a player just make it more applicalbe for the npc in question.
???
__________________

To the sun of your age, I arise
Reply With Quote
  #7  
Old 03-28-2004, 07:11 PM
Gman4pwnu Gman4pwnu is offline
Banned
Join Date: Jan 2004
Posts: 434
Gman4pwnu is on a distinguished road
Send a message via AIM to Gman4pwnu
im doing it for a player o.o
Reply With Quote
  #8  
Old 03-28-2004, 07:22 PM
Python523 Python523 is offline
Banned
Join Date: Aug 2001
Location: Illinois
Posts: 3,498
Python523 is on a distinguished road
Quote:
Originally posted by osrs
Edit: Finally a proper thread name
Uh? His title is fine.
Reply With Quote
  #9  
Old 03-28-2004, 07:58 PM
osrs osrs is offline
Graalian since 1998
osrs's Avatar
Join Date: Mar 2002
Location: Brazil
Posts: 2,724
osrs is on a distinguished road
Send a message via ICQ to osrs Send a message via AIM to osrs Send a message via MSN to osrs Send a message via Yahoo to osrs
Quote:
Originally posted by Python523


Uh? His title is fine.
I know and that's what i mean.
__________________
"Ability is what you are capable of doing. Motivation determines what you do. Attitude determines how well you do it."
Facebook: facebook.com/raysilvadotnet /
Reply With Quote
  #10  
Old 03-28-2004, 08:50 PM
Python523 Python523 is offline
Banned
Join Date: Aug 2001
Location: Illinois
Posts: 3,498
Python523 is on a distinguished road
Quote:
Originally posted by osrs


I know and that's what i mean.
Misread it as 'find a proper' x_X sorry
Reply With Quote
  #11  
Old 03-28-2004, 10:27 PM
Dach Dach is offline
call me Chad, it's cooler
Dach's Avatar
Join Date: Aug 2002
Posts: 1,899
Dach is on a distinguished road
Quote:
Originally posted by TB3

For player you would use arrays with points to check around the player with a nifty for loop and alot more its realy complicated. Falados(Falcor) made one of the best that I had seen in a while.
arrays? don't know if that's really necessary, unless you're using something other than the normal vecx/vecy for directions...

I should probably write some tutorial for onwall detection, since i'm so fond of my little wall check algorithms
__________________
Scripting Documents:Old Script Documentation-Movement Tutorial
Reply With Quote
  #12  
Old 03-29-2004, 08:33 AM
TB3 TB3 is offline
Registered User
TB3's Avatar
Join Date: May 2001
Location: US of A State of VA
Posts: 658
TB3 is on a distinguished road
Send a message via Yahoo to TB3
Quote:
Originally posted by Dach

arrays? don't know if that's really necessary, unless you're using something other than the normal vecx/vecy for directions...

I should probably write some tutorial for onwall detection, since i'm so fond of my little wall check algorithms
Its more convienent if you have a realy advanced onwall. Just checking 4 points for the players direction isnt enough.
__________________

To the sun of your age, I arise
Reply With Quote
  #13  
Old 03-29-2004, 09:26 AM
Gman4pwnu Gman4pwnu is offline
Banned
Join Date: Jan 2004
Posts: 434
Gman4pwnu is on a distinguished road
Send a message via AIM to Gman4pwnu
what i do is i check every .1 coord for my script. Works nicely. Currently im dealing with the troubles of making character sit, sleep and swim. Along with push, (probably gonna use a for loop for that too )
Reply With Quote
  #14  
Old 03-29-2004, 09:45 AM
WanDaMan WanDaMan is offline
Master Tux
WanDaMan's Avatar
Join Date: Aug 2002
Location: England, United Kingdom
Posts: 5,571
WanDaMan is a jewel in the roughWanDaMan is a jewel in the rough
Send a message via MSN to WanDaMan
replaceani sit,newgani;
__________________
V$:CONFL16T
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 02:11 AM.


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