The following warnings occurred:
Warning [2] Use of undefined constant SAPI_NAME - assumed 'SAPI_NAME' (this will throw an Error in a future version of PHP) - Line: 3388 - File: inc/functions.php PHP 7.4.33-nmm7 (Linux)
File Line Function
/inc/functions.php 3388 errorHandler->error
/showthread.php 116 build_archive_link
Warning [2] Use of undefined constant IN_ARCHIVE - assumed 'IN_ARCHIVE' (this will throw an Error in a future version of PHP) - Line: 3331 - File: inc/functions.php PHP 7.4.33-nmm7 (Linux)
File Line Function
/inc/functions.php 3331 errorHandler->error
/inc/functions.php 3324 build_forum_breadcrumb
/showthread.php 195 build_forum_breadcrumb
Warning [2] Use of undefined constant IN_ARCHIVE - assumed 'IN_ARCHIVE' (this will throw an Error in a future version of PHP) - Line: 3331 - File: inc/functions.php PHP 7.4.33-nmm7 (Linux)
File Line Function
/inc/functions.php 3331 errorHandler->error
/showthread.php 195 build_forum_breadcrumb






Post Reply 
 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
isneartype t_forest
Author Message
Gil Amarth
Journeyman
*

Posts: 189
Likes Given: 2
Likes Received: 1 in 1 posts
Joined: May 2012
Reputation: 0



Post: #1
isneartype t_forest
In my scripts works all isneartype anything except t_forest.

isneartype t_grass, isneartype t_snow, etc... works. But isneartype t_forest always returns me =0

Anyone have experienced this. At spheretables i have in t_forest:

[TYPEDEF t_forest]
TERRAIN = 0c4 0d7
TERRAIN = 0ed 0f3
TERRAIN = 0f8 0fb
TERRAIN = 015d 0168
TERRAIN = 0324 032a
TERRAIN = 054f 0552
TERRAIN = 05f1 05f4
TERRAIN = 05f9 0603
TERRAIN = 0611 0614
TERRAIN = 0653 0655
TERRAIN = 065b 0662
TERRAIN = 066b 066e
TERRAIN = 06af 06b4
TERRAIN = 06bb 06be
TERRAIN = 0709 070c
TERRAIN = 0715 071c

Why don´t work with t_forest?
(This post was last modified: 02-09-2014 03:52 AM by Gil Amarth.)
02-09-2014 03:51 AM
Find all posts by this user Like Post Quote this message in a reply
amonvangrell
Banned

Posts: 337
Likes Given: 17
Likes Received: 32 in 20 posts
Joined: Aug 2012

britannia shard

Post: #2
RE: isneartype t_forest
interesting thing... can u post the scp you use with the types?
thanks
02-09-2014 07:26 AM
Visit this user's website Find all posts by this user Like Post Quote this message in a reply
Gil Amarth
Journeyman
*

Posts: 189
Likes Given: 2
Likes Received: 1 in 1 posts
Joined: May 2012
Reputation: 0



Post: #3
RE: isneartype t_forest
Code:
//****************************************************************************
//SPHERE by : Menasoft ©1997-2007
//www.sphereserver.net
// All SPHERE script files and formats are copyright Menasoft & Partners.
// This file may be freely edited for personal use, but may not be distributed
// in whole or in part, in any format without express written permission from
// Menasoft & Partners.  All donations and contributions
// become the property of Menasoft & Partners.
//****************************************************************************
// FILE LAST UPDATED: 27-Jul-2006
//****************************************************************************
// This script associates terrain tiles with item types. You MUST have a script
// like this in your server as of SphereServer 55R3rc2. Failure to do so will
// result in, for instance, not being able to mine.
// Be warned that if you redefine one of the TYPEDEFs placed here, you will
// clear all TERRAINs associated with it. This was done specifically to make
// sure TYPEDEFs don't remain associated with TERRAIN ids after you remove them
// from a script in a resync.
//****************************************************************************
// t_jungle & t_forest added by Mordaunt 11/3/12

VERSION=0.56b

[TYPEDEF t_water]
TERRAIN = 0a8    0ab
TERRAIN = 0136    0137
TERRAIN = 064
TERRAIN = 03ff0 03ff3

[TYPEDEF t_rock]
TERRAIN = 0e1
TERRAIN = 00dc    00e7
TERRAIN = 00ec    00f7
TERRAIN = 00fc    0107
TERRAIN = 010c    0117
TERRAIN = 011e    0129
TERRAIN = 0141    0144
TERRAIN = 021f    0243
TERRAIN = 024a    0257
TERRAIN = 0259    026d
TERRAIN = 022e
TERRAIN = 0236
TERRAIN = 0234
TERRAIN = 023b
TERRAIN = 0245    0249

[TYPEDEF t_dirt]
TERRAIN    = 09        015        
TERRAIN    = 0150    015c

[TYPEDEF t_grass]
TERRAIN = 0003    0006
TERRAIN = 007d    008c
TERRAIN = 00c0    00db
TERRAIN = 00f8    00fb
TERRAIN = 015d    0164
TERRAIN = 01a4    01a7
TERRAIN = 0231    0234
TERRAIN = 0239    0243
TERRAIN = 0324    032b
TERRAIN = 036f    0376
TERRAIN = 037b    037e
TERRAIN = 03bf    03c6
TERRAIN = 03cb    03ce
TERRAIN = 0579    0580
TERRAIN = 058b    058c
TERRAIN = 05e3    0604
TERRAIN = 066b    066e
TERRAIN = 067d    0684
TERRAIN = 0695    069c
TERRAIN = 06a1    06c2
TERRAIN = 06d2    06d9
TERRAIN = 06de    06e1

[TYPEDEF t_lava]
TERRAIN = 01f4    01f7

[TYPEDEF t_snow]
TERRAIN = 010c    011d
TERRAIN = 0385    03ac
TERRAIN = 0745    0773

[TYPEDEF t_swamp]
TERRAIN = 07dc 0808
TERRAIN = 083b 0867
TERRAIN = 03d65
TERRAIN = 03dc0 03df1
TERRAIN = 03ef0

[TYPEDEF t_sand]
TERRAIN = 016 03e
TERRAIN = 044 04b

[TYPEDEF t_jungle]
TERRAIN = 0ac 0bf
TERRAIN = 0ec
TERRAIN = 0fc 0103
TERRAIN = 0108 010b
TERRAIN = 01f1 01f3
TERRAIN = 026e 0271
TERRAIN = 0276 027d
TERRAIN = 0286 0289
TERRAIN = 0292 0295
TERRAIN = 0581 058a
TERRAIN = 058d 0590
TERRAIN = 059f 05a5
TERRAIN = 05b3 05b9
TERRAIN = 05f5 05f8
TERRAIN = 0605 0610
TERRAIN = 0615 0617
TERRAIN = 0727 072a
TERRAIN = 0733 073a

[TYPEDEF t_forest]
TERRAIN = 0c4 0d7
TERRAIN = 0ed 0f3
TERRAIN = 0f8 0fb
TERRAIN = 015d 0168
TERRAIN = 0324 032a
TERRAIN = 054f 0552
TERRAIN = 05f1 05f4
TERRAIN = 05f9 0603
TERRAIN = 0611 0614
TERRAIN = 0653 0655
TERRAIN = 065b 0662
TERRAIN = 066b 066e
TERRAIN = 06af 06b4
TERRAIN = 06bb 06be
TERRAIN = 0709 070c
TERRAIN = 0715 071c

[TYPEDEF 2010]

[TYPEDEF 2011]

The .scp says Mordaunt added t_jungle and t_forest, but if you use:

.show isneartype t_grass

Over a grass tile, it returns 1, and 0 if not.

But .show isneartype t_jungle or .show isneartype t_forest, always returns me 0, in forest, jungle or anywhere else.

Maybe a hardcoded bug? Do you experience the same in your servers?
02-09-2014 11:48 PM
Find all posts by this user Like Post Quote this message in a reply
Mordaunt
Super Moderator
****

Posts: 1,237
Likes Given: 26
Likes Received: 55 in 43 posts
Joined: Mar 2012
Reputation: 35



Post: #4
RE: isneartype t_forest
forest tiles are not grass... they look more like moss. make sure you are looking in the right place, the tile types are correct.

e.g. go to 1276,2000 and do .info on the ground tiles there, they will come up as t_forest

[Image: 2nis46r.jpg]
(This post was last modified: 02-10-2014 12:17 AM by Mordaunt.)
02-10-2014 12:15 AM
Visit this user's website Find all posts by this user Like Post Quote this message in a reply
Gil Amarth
Journeyman
*

Posts: 189
Likes Given: 2
Likes Received: 1 in 1 posts
Joined: May 2012
Reputation: 0



Post: #5
RE: isneartype t_forest
Yes, I know what are the forest tiles, if you write .info, you take type t_forest.

My question is about isneartype t_forest or isneartype t_jungle working correctly.
02-10-2014 12:25 AM
Find all posts by this user Like Post Quote this message in a reply
Mordaunt
Super Moderator
****

Posts: 1,237
Likes Given: 26
Likes Received: 55 in 43 posts
Joined: Mar 2012
Reputation: 35



Post: #6
RE: isneartype t_forest
Oh sorry.

Interestingly, I am getting the same result. I will poke around

[Image: 2nis46r.jpg]
02-10-2014 12:33 AM
Visit this user's website Find all posts by this user Like Post Quote this message in a reply
Ben
Sphere Developer
*****

Posts: 612
Likes Given: 2
Likes Received: 123 in 70 posts
Joined: Mar 2010
Reputation: 18

SphereCommunity

Post: #7
RE: isneartype t_forest
just add:
t_forest 500 // Forest Tiles
t_jungle 501 // Jungle Tiles
to sphere_defs.scp under [TYPEDEFS] section...
This will be added in the script pack.

AxisII's current version: 2.0.4j
AxisII SourceCode on Github
AxisII up to date changelog
02-10-2014 05:53 AM
Visit this user's website Find all posts by this user Like Post Quote this message in a reply
[+] 1 user Likes Ben's post
Gil Amarth
Journeyman
*

Posts: 189
Likes Given: 2
Likes Received: 1 in 1 posts
Joined: May 2012
Reputation: 0



Post: #8
RE: isneartype t_forest
It works now.

Thanks! Smile
02-10-2014 06:36 AM
Find all posts by this user Like Post Quote this message in a reply
Post Reply 


Forum Jump:


User(s) browsing this thread: 3 Guest(s)