![]() |
New things for scriptors
I think that stefan should put in a script command called
"move to" then you should put in the x,y coordinates to start at then the ones to finish at then the speed and then the options. Also anyone know how I would script a spar arena to get a script to 32,32,spar.nw if you say warp (the players accountname here) to spar ring. |
yes but this should be in scripting forum
|
if (playerchats) {
tokenize #c; if (strequals(#c,warpplayer)) { with (getplayer(#t(1)) { setlevel2 event.jr,x,y; } } } |
Weird Man has it wrong.
if(playerchats){ if(startswith(summon,#c)){ tokenize #c; with(getplayer(#t(2))){ setlevel2 level.graal,30,30; } } } |
Durr...you all have it wrong
}if playereastcowsayboo{ |
Quote:
|
There is the 'move' command or do you mean
moving the player? |
Quote:
|
you could just have a npc that moves and sets the player x to itself.
but then it wont do direction as well. so it would be easier for a new command, but untill then jus use an npc that you can do callnpc or triggeraction with to move. |
How about some things to simplify path finding?
|
im sure you have an onwall script somewhere right?
well if (x!=this.targetx&&y!=this.targety){ onwallmovement(); } then tweak the onwall so it will instead of keep obj or player still, it will move it up or down (depending on where a wall is located) if you cant script the rest from this, you shouldnt worry about path finding anyways |
Quote:
Say I want to move a NPC OR player to 32,46. All I would have to do is use a command called movenpc, or moveplayer. NPC Code: and then the NPC would go straight to 32,46, through any NPCs or blocking tiles in the way. Of course, you could use a command kind of like the options thing in move. Like, you could do blockcheck and stuff like that. NPC Code: |
... boo!
pathfinding is awesome. |
yah, a player version of move would be nice.
|
What I meant was if you have something running on random loops you could put a timeout=10; at the end of the random then put something like
moveto x,y,time,options;} and have it move you there from wherever your npc might happen to be at the moment.;) |
| All times are GMT +2. The time now is 08:31 AM. |
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.