Leaderboard
Popular Content
Showing content with the highest reputation on 01/13/12 in Posts
-
Toasty's Warper by: ToastOfDoom So this is a project I've been working on and off for a while and only really just had it done to a release standard recently. The original reason I started this script was cause of Annie's Favorite Warper script. While pretty original in that I think it was the 1st one to implement a favorites menu in a warper, I absolutely detested how ugly that script looked. No offence to annie, but it looked like an absolute nightmare to configure (menu structure in one area, warp data in another, lots of duplicated data all over the place making it very easy to make a mistake). So I set out to write a warper that meets this one objective: Be able to portray the configuration of all map and menu structure data in a single glance. Features: Easy to configure layout Zeny cost configuration on menu/submenu/map levels Configurable dynamic access to menus and maps Remembers last warps Brain hurting complexity in other parts of the script (not guaranteed) Download: ver 1.32 - 21-04-2011 (r14682 trunk) ver 1.31 - 27-04-2011 (r14682 trunk) ver 1.30 - 26-04-2011 (r14682 trunk) ver 1.20 - 12-02-2011 (r14682 trunk) ver 1.10 - 13-01-2011 (r14413 trunk) ver 1.00 - 08-01-2011 (r14413 trunk) Mirrors: ver 1.32 - 21-04-2011 (r14682 trunk) How to configure: Look for the 'LoadData' label in the script (line 184). All menu and map data is stored in this one subroutine. Configuring the menus is as easy as moving lines around. Details for each function as follows. AddLastWarpNode(): Will add a menu item to access previously used warps. The maximum amount of stored last maps is 64, however by default it has been set to 10 (.numLastWarps) AddNode(<node_name>{, <modifier>, <modifier_value>{, <modifier>, ...}}): This will add a submenu to the current menu. The cost value for zeny is optional. The cost value will carry on to all nodes and maps within the submenu unless overwritten but another cost value either at a lower node or map. Setting cost to 0 will cancel any costs from being carried down. //Eg. This will make a menu called "Dungeons" with a menu called "Abbey, Cursed Monastery" within StartNode("Dungeons"); StartNode("Abbey, Cursed Monastery"); AddMap("Abbey, Cursed Monastery - Level 1", "abbey01", 51, 14); AddMap("Abbey, Cursed Monastery - Level 2", "abbey02", 150, 11); ... EndNode(); EndNode(); EndNode(): This will exit the current menu that was opened with AddNode() and go back to the parent menu of that menu. Consider it like brackets. All StartNode()s must end somewhere with an EndNode(). AddMap(<map_title>, <map_name>, <x>, <y>{, <modifier>, <modifier_value>{, <modifier>, ...}}): This will add a map to the current menu. //Eg. This will make a menu called "Towns" and place 5 maps within StartNode("Towns"); AddMap("Alberta", "alberta", 28, 234); AddMap("Aldebaran", "aldebaran", 140, 131); AddMap("Amatsu", "amatsu", 198, 84, 5000); AddMap("Ayothaya", "ayothaya", 150, 163); AddMap("Comodo", "comodo", 209, 143); EndNode(); Modifiers: With the 'AddNode' and 'AddMap' commands you are able to add modifiers to either give a set price or dynamically allow access to the specified menu or map (and some other things). All modifiers will cascade down all children nodes until overwritten by another modifier. You can apply multiple modifiers but only one of each (ie..can't use 2x "gm" modifiers, but you can use 1x "gm", 1x "woe") Descriptions of all avaiable modifiers and examples follow: "zeny" - This sets a zeny cost to either all maps within the set node or the set map depending on how it was used. //Eg. This will make all maps within the 'Dungeons' menu cost 1000z StartNode("Dungeons", "Zeny", 1000); StartNode("Abbey, Cursed Monastery"); AddMap("Abbey, Cursed Monastery - Level 1", "abbey01", 51, 14); AddMap("Abbey, Cursed Monastery - Level 2", "abbey02", 150, 11); ... EndNode(); EndNode(); "gm"- This limits access to the menu/map according to the player's gm level. If set to positive it will check if the player's gm level is above or equal. If set to negative, it will check if the player's gm level is below or equal to the absolute of the value //Eg. This will make all maps within the 'Fields' menu accessible to only GMs above or equal to level 20 StartNode("Fields", "gm", 20); StartNode("Amatsu Fields"); AddMap("Amatsu Field 1", "ama_fild01", 190, 197); EndNode(); StartNode("Ayothaya Fields"); AddMap("Ayothaya Field 1", "ayo_fild01", 173, 134); AddMap("Ayothaya Field 2", "ayo_fild02", 212, 150); ... EndNode(); EndNode(); //This will make all maps within the 'Fields' menu accessible to only players below or equal to level 40 StartNode("Fields", "gm", -40); StartNode("Amatsu Fields"); AddMap("Amatsu Field 1", "ama_fild01", 190, 197); EndNode(); StartNode("Ayothaya Fields"); AddMap("Ayothaya Field 1", "ayo_fild01", 173, 134); AddMap("Ayothaya Field 2", "ayo_fild02", 212, 150); ... EndNode(); EndNode(); "woe"- This limits access to the menu/map according to the current state of WoE. This relies on the OnAgitStart/OnAgitEnd events at the end of the script. //1: active when woe inactive //2: active when woe active //3: active regardless of woe setting(default) //Eg. This will only allow access to the Castles menus and maps when WoE is active StartNode("Castles", "woe", 2); StartNode("Aldebaran Castles"); AddMap("Neuschwanstein(Aldebaran)", "alde_gld", 48, 83, "mapUsers", "aldeg_cas01"); AddMap("Hohenschwangau(Aldebaran)", "alde_gld", 95, 249, "mapUsers", "aldeg_cas02"); ... EndNode(); EndNode(); "job"- This limits access to the menu/map according to the player's current job. Calculation method is exactly the same as the one used for jobs in item_db (ie..add up the bitmasks) (S.) Novice (2^00): 0x00000001 Swordman (2^01): 0x00000002 Mage (2^02): 0x00000004 Archer (2^03): 0x00000008 Acolyte (2^04): 0x00000010 Merchant (2^05): 0x00000020 Thief (2^06): 0x00000040 Knight (2^07): 0x00000080 Priest (2^08): 0x00000100 Wizard (2^09): 0x00000200 Blacksmith (2^10): 0x00000400 Hunter (2^11): 0x00000800 Assassin (2^12): 0x00001000 Unused (2^13): 0x00002000 Crusader (2^14): 0x00004000 Monk (2^15): 0x00008000 Sage (2^16): 0x00010000 Rogue (2^17): 0x00020000 Alchemist (2^18): 0x00040000 Bard/Dancer (2^19): 0x00080000 Unused (2^20): 0x00100000 Taekwon (2^21): 0x00200000 StarGladi (2^22): 0x00400000 Soul Linker (2^23): 0x00800000 Gunslinger (2^24): 0x01000000 Ninja (2^25): 0x02000000 //Eg. This will only allow access to the Payon dungeons to Wizards and Hunters and only when WoE is inactive StartNode("Payon Dungeon", "job", 0x00000A00, "woe", 1); AddMap("Payon Dungeon - Lvl 1", "pay_dun00", 21, 183); AddMap("Payon Dungeon - Lvl 2", "pay_dun01", 19, 33); AddMap("Payon Dungeon - Lvl 3", "pay_dun02", 19, 63); AddMap("Payon Dungeon - Lvl 4", "pay_dun03", 155, 159); AddMap("Payon Dungeon - Lvl 5", "pay_dun04", 201, 204); EndNode(); "upper"- This limits access to the menu/map according to wherever the player is a normal/high/baby class. Like with 'job' this works the same as the 'upper' value in item_db. //1: Normal jobs //2: Upper jobs //4: Baby jobs //Eg. This will only allow access to the casino to baby classes AddMap("Casino", "cmd_in02", 179, 129, "upper", 4); "gender"- This limits access to the menu/map according to the sex of the player. 0 is female, 1 is male, 2 for both. "blvl"- This limits access to the menu/map according to the base level of the player. This works exactly the same as with "gm" except with baselevels instead of gmlevels. "flag"- This will limit access to the menu/map depending on the value of a specified variable. This is very useful for restricting access to things when an event is on or wherever the player as passed a certain quest. //Eg. This will only allow access to the guild dungeons if the global variable $@testEvent is not set to 0. StartNode("Guild Dungeons", "flag", "$@testEvent"); AddMap("Baldur Guild Dungeon", "gld_dun01", 119, 93); AddMap("Luina Guild Dungeon", "gld_dun02", 39, 161); AddMap("Valkyrie Guild Dungeon", "gld_dun03", 50, 44); AddMap("Britoniah Guild Dungeon", "gld_dun04", 116, 45); EndNode(); "function"- This will limit access to a menu/map depending on the output of a specified function. Works very similar to the 'flag' modifier only will allow greater control but is also alot more computationally expensive. Recommend only using when needed and to keep things simple in the function. The script will automatically pass the following variables to the function: //Node: "Node", <nodeid>, <nodename> //Map: "Map", <mapid>, <maptitle>, <mapname>, <mapx>, <mapy>, <mapcost> //Eg. This will only allow access to the Thanatos tower to players that are in a party and above or equal to level 90 StartNode("Thanatos Tower", "function", "PartyCheckFunc", "blvl", 90); AddMap("Thanatos Tower - Lvl 1", "tha_t01", 150, 39); AddMap("Thanatos Tower - Lvl 2", "tha_t02", 150, 136); AddMap("Thanatos Tower - Lvl 3", "tha_t03", 220, 158); AddMap("Thanatos Tower - Lvl 4", "tha_t04", 59, 143); AddMap("Thanatos Tower - Lvl 5", "tha_t05", 62, 11); ... EndNode(); ... function script PartyCheckFunc { return strcharinfo(1) != ""; } "mapUsers"- This will change the map used for the getmapusers() calculation. This allows you to warp to one map, but display the user count for another map (like for castles) Other Settings: .showNodeUserCount: 0/1 turns on/off the user count display for nodes/menus .showMapUserCount: 0/1 turns on/off the user count display for maps Important Notes: In the case that you add a map that doesn't exist a message will be displayed within your map server console indicating the name of the map. There is a limit to the length of the menu can reach. This limit is defined by 2047 characters. When this limit is reached the client will crash. The script has measures to prevent client crashes, but the menu in question will still be broken. A message in the map server console will display indicating the affected menu. Please modify the structure of the menu to prevent the overflow. Additionally all GMs above the set .gmAccessLvl will have the option to check which menus will overflow. Likewise this overflow problem will also affect the lastwarp menu so it is advised you keep the .numLastWarp value to a reasonable value (10-20) Technical stuff: Just some data on the structure of the script for those who want to modify functions (read this if you are interested in picking apart the script) ShowMenu(): Displays the menu and returns the map id of the selected map ComputeMenu(<menu_ptr>): Generates menu string. Modify this to change how you want the menus to look SelectMap(<mapid>): Does the final zeny subtraction and warping to the map after selection. You can modify this to have it do other things with the cost value (eg, subtract coins instead) All map data are stored in an infinite style array of the following names: # = index / 128, % = index % 128 .maps_name_#[%] .maps_map_#[%] .maps_x_#[%] .maps_y_#[%] .maps_cost_#[%] Node data are stored in the following manner: node_ptr$ = .menu_<nodeid>$ node[0] = Node title node[1] = Basic precomputed node menu string node[2+] = Either a pointer to a map or another node_ptr$. If it is a number it is a map id otherwise it is the menu pointer for the next submenu. Last warp menu is simply a pointer to "@menu_lastwarps$" As always will appreciate bugs reports, suggestions & criticism. This work is licensed under a Creative Commons Attribution-Noncommercial-Share Alike 3.0 Unported License2 points
-
For the love of god, please use: www.webhostingtalk.com You will be able to find a great host and be able to read up on their reviews.2 points
-
In all sub-forums of the Scripting section, you are still bound to follow all of rAthena Board Rules 1.Do not release scripts that are not of your own creation unless you can provide evidence of explicit permission from the original author to do so 2. Attempt to post your script in the proper section. If you're not certain as to where to post it, feel free to ask one of the Moderators 3. Your script release should contain at the very least a 3-4 sentence description that states what your script does. 4. Attempt to have multiple hosts for your scripts as to prevent dead links. 3 or more links are ideal. [ Hosting Sites ] 5. Links to your script should directly provide the script without the need for registration. Hosting your script in X Site and requiring users to register to see the script is not permitted. 6. Do not use code tag or codebox tag to release your script. 7. Your script should not contain any malicious code or produce the name of any servers in game where it will be visible to other players. 8. Your script release should be tested, polished, map-server error free, and debugged fully or to a certain extent prior to release. 9. Do not create topics in this section asking for support or requesting for scripts. 10. Do not judge others script as being too simple. The standard for scripts is decided by Scripting Moderators, inappropriate scripts will be removed by the staff. If you think a script is not appropriate for release, hit the report button and it'll be reviewed by Scripting Moderators. 11. Do not simply state that there is an error or a bug in the script. If there is an error, state what the error is. If there is a bug, state as to how one can replicate the bug. 12. Do not post to simply state that the link is down. The best course of action would be to send the author a Personal Message informing them that their link is down. Consequences rAthena Staff reserves the right to add to and change the rules at any time. It is your duty to keep up with any changes and follow them to the best of your ability. Version 1.0 - Created the rules. 1.5 - Edited a typo.2 points
-
Toasty's WoE Controller So...once upon a time when I did have a server to run and one of the few questions that would always come up was..."What time was WoE and what region was it?" (WoE on this server was broken up into regions). Usually I didn't know the answer and so I had to go through the awful task of trying to find it in the forums and eventually I just directed everyone to it. And then there's the issue with people not understanding timezones or knowing how to substract. Soo...one day i got off my lazy ass and wrote this little thingymabob that would tell people exactly how long left it is till WoE, where it was and other random tiddy-bits of info. Worked pretty well. Anyways...just recently I was pretty bored and decided to clean it up abit and thought...well...since it's already keeping time..why not just let it do all the agit_controller stuff too. So I added that and presto!....this came out." Features: WoE 2.0 ready Novice WoE ready Real-time updated time display of how much longer till WoE starts/ends WoE configurable on a Castle level basis Useful castle owner listing feature Even more useful region map warper feature Some random skip/start/end WoE functions for GMs Auto-Restart WoE after server crash Now with a mildly easy to use online generator script. Though tested on trunk, will very much likely work on stable (provided you tick the correct box while generating the script) Description: Basically what you get is a little banner NPC with a chatroom on it who's title updates with the amount of time left till WoE starts or ends. (Little idea stolen from one of annie's scripts =P...some mvp arena i think) Clicking on the NPC (the npc not the chatroom) opens up a menu with a couple useful options which are self-explanatory. Note: Castle Owner listing is only for castles of the current/upcoming WoE session. Too much spam to print all Scripts: ver 1.22 - 26-05-2011 (r14829 trunk) (Mirror) (Mirror) ver 1.21 - 21-12-2010 (r14413 trunk) ver 1.20 - 18-10-2010 (r14413 trunk) ver 1.11 - 25-01-2009 (r13435 trunk) ver 1.10 - 03-01-2009 (r13405 trunk) ver 1.02 - 09-10-2008 (r13271 trunk) ver 1.01 - 21-09-2008 (r13091 trunk) ver 1.00 - 10-09-2008 (r13091 trunk) Backup ver1.22 Installation: Generate the script by inputting the times you require and any options you may want in the generator form Install the script as you would for any NPC. Depending if you want to use this to replace agit_controller.txt or not you can replace the contains of ./npc/guild/agit_controller.txt with this script. IF you use this script to manage your WoE timings (which you prob would..). Remove any existing WoE timing management scripts. By default... ./npc/guild/agit_controller.txt -if you didn't replace it with this script ./npc/guild2/agit_start_se.txt -for woe2 controller If you want to use any of the Novice castles make sure you enable them in ./npc/scripts_athena.conf npc: npc/events/nguild/nguild_dunsw.txt npc: npc/events/nguild/nguild_treas.txt npc: npc/events/nguild/nguild_guardians.txt npc: npc/events/nguild/nguild_warper.txt npc: npc/events/nguild/nguild_ev_agit.txt npc: npc/events/nguild/nguild_flags.txt npc: npc/events/nguild/nguild_managers.txt npc: npc/events/nguild/nguild_kafras.txt Restart/Startup server...enjoy =D Limitations: Since WoE can be run in pretty much any format, it's kinda impossible for this script to accommodate for all types of WoE. Anyways...here are the limitations of this script. WoE sessions have to start and end on the same day (usually the case but good to state) Only one WoE session is available at a time. In order to start another one, you must end the current one. The generator will complain if you try to overlap sessions. Standard array/variable limits. 128 for number of WoE sessions and separate regions. 31 different castles per region(Not that anyone is gonna use all that...unless they're planning like an all world WoE extravaganza). Time is actually updated using an infinite loop. Depending on the refresh rate setting timing can be off sync with the time WoE actually starts/end (default 500ms/half a second. This isn't a problem if you are using the built in controller) Due to the way in which the original WoE scripts were coded and how I implemented the castle based controller (calls OnAgitEnd/2 events) castles MAY remain open if they do not have an owner. Notes: Yup...idea for timer based waitingroom was stolen from annie's Mvp Ladder script This script is semi-protected against @reloadscript/@loadnpc commands. Though not recommended that you load the script using this manner, if you must after loading the scripts, to restart the script click each NPC (one NPC only needs to start to initialise the floating main script that controls the WoE timing, but each banner NPC needs to be clicked to start the waitingroom) When doing the timings, it is VERY IMPORTANT that you have the times in order from sunday to saturday and starting time. If you don't do this it'll skip over them till the next week. WoE happens in the order that the timings are specified. Sometimes it may be desirable to have them out of order so it can do one region this week and another one a different week...But this is only a side-effect to the timing design and weird things might happen..so do it at your own risk. (This is no longer a problem in ver 1.10 provided you didn't mess with the config after generating the script) You can change the rate at which the banner is updated by modifying the ".banner_refresh_rate" value in the CONFIG section. The banner will update every '.banner_refresh_rate' seconds. This script is rather dynamic and so adding additional castles just involves modifying and adding arrays. Adding castles to existing regions should be self-explanatory. But setting up a new region...maybe not.. Steps to setup a new region are as follows: Make up a prefix for the region you are adding (in this example I am using "test" Put all the maps for the castles in an array named ".castles_***" (eg. .castles_test$) Put all the put all the woe ending function addresses into an array named "woe_kill_***" (eg. .woe_kill_test$) Go to the constants section in the script (search for CONSTANTS START) Add the castles and portals in the corresponding sections Add the prefix to the end of the array .regions$, the name of the region in .region_names$ and the map that contains all the castle entrances in the array .region_maps$ Tah da!! you have now added a new region. Feel free to test the hell out of this and report bugs/suggestions/criticism. This work is licensed under a Creative Commons Attribution-Noncommercial-Share Alike 3.0 Unported License1 point
-
No es una instance.. es una torre normal para evento para todo el mundo de tu server.... si llegas al final tendrás la opción de ganar una old box que da un gorros de kafra o puedes cambiarlo por lo que quieras.....1 point
-
type /showname maby you accidentally patched the option to default enabled, or didnt patch to disable it, or something o_O1 point
-
I only have one screenshot from it. No videos. If anyone wants to make one, feel free to do so though.1 point
-
- script abcde -1,{ OnPCLoadMapEvent: getmapxy(.@amap$,.@mapx,.@mapy,0); if(.@amap$!="quiz_00") end; query_sql("SELECT last_ip FROM `login` WHERE account_id = "+getcharid(3)+"", .@LastIp$); query_sql("SELECT account_id FROM `login` WHERE last_ip = '"+.@LastIp$+"'", .@AccountId); set .@aidtemp,getcharid(3,strcharinfo(0)); for(set .@i ,0;.@i<getarraysize(.@AccountId);set .@i,.@i+1) { if(attachrid(.@AccountId[.@i])) { getmapxy(.@qmap$,.@qmapx,.@qmapy,0); if (.@qmap$== .@amap$) set .@j,.@j+1; } detachrid; } attachrid .@aidtemp; if(.@j > $@MaxWimdows) warp "SavePoint",0,0; end; OnInit: set $@MaxWimdows,1; end; } //------Enable map OnPCLoadMapEvent------------------- quiz_00 mapflag loadevent1 point
-
for me is ovh (kimsufy fr | kemsirve es) 20$ / montly the big machine ^^1 point
-
Pues déjame decirte que este proyecto es completamente gratis. Por lo menos si vas a empezar un proyecto como tal, ten la decencia de brindar un estilo amigable; de quien es la bronca si ustedes están poniendo tanta "cosa"? no creo que sea de los usuarios verdad? Obviamente es de los "manager" de ese proyecto, así que...La verdad? ustedes gastan de más porque quieren, si vas a manejar algo así ya es cosa de preguntarle a los usuarios si les gusta, que podemos hacer para mejorar, a lo mejor reducir las imágenes, no se, algo, pero si, es muy incomodo, y vuelvo a repetir, ustedes gastan de más porque quieren, si lo supieran manejar bien, no habría tanta bronca. No me vengas hablar a mi de gastar si yo entiendo de todo eso, una cosa es saber gastar, y otra cosa es gastar "a lo wey" como decimos en México. Edit: Apesar de eso, se han ganado a la mayoria de los latinos, y dan buen soporte, eso nadie lo niega, pero bueno! no todos somos iguales ;1 point
-
Los que os quejáis de la publicidad me gustaría veros contratando un host dedicado y pagándolo de vuestro bolsillo. ¿o creéis que el dinero sale de los árboles? Por favor, si tenéis quejas me parece estupendo, pero del sistema de financiación, no gracias.1 point
-
A mi tambien me gusta mas este foro, presenta un mejor espacio que Divine RO, aunque si hacen bastante falta los usuarios :S1 point
-
[script][npc] Advanced Tombstone v1.03 Зачастую игроки хотят знать, когда воскреснет MVP, да и кто такой супер-крутой его смог забить, а многим админам хотелось бы иметь удобный инструмент для работы с MVP (отключить не залезая в конфиги, убить, чтобы игроки могли спокойно бегать по локации или оживить убитого MVP для соискателей приключений). Описание Скрипт позволяет управлять MVP (и не только, при желание), получать информацию о состояние MVP. Скачать Скрипт версии 1.03: скачать (в базе монстров все mvp от 13.2, Maya Purple и один тестовый квестовый моб) (Используя скрипт вы обязуетесь следовать лицензионному соглашению указанному в скрипте) Вот список возможностей: После смерти Монстра создаётся Tombstone с информацией о монстре, кто его убил и времени его воскрешения; Имеется несколько режимов состояние монстра (Живой, мёртвый и ждёт воскрешения, отлючен); Запоминание режима даже после перезагрузки (координаты Tombstone так же запоминаются); При отключение выставляется в стандартно установленное место (Координаты прописываются в таблицу скрипта); Координаты respawn'а выставляются как и в map monster (а не как в areamonster, кому интересна разница читайте doc'и); Время respawn'а указывается как в map monster (а не как в оригинальном Tombstone); Можно указывать имя моба, а не брать стандартное из mobdb; Специальный NPC с помощью которого GM'ы могут управлять режимом монстров (Убить монстра, оживить немедленно, отключить) и получить некоторые сведения о состояние монстра; После смерти монстра создаётся NPC Tombstone с окном чата сообщающим когда монстр оживёт, что он отключен или был убит и квест завершён; При разговоре с NPC Tombstone сообщается имя убившего (отключившего) его персонажа, для GM'ов есть функция мгновенного оживления монстра; Создание монстра можно вызывать из любого скрипта (методом вызова глобальной функции), что позволяет делать квесты. Недостатки и ошибки Я могу назвать только одну ошибку — при использование GM команды @killmonster скрипт работает некорректно. Так же не работает зеркало (будет говорить, что MVP на карте необнаружены, imho, не критично, т.к. Tombstone показывает нужную информацию и без того). Если что-то найдёте — отписывайтесь. Скриншоты Примечание Базы монстров скрипта настроены на обычный сервер, не Renewal, если вам нужно для Renewal, то боюсь придётся немного потрудиться базы сильно отличаются. Вы так же должны очистить(закомментировать) все записи о расположение текущих монстров в скриптах NPC. Для доступа к MVP Master и функции оживления монстра из Tomb'а нужен GM уровень не ниже 50ого, иначе NPC вас будут просто троллить Таблица монстров скрипта Массивы данных: setarray .mvpbmid[0],0; // Mob ID setarray .mvpbdl1[0],0; // Respawn Delay1 (in seconds, if is 0 - then mob consider as Quest Mob and not creating on first OnInit) setarray .mvpbdl2[0],0; // Respawn Delay2 (in seconds, if is 0 - then not create Tomb and Chat Room) // Default Tombstone coordinates X,Y setarray .mvpbcdx[0],0; setarray .mvpbcdy[0],0; // Area coordinates to spawn X,Y,X1,Y1 (if X and Y = 0 - get random area) setarray .mvpbcx[0],0; setarray .mvpbcy[0],0; setarray .mvpbcx1[0],0; setarray .mvpbcy1[0],0; setarray .mvpbaname$[0],""; // Name for Admins NPC (if empty then get from MobDB) setarray .mvpbmname$[0],""; // Mob name setarray .mvpbevent$[0],""; // Do Event on Kill Monster (empty to nothing todo) mvpbmid — MobID (идентификатор монстра) соответствующий идентификатору в базе - mob_db.txt mvpbdl1 — Время респауна (указывается в секундах!), через какое минимальное кол-во времени монстр воскреснит, если значение установлено равное 0, то монстр считается квестовым и после своей смерти он не пересоздаётся, чат комната так же имеет иное содержание, а не время до следующего респауна mvpbdl2 — Разница во времени респауна (в большую сторону, указывается в секундах), если значение установлено равное 0, то после смерти монстра не создаётся его Tombstone mvpbcdx, mvpbcdy — Расположение по-умолчанию Tombstone (X, Y), это место, где будет установлен Tombstone при убийстве или отключение монстра через Admin NPC mvpbcx, mvpbcy, mvpbcx1, mvpbcy1 — X, Y - коордианты появления монстра (если координаты равны 0, то коордианты берутся случайным образом относительно всей локации), X1, Y1 - разброс в появление монстра (X, Y при этом являются центром зоны появления, а X1, Y1 - диаметром) mvpbaname$ — Название монстра для меню Admin NPC, если оставить пустым, то возьмётся имя из базы mvpbmname$ — Название монстра, можно указывать какое имя из базы брать ("--ja--" - корейское название, "--en--" - английское название, или указывать своё название) mvpbevent$ — Обработка Event после смерти моба, чаще всего необходима для создания квестов (смотрите пример в скрипте с Yggas'Worth) Пример для монстра Fallen Bishop: callsub(L_AddMobDB,1871,7200,600,238,73,236,78,21,18,"","--en--",""); Добавление монстра Добавление монстра проходит в две стадии — первая стадия включает в себя дубликата NPC на нужную локацию с определённым именем, вторая — прописывание данных в таблицу монстров скрипта. Итак, для начала добавляем дубликат NPC, тут ничего сложного, находим последнюю запись дубликатов, допустим, у нас всего два монстра и последняя запись, пусть будет примерно такая: prontera,0,0,0 duplicate(tombstone_dup) Tomb#2_mvp 565 Запоминаем, что название NPC — Tomb#2_mvp, сейчас нам очень важна скрытая часть названия «2_mvp» — здесь важная цифра, это «2», значит в таблице всего 2 монстра, добавляем нашего нового монстра, пусть это будет Beelzebub (#1873), заглядываем в npc/mobs/dungeons/abbey.txt и находим нашего монстра: abbey03,0,0,0,0 boss_monster Beelzebub 1873,1,43200000,600000,1 Комментируем эту строчку и добавляем после последнего найденного нами дубликата NPC в скрипте строчку, указывая в скрытом название NPC следующий номер (2_mvp был последним, значит теперь будет 3_mvp): abbey03,0,0,0 duplicate(tombstone_dup) Tomb#3_mvp 565 Отлично, теперь нам надо добавить информацию о монстре, добавляем в таблицу монстров скрипта строчку: callsub(L_AddMobDB,1873,43200,600,120,112,0,0,0,0,"","--en--",""); Монстр добавлен и при перезагрузке появится на указанной локации. Немного о глобальной функции Для взаимодействия самого скрипта монстров с внешними NPC было созданное небольшое API (не слишком хорошо написанное, но рабочее). Это функция tmvp_menu, она имеет входящие ключи для определения того, что именно вам нужно (getarg(0)), вот id ключей и их краткое описание: 0 - Вызывается при основном OnInit скрипта монстров, создаёт нужные переменные и устанавливает первый пункт для Admin NPC - «Nothing» 1 - Вызывается при OnInit скрипта монстров, запоминает нужные данные для последующей работы 2 - Возвращает созданное меню (список монстров со статусом, работает медленно, т.к. обращается к глобальным данным) 3 - Устанавливает режим монстра в «Суицид», входящим данным (getarg(1)) является номер пункта меню, возвращает 0 — если всё прошло успешно, 1 — монстр не может быть установлен в режим (режим уже установлен или монстр отключен) 4 - Устанавливает режим монстра в «Оживить», возвращает 0 — если монстр создан успешно, 1 — монстр уже создан и не может быть создан снова, входящим данным является номер монстра (mvpbid) в таблице монстров скрипта 5 - Возвращается текст из пункта меню (Обычно это имя монстра), входящим данным является номер пункта меню 6 - Устанавливает режим монстра в «Суицид», входящим данными является mvpbid и имя персонажа, которое будет установлено как имя убийцы монстра, возвращаемые данные такие же, как и для 3 7 - Возвращает состояние монстра (Текстовое сообщение), входящим данным является mvpbid 8 - Возвращается mvpbid, входящим данным является номер пункта меню 9 - Устанавливает режим монстра в «Убить и отключить», входяшими данными является mvpbid и имя персонажа, возвращает 0 — при успешном выполнение, 1 — если монстр уже отключён. Формат вызова функции: callfunc("tmvp_menu", <номер ключа>(, <входящие переменные>)); Входящие переменные: mvpbid — это ID монстра в таблице скрипта, это не одно и то же, что и MobID. номер пункта меню — это уникальный идентификатор пункта меню для Admin NPC, который создаётся в 0 и 1 ключах функции, вызывается такое меню ключом 2 charname — имя персонажа игрока Пример, убить монстра №2: callfunc("tmvp_menu", 6, 2, strcharinfo(0)); Пример, воскресить монстра №2: callfunc("tmvp_menu", 4, 2); Для наглядности в скрипт добавлен NPC Yggas'Worth, он создаёт Поринга с кастумным названием и ждёт пока вы его не убьёте. На самом деле это самый простой пример, но вы можете добавлять каких-либо сложных монстров и создавать на этой основе квесты. Немного о глобальных переменных Их несколько, но вы можете использовать их в своих скриптах для создания квестов: $tmvp<mvpbid>_state — Признак состояния монстра (см ниже) $tmvp<mvpbid>_nick$ — Имя персонажа убившего монстра (учтите, что при измененеие состояния эта переменная не очищается) $tmvp<mvpbid>_x и $tmvp<mvpbid>_y — Координаты где расположен Tombstone (учтите, что при измененеие состояния эта переменная не очищается) $tmvp<mvpbid>_time — Время (указан tick с момента начала эпохи) до начала действия признака события (используется только для подсчёта времени respawn'а монстра) $tmvp<mvpbid>_created — Создан ли монстр (необходимо для некоторых проверок) (0 - нет, не создан, 1 - создан и бегает) $tmvp<mvpbid>_frun — Первый или нет запуск (0 - первый запуск, 1 - запуск уже был), необходимо для квестовых мобов, чтобы они не создавались Признаки состояния монстров: 0 — Монстр жив и где-то бегает 1 — Признак на суицид 2 — Монстр убит и ожидает времени respawn'а 3 — Признак на немедленное оживление 4 — Признак на суицид и отключение 5 — Монстр отключён и ждёт включения 6 — Для квестового монстра, состояние его смерти (убит и ожидает оживления через квест) Вы можете использовать эти данные для написания скриптов квестов (смотрите пример в скрипте на Yggas'Worth). Механика Скрипт работает на режимах, это так называемые признаки событий, действия происходят не мгновенно, а только создают признак этого события. К примеру, вы выставляете монстру признак события на суицид, обработка этого события произойдёт в течени 5 секунд, когда внутренний обработчки скрипта распознает этот признак и примет решение о том, что нужно сделать. Итерация обработчика - 5 секунд (OnTimer5000), вы можете поменять это значение на другое, но на свой страх и риск, учтите, что чем меньше вы делаете время обработки, тем больше нагрузок создаётся на ваш сервер (я считаю идеальным обработку каждые 10 секунд, но выставил 5, чтобы задержка составляла минимальную серверную). Благодарности Своей девушке, что разрешала работать над скриптом по ночам Sanasol — автору основного скрипта, я взял кусочек его кода (функция вывода времени, копирайт указан в скрипте, прошу прощения, было лень писать точно такую же функцию). Heler'у — за то, что оказывал некоторую помощь. nndsl — за подкинутую идею.1 point