Graal Forums  

Go Back   Graal Forums > Development Forums > Future Improvements
FAQ Members List Calendar Search Today's Posts Mark Forums Read

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 05-21-2010, 01:39 AM
DustyPorViva DustyPorViva is offline
Will work for food. Maybe
DustyPorViva's Avatar
Join Date: Sep 2003
Location: Maryland, USA
Posts: 9,589
DustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond repute
Send a message via AIM to DustyPorViva Send a message via MSN to DustyPorViva
onTileType(type,x,y,width,height)

onTileType(type,x,y,width,height)

Similar to onwall2 and onwater2, it would return true if the specified tiletype is found in the defined area. This would be useful for checking for things like chairs when replicating horse movement without having to do it the old fashioned way.


Also, if it can be done...

onTiles({array},x,y,width,height)

would return true if the tiles found in the specified area are found in the array. Would relieve a lot of looping that has to be done with special tile checks.
Reply With Quote
  #2  
Old 05-21-2010, 01:51 AM
Cubical Cubical is offline
Banned
Join Date: Feb 2007
Posts: 1,348
Cubical has a brilliant futureCubical has a brilliant futureCubical has a brilliant futureCubical has a brilliant futureCubical has a brilliant futureCubical has a brilliant futureCubical has a brilliant future
Wouldn't this work?
NPC Code:

temp.tilearray = findAreaTiles();
if (temp.tile in temp.tilearray){
//dostuff
}


http://forums.graalonline.com/forums...hp?t=134258357

edit: I didn't see you said without doing it the old fashioned way.
Reply With Quote
  #3  
Old 05-21-2010, 01:54 AM
DustyPorViva DustyPorViva is offline
Will work for food. Maybe
DustyPorViva's Avatar
Join Date: Sep 2003
Location: Maryland, USA
Posts: 9,589
DustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond repute
Send a message via AIM to DustyPorViva Send a message via MSN to DustyPorViva
Quote:
Originally Posted by Cubical View Post
Wouldn't this work?
NPC Code:

temp.tilearray = findAreaTiles;
if (temp.tile in temp.tilearray){
//dostuff
}


http://forums.graalonline.com/forums...hp?t=134258357
With movement being built around onwall2(like most on mines) it becomes increasingly difficult to work with more specific tile checks(exceptions, or like I said, chair checks for horses) when there aren't equivalent checks for tiles.
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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 07:06 PM.


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