nunesb Posted December 26, 2012 Group: Members Topic Count: 7 Topics Per Day: 0.00 Content Count: 17 Reputation: 0 Joined: 11/30/12 Last Seen: December 9, 2019 Share Posted December 26, 2012 (edited) So, could someone help me with a scroll that when be used appear a bar and you can write one map coordinates and you will be teleported to this place, like @warp but as an item ? Edited December 26, 2012 by nunesb Quote Link to comment Share on other sites More sharing options...
Euphy Posted December 26, 2012 Group: Members Topic Count: 72 Topics Per Day: 0.02 Content Count: 2997 Reputation: 1132 Joined: 05/27/12 Last Seen: June 1, 2017 Share Posted December 26, 2012 message strcharinfo(0),"Teleport to..."; dispbottom "map,x,y"; input .@i$; explode(.@j$,.@i$,","); if (getmapusers(.@j$[0]) >= 0) { delitem your_item,1; // Type item ID here warp .@j$[0], atoi(.@j$[1]), atoi(.@j$[2]); } else message strcharinfo(0),"Invalid map."; end; Item type 11. 1 Quote Link to comment Share on other sites More sharing options...
nunesb Posted December 26, 2012 Group: Members Topic Count: 7 Topics Per Day: 0.00 Content Count: 17 Reputation: 0 Joined: 11/30/12 Last Seen: December 9, 2019 Author Share Posted December 26, 2012 what command I use to call this scrip, sc_start? Could you tell me how to do it? or a page that teaches, I not found.. Quote Link to comment Share on other sites More sharing options...
Euphy Posted December 26, 2012 Group: Members Topic Count: 72 Topics Per Day: 0.02 Content Count: 2997 Reputation: 1132 Joined: 05/27/12 Last Seen: June 1, 2017 Share Posted December 26, 2012 That's an item script. Either condense it into 1 line or make it a function. Custom_Items 1 Quote Link to comment Share on other sites More sharing options...
nunesb Posted December 26, 2012 Group: Members Topic Count: 7 Topics Per Day: 0.00 Content Count: 17 Reputation: 0 Joined: 11/30/12 Last Seen: December 9, 2019 Author Share Posted December 26, 2012 (edited) I did it function script scrollwarpzz { message strcharinfo(0),"Teleport to..."; dispbottom "map,x,y"; input .@i$; explode(.@j$,.@i$,","); if (getmapusers(.@j$[0]) >= 0) { delitem your_item,12219; warp .@j$[0], atoi(.@j$[1]), atoi(.@j$[2]); } else message strcharinfo(0),"Invalid map."; end; } and in the script item: { callfunc "scrollwarpzz"; } item type 11, why do not works ? Edited December 26, 2012 by nunesb Quote Link to comment Share on other sites More sharing options...
Euphy Posted December 26, 2012 Group: Members Topic Count: 72 Topics Per Day: 0.02 Content Count: 2997 Reputation: 1132 Joined: 05/27/12 Last Seen: June 1, 2017 Share Posted December 26, 2012 delitem 12219,1; Other than that, works for me. Quote Link to comment Share on other sites More sharing options...
nunesb Posted December 26, 2012 Group: Members Topic Count: 7 Topics Per Day: 0.00 Content Count: 17 Reputation: 0 Joined: 11/30/12 Last Seen: December 9, 2019 Author Share Posted December 26, 2012 (edited) works now thanks Edited December 26, 2012 by nunesb Quote Link to comment Share on other sites More sharing options...
AnnieRuru Posted December 27, 2012 Group: Members Topic Count: 18 Topics Per Day: 0.00 Content Count: 2044 Reputation: 682 Joined: 10/09/12 Last Seen: December 20, 2020 Share Posted December 27, 2012 (edited) http://www.eathena.ws/board/index.php?s=&showtopic=238404&view=findpost&p=1500001 updating this script function script tele_device { if ( getmapflag( strcharinfo(3), mf_nowarp ) ) { dispbottom "Teleport Device : you can't use this device on this map"; end; } if ( input( .@input$, 4, 21 ) ) { dispbottom "Teleport Device : invalid string length"; end; } if ( sscanf( .@input$, "%15s %d %d", .@map$, .@x, .@y ) < 3 ) { if ( sscanf( .@input$, "%15[^,],%d,%d", .@map$, .@x, .@y ) < 1 ) { dispbottom "Teleport Device : invalid format. Usage: <mapname> <x> <y>"; end; } } if ( getmapusers( .@map$ ) == -1 ) { dispbottom "Teleport Device : no such map"; end; } if ( getmapflag( .@map$, mf_nowarpto ) ) { dispbottom "Teleport Device : you can't warp to this map"; end; } if ( ( .@x || .@y ) && checkcell( .@map$, .@x, .@y, cell_chknopass ) ) { dispbottom "Teleport Device : invalid coordinate"; end; } // delitem 10000,1; // uncomment this for limited use warp .@map$, .@x, .@y; end; } but this sscanf post out some !@# error when user input invalid format <.< dunno but somehow I want to file a report for it http://rathena.org/board/tracker/issue-7059-sscanf-script-command-display-error-in-map-server/ EDIT: and I want to edit this script somemore =/ done ... EDITED again <.< this time follows the atcommand.c Edited December 30, 2012 by AnnieRuru Quote Link to comment Share on other sites More sharing options...
Question
nunesb
So, could someone help me with a scroll that when be used appear a
bar and you can write one map coordinates and you will be teleported to this place, like @warp but as an item ?
Edited by nunesbLink to comment
Share on other sites
7 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.