Lazarus
Master
Posts: 352
Likes Given: 11
Likes Received: 7 in 6 posts
Joined: Jun 2012
Reputation: 1
Hybris Ultima Online
|
RE: targon_ground - need help ^_^
(08-07-2012 02:32 PM)Shaklaban Wrote: well you can add: (<SERV.MAP(<argv[0]>,<argv[1]>,<argv[3]>).STATICS>) then they are not able to teleport a tile which contains statics. if you want to disable just some types of statics you can loop through statics: http://wiki.sphere.torfo.org/index.php/Map_Points you can control their properties with <serv.itemdef.x.can> thing. if you want to disable teleport on blocking ingame items you can use foritems 0 and control the can flag of items in for loop "if (<can>&can_i_block)".
I can do something like:
if ((<SERV.MAP(<argv[0]>,<argv[1]>,<argv[3]>).ISNEARTYPE t_grass>) || t_normal || t _rock
return 1
else
return 0
?
just to know, this will simply all the function and works only in grass, normal terrain or rock.
Thanks for the .statics , I'll try it.
WITH STATICS works fine but the houses... I can still get in the player's houses...
(This post was last modified: 08-07-2012 02:46 PM by Lazarus.)
|
|
08-07-2012 02:41 PM |
|
|
Mordaunt
Super Moderator
Posts: 1,237
Likes Given: 26
Likes Received: 55 in 43 posts
Joined: Mar 2012
Reputation: 35
|
RE: targon_ground - need help ^_^
Code:
if (<SERV.MAP(<argv[0]>,<argv[1]>,<argv[3]>).TYPE==t_multi)
src.sysmessage you cannot teleport into a house
return 1
endif
that would fix the house issue...
As for the items and such, it would be a shorter script to say what you CAN tele onto than what you can't....
Code:
[function summon_ground_avaible]
if (<SERV.MAP(<argv[0]>,<argv[1]>,<argv[3]>).TYPE==t_normal) || (<SERV.MAP(<argv[0]>,<argv[1]>,<argv[3]>).TYPE==t_grass) || (<SERV.MAP(<argv[0]>,<argv[1]>,<argv[3]>).TYPE==t_sand) || (<SERV.MAP(<argv[0]>,<argv[1]>,<argv[3]>).TYPE==t_swamp) || (<SERV.MAP(<argv[0]>,<argv[1]>,<argv[3]>).TYPE==t_snow) || (<SERV.MAP(<argv[0]>,<argv[1]>,<argv[3]>).TYPE==t_jungle) || (<SERV.MAP(<argv[0]>,<argv[1]>,<argv[3]>).TYPE==t_forest)
return 0
else
src.sysmessage cannot teleport there
return 1
endif
Now if they target anything that is NOT ground they will not be allowed to teleport, couple this with the check for a multi, distance and los and it should prevent any nonsense
|
|
08-08-2012 06:57 AM |
|
|
Lazarus
Master
Posts: 352
Likes Given: 11
Likes Received: 7 in 6 posts
Joined: Jun 2012
Reputation: 1
Hybris Ultima Online
|
RE: targon_ground - need help ^_^
(08-08-2012 06:57 AM)Mordaunt Wrote:
Code:
if (<SERV.MAP(<argv[0]>,<argv[1]>,<argv[3]>).TYPE==t_multi)
src.sysmessage you cannot teleport into a house
return 1
endif
that would fix the house issue...
As for the items and such, it would be a shorter script to say what you CAN tele onto than what you can't....
Code:
[function summon_ground_avaible]
if (<SERV.MAP(<argv[0]>,<argv[1]>,<argv[3]>).TYPE==t_normal) || (<SERV.MAP(<argv[0]>,<argv[1]>,<argv[3]>).TYPE==t_grass) || (<SERV.MAP(<argv[0]>,<argv[1]>,<argv[3]>).TYPE==t_sand) || (<SERV.MAP(<argv[0]>,<argv[1]>,<argv[3]>).TYPE==t_swamp) || (<SERV.MAP(<argv[0]>,<argv[1]>,<argv[3]>).TYPE==t_snow) || (<SERV.MAP(<argv[0]>,<argv[1]>,<argv[3]>).TYPE==t_jungle) || (<SERV.MAP(<argv[0]>,<argv[1]>,<argv[3]>).TYPE==t_forest)
return 0
else
src.sysmessage cannot teleport there
return 1
endif
Now if they target anything that is NOT ground they will not be allowed to teleport, couple this with the check for a multi, distance and los and it should prevent any nonsense
That of t_multi doesn't works... I can tp in the houses can you try in your own server please :'(?
but I'll try the other set of scripts, and will edit this.
I need go to dinner now.
Thanks, rly ^_^
|
|
08-08-2012 10:51 AM |
|
|