Teleports help!

Discussion for map development.

Teleports help!

Postby JumpMe » Wed Dec 07, 2011 1:38 pm

If i edited a tyt map or something and completly moved the town to say the top left corner ( for example)
How would i go about editing teleports so they actually bring you back to town and not where the old tyt use to be?!
JumpMe
SD One Star
SD One Star
 
Posts: 28
Joined: Sat Oct 08, 2011 5:29 pm

Re: Teleports help!

Postby savate » Wed Dec 07, 2011 2:59 pm

JumpMe wrote:If i edited a tyt map or something and completly moved the town to say the top left corner ( for example)
How would i go about editing teleports so they actually bring you back to town and not where the old tyt use to be?!


Are you talking about the Warp lady or Scrolls?

If both,

You can use the find and replace function in in notepad for EVT's to replace the search for something like E LINK and replace with E LINK XXX YYY Z, please be aware that not all E LINKS will link to TYT and you will need to change E WARP_GATE too, if you wanted to make things easier to make the Warp lady sell them a specific town portal scroll then they can use that to warp since it would be too annoying searching through all the EVT's just to change that value.

If you want to change the Scrolls

If I remember correctly, normal town portal scrolls use tb_townportal_fixed table and Specific portal scrolls like guild village or mercenary town portal scrolls use tb_townportal where basicitem is the reference to which town it is used for for example 422 is the TYT town portal scroll so you would change the row for itemnum 422 in tb_townportal table for the TYT town portal scroll, for the normal portal scrolls you will change tb_townportal_fixed, since TYT has a lot of entries you will have to change the value for each row containing smovezone = 1

Sorry if it looks abit messy lol but i hope it helps.

Savate
savate
SD Four Star
SD Four Star
 
Posts: 208
Joined: Fri Sep 12, 2008 9:54 am

Re: Teleports help!

Postby JumpMe » Wed Dec 07, 2011 3:09 pm

cheers mate will help alot :)
JumpMe
SD One Star
SD One Star
 
Posts: 28
Joined: Sat Oct 08, 2011 5:29 pm

Re: Teleports help!

Postby POW » Thu Dec 08, 2011 7:56 am

u also need to hex 1p1 if u wish to edit the login random co'ords
User avatar
POW
SD Pro 1 Star
SD Pro 1 Star
 
Posts: 393
Joined: Thu Jul 22, 2010 8:19 pm

Re: Teleports help!

Postby JumpMe » Thu Dec 08, 2011 5:16 pm

POW wrote:u also need to hex 1p1 if u wish to edit the login random co'ords



ah yer sh!t completely forgot about that -_- do you know the 1p1 code i have to edit?
JumpMe
SD One Star
SD One Star
 
Posts: 28
Joined: Sat Oct 08, 2011 5:29 pm

Re: Teleports help!

Postby savate » Thu Dec 08, 2011 5:48 pm

Shouldn't need to hex edit the 1p1 for this, change the new_user procedure

Add this to the bottom of the DECLARES
Code: Select all
DECLARE @Randomx INT
DECLARE @Upperx INT
DECLARE @Lowerx INT
DECLARE @Randomy INT
DECLARE @Uppery INT
DECLARE @Lowery INT

---- This will create a random number between 1 and 999
SET @Lowerx = 1 ---- The lowest x coord number
SET @Upperx = 999 ---- The highest x coord number
SET @Randomx = ROUND(((@Upperx - @Lowerx -1) * RAND() + @Lowerx), 0)

---- This will create a random number between 1 and 999
SET @Lowery = 1 ---- The lowest y coord number
SET @Uppery = 999 ---- The highest y coord number
SET @Randomy = ROUND(((@Uppery - @Lowery -1) * RAND() + @Lowery), 0)



I no its just a workaround I don't no the 1p1 address for the rand function

then you just need to change

@lz = @first_z,
@lx = @Rand_x,
@ly = @Rand_y,

to

@lz = @first_z,
@lx = @Randomx,
@ly = @Randomy,

Dont forget to edit the upper and lower limits of X and Y, otherwise new chars could spawn anywhere on the map since they are set to 1 and 999 in this example lol

Of course you can just set these values to static values instead, if you don't want random new char spawns, but if two people create characters at the same time they might get stuck inside each other.

Savate
savate
SD Four Star
SD Four Star
 
Posts: 208
Joined: Fri Sep 12, 2008 9:54 am

Re: Teleports help!

Postby POW » Thu Dec 08, 2011 8:23 pm

also need to edit the rand warp values for gvw warp wen it ends or u die and hit warp insted of revive
User avatar
POW
SD Pro 1 Star
SD Pro 1 Star
 
Posts: 393
Joined: Thu Jul 22, 2010 8:19 pm

Re: Teleports help!

Postby w1ls0n » Thu May 10, 2012 7:40 pm

would this be the same for dsoma?
Image
User avatar
w1ls0n
SD Pro 2 Star
SD Pro 2 Star
 
Posts: 459
Joined: Thu Mar 01, 2012 5:07 am

Re: Teleports help!

Postby ghostlord » Fri May 11, 2012 1:18 pm

I'd guess.
Leader of The_Empire
@Ghostlord - Test server Pos King
@Phawaka - Retired human

Proud board member and mod of Somadev. Play fair, be nice!
Show your love for Soma, tell your friends about it!

Somadev - Blade of Heaven - 31st of August
ghostlord
SD Pro 5 Star
SD Pro 5 Star
 
Posts: 1619
Joined: Thu Aug 07, 2008 3:17 pm
Location: Netherlands


Return to Map Development

Who is online

Users browsing this forum: No registered users and 2 guests