Jump to content

AnnieRuru

Script Developers
  • Content Count

    1677
  • Joined

  • Last visited

  • Days Won

    245

Reputation Activity

  1. Upvote
    AnnieRuru got a reaction from Kairedia in Maintenance mode   
    Download: 1.5
    plugin
     
    create table maintenance ( id int primary key auto_increment, account_id int, name varchar(23), reason varchar(99), minlv2connect tinyint, order_time datetime, start_time datetime, end_time datetime ) engine = innodb;   .
    remember to enable HPMHooking to enable this modification
    plugins_list: [ /* Enable HPMHooking when plugins in use rely on Hooking */ "HPMHooking", .
    .
    Note:
    sometimes the server countdown jumps 1 second ahead
    this is normal because the timetick from time->add is unstable
    so I use unix_time to synchronize the countdown to server time
     
    .
    .
    so, if you found some script/source code having bugs and you need to shut down your server for a short while
    then you come to the right place
    .
    @maintenance <Group ID can stay 1~99> <duration to kick in minute> <maintenance duration in minute> <reason> then a GM99 can commence the maintenance
     
    Example : '@maintenance 40 5 10 need to fix announcer script'
     
    every player with group ID 40 and below will be kick after 5 minutes
    and the server will start counting down by an announcement,
    during the maintenance of 10 minutes, group ID 40 and below will deny from login into the server
    `maintenance` table will also generate a new line, with the `reason` field as 'need to fix announcer script'
    which is useful to know when and how many times you did emergency server shutdown
    though, the actual reason for using SQL is to persist the data after server shutdown
    so the server will continue being in maintenance mode despite how many times you have shut down the server
    until it times up ( `end_time` field ), or manually do `@maintenanceoff`
     
    Note:
    you can't generate a new line using 'INSERT INTO' Sql syntax when server is online
    because I declare a bunch of variables to for them, for the purpose of saving memory consumption
    you have to login the game and type `@maintenance` to initiate the maintenance mode, otherwise it wont work.
    .
    .
    .
    @maintenanceoff if you have already finished fixing the script/source code, and there's still a lot of time left
    you can type '@maintenanceoff' to immediately turn off the maintenance mode so players can login before the schedule.
    .
    .
    .
    .
    -- Script commands --
    .
    *maintenance <Group ID can stay 1~99>, <duration to kick in minute>, <maintenance duration in minute> { , <reason> }; .
    .
    actually I have no idea why I wanna make a script command ... maybe just for fun ?
    .
    - script jsdfksdj FAKE_NPC,{ OnMon0255: maintenance 40, 5, 60; end; } .
    this will make an announcement on Monday, 2:55AM that the server will have a regular server maintenance starts from 3AM to 4AM
    during that time, player with group ID 40 will be kicked and blocked from entering the server
    the `reason` field in `maintenance` table will be defaulted to '*Regular server maintenance*'
    .
    maintenance 40, 5, 60, "系统保养";
    this will overwrite the `reason` field in `maintenance` table to '系统保养' instead of regular maintenance
    .
    .
    *maintenanceoff { <reason> }; uhh ... useless I think ...
    .
    .
    *maintenancecheck( <type> ); use 'maintenance()' to check the server is currently in maintenance mode or not
    return 0 if server is normal
    return 1 if server is going to have maintenance
    return 2 if server is having maintenance
    all other types are meant to myself to debug this junk
     
     
     
     
  2. Upvote
    AnnieRuru got a reaction from aszrool in Maintenance mode   
    Download: 1.5
    plugin
     
    create table maintenance ( id int primary key auto_increment, account_id int, name varchar(23), reason varchar(99), minlv2connect tinyint, order_time datetime, start_time datetime, end_time datetime ) engine = innodb;   .
    remember to enable HPMHooking to enable this modification
    plugins_list: [ /* Enable HPMHooking when plugins in use rely on Hooking */ "HPMHooking", .
    .
    Note:
    sometimes the server countdown jumps 1 second ahead
    this is normal because the timetick from time->add is unstable
    so I use unix_time to synchronize the countdown to server time
     
    .
    .
    so, if you found some script/source code having bugs and you need to shut down your server for a short while
    then you come to the right place
    .
    @maintenance <Group ID can stay 1~99> <duration to kick in minute> <maintenance duration in minute> <reason> then a GM99 can commence the maintenance
     
    Example : '@maintenance 40 5 10 need to fix announcer script'
     
    every player with group ID 40 and below will be kick after 5 minutes
    and the server will start counting down by an announcement,
    during the maintenance of 10 minutes, group ID 40 and below will deny from login into the server
    `maintenance` table will also generate a new line, with the `reason` field as 'need to fix announcer script'
    which is useful to know when and how many times you did emergency server shutdown
    though, the actual reason for using SQL is to persist the data after server shutdown
    so the server will continue being in maintenance mode despite how many times you have shut down the server
    until it times up ( `end_time` field ), or manually do `@maintenanceoff`
     
    Note:
    you can't generate a new line using 'INSERT INTO' Sql syntax when server is online
    because I declare a bunch of variables to for them, for the purpose of saving memory consumption
    you have to login the game and type `@maintenance` to initiate the maintenance mode, otherwise it wont work.
    .
    .
    .
    @maintenanceoff if you have already finished fixing the script/source code, and there's still a lot of time left
    you can type '@maintenanceoff' to immediately turn off the maintenance mode so players can login before the schedule.
    .
    .
    .
    .
    -- Script commands --
    .
    *maintenance <Group ID can stay 1~99>, <duration to kick in minute>, <maintenance duration in minute> { , <reason> }; .
    .
    actually I have no idea why I wanna make a script command ... maybe just for fun ?
    .
    - script jsdfksdj FAKE_NPC,{ OnMon0255: maintenance 40, 5, 60; end; } .
    this will make an announcement on Monday, 2:55AM that the server will have a regular server maintenance starts from 3AM to 4AM
    during that time, player with group ID 40 will be kicked and blocked from entering the server
    the `reason` field in `maintenance` table will be defaulted to '*Regular server maintenance*'
    .
    maintenance 40, 5, 60, "系统保养";
    this will overwrite the `reason` field in `maintenance` table to '系统保养' instead of regular maintenance
    .
    .
    *maintenanceoff { <reason> }; uhh ... useless I think ...
    .
    .
    *maintenancecheck( <type> ); use 'maintenance()' to check the server is currently in maintenance mode or not
    return 0 if server is normal
    return 1 if server is going to have maintenance
    return 2 if server is having maintenance
    all other types are meant to myself to debug this junk
     
     
     
     
  3. Upvote
    AnnieRuru got a reaction from Legend in MaxLvExpGain   
    I saw a lot of methods on how to stop players from gaining exp after certain level
    but all of them have flaws, so I release mine, its from my google drive
     
    Download: 1.3
    plugin
     
    Full Description of what this plugin DO
    stop players gain exp through killing monsters, mvp exp, or share party experience allows to gain exp by *getexp script command or BaseExp++ / JobExp++ allows players to pay guild tax exp after they hit your capped level value if your server has heal_exp, resurrection_exp or shop_exp enable,
    they will stop gain exp from these action after they hit your cap level if the player do SA_LEVELUP ( a random skill from Hocos-Pocus ) after the cap level, they can't gain exp if it doesn't follow this list, then this is bug
     
    there is a small issue with this plugin,
    everything else in the above list will still works, don't worry, tested
     
     
  4. Upvote
    AnnieRuru got a reaction from Legend in Show error item on pc_bonus2   
    honestly, status_calc_pc should have split into multiple functions ...
    if we have follow the Linux Kernel Coding Style
    in my opinion, status_calc_pc_additional function shouldn't even exist ...
    parse equipment, should has its own function, parse card, its own function
    so we can just post-hook to that function, instead of having a function doing nothing out in the middle of it =/
     
    ok let me try code this bAddMaxWeight, that has been in our repo and turn it as a plugin
    #include "common/hercules.h"#include <stdio.h>#include <stdlib.h>#include <string.h>#include "map/pc.h"#include "map/map.h"#include "common/nullpo.h"#include "common/HPMDataCheck.h"HPExport struct hplugin_info pinfo = { "baddweight", SERVER_TYPE_MAP, ">.<", HPM_VERSION,};int SP_ADDWEIGHT = 0;int pc_bonus_pre( struct map_session_data *sd, int *type, int *val ) { nullpo_ret(sd); if ( *type == SP_ADDWEIGHT ) { if ( sd->state.lr_flag != 2 ) { sd->max_weight += *val; hookStop(); } } return 0;}HPExport void plugin_init (void) { SP_ADDWEIGHT = map->get_new_bonus_id(); script->set_constant( "baddweight", SP_ADDWEIGHT, false ); addHookPre( "pc->bonus", pc_bonus_pre );} - script dfbskfh -1,{OnPCStatCalcEvent: bonus baddweight, 10000000;}hmmm ... totally possible,I just noticed there is a map->get_new_bonus_id() in our repo, somebody must have use this stuff before already
    so don't have to add whatever function anymore
    .
    . and for the topic,
    I rather say there are 2 problems with it
     
    1. bonus bAddMaxWaight, 1000;
    I think the bonus command, the 1st field should always be a constant
    this kind of typo makes the script engine read the bAddMaxWaight as a player variable
    and currently our script engine 'i' type cannot differentiate integer, constant or player variable
    maybe we can add a 'c' type, to enforce a check that field only accept constant
    BUILDIN_DEF(bonus,"cv"),however, this is still a run-time check, our script engine still suxbut the script->report_data function will able to print the variable name out
    I can pull request this soon
     
    2. and to actually having to print where the error come from, item ? pet ? combo ?
    perhaps the run_script function should have an optional field 'flag' and 'line',
    so the 'pc_bonus' and 'status_change_start' function can tell where the error come from
    this kind of stuffs should be done in the new script engine update though
    I kinda lost interest in this, better left this to Haru
  5. Upvote
    AnnieRuru got a reaction from xathenx in Guild Package   
    no need src, just query_sql will do
     
    however there is no getguildlv script command, only getgdskilllv script command though
    very easy to code though
    prontera,147,175,6 script kjdhfksdjf 100,{ .@req_online = 11; // how many players need to online to claim. Default: 11 .@req_lv = MAX_LEVEL; // minimum level of .@online players that has to be. Default: MAX_LEVEL in mmo.h if ( !getcharid(2) ) { mes "you must have a guild"; close; } if ( getguildmasterid( getcharid(2) ) != getcharid(0) ) { mes "you are not a guild master"; close; } getguildmember getcharid(2), 1; getguildmember getcharid(2), 2; for ( .@i = 0; .@i < $@guildmembercount; .@i++ ) if ( isloggedin( $@guildmemberaid[.@i], $@guildmembercid[.@i] ) ) .@online++; if ( .@online < .@req_online ) { mes "your guild must have "+ .@req_online +" guild members online"; close; } .@origin = getcharid(3); for ( .@i = 0; .@i < $@guildmembercount; .@i++ ) { if ( isloggedin( $@guildmemberaid[.@i], $@guildmembercid[.@i] ) ) { attachrid $@guildmemberaid[.@i]; if ( BaseLevel < .@req_lv ) { .@deny_name$[.@c] = strcharinfo(0); .@c++; } } } attachrid .@origin; if ( .@c ) { mes "there are "+ .@c +" member does not meet the level requirement"; mes implode( .@deny_name$, "," ); close; } for ( .@i = 0; .@i < $@guildmembercount; .@i++ ) { if ( isloggedin( $@guildmemberaid[.@i], $@guildmembercid[.@i] ) ) { attachrid $@guildmemberaid[.@i]; if ( #guild_package_claimed ) { .@deny_name$[.@c] = strcharinfo(0); .@c++; } } } attachrid .@origin; if ( .@c ) { mes "there are "+ .@c +" members already claimed this package within their account"; mes implode( .@deny_name$, "," ); close; } if ( query_sql( "select account_id as aaa, ( select last_ip from login where account_id = aaa ) as last_ip from guild_member where guild_id = "+ getcharid(2) +" group by last_ip", .@aid, .@ip$ ) < .@req_online ) { mes "same ip detected"; .@nb = query_sql( "select name, account_id as aaa, ( select last_ip from login where account_id = aaa ) as last_ip from guild_member where guild_id = "+ getcharid(2), .@name$, .@aid, .@ip$ ); for ( .@i = 0; .@i < .@nb; .@i++ ) mes (.@i +1)+". "+ .@name$[.@i] +" ("+ .@ip$ +")"; next; } mes "pass"; for ( .@i = 0; .@i < $@guildmembercount; .@i++ ) { if ( isloggedin( $@guildmemberaid[.@i], $@guildmembercid[.@i] ) ) { attachrid $@guildmemberaid[.@i]; if ( getguildmasterid( getcharid(2) ) != $@guildmembercid[.@i] ) getitem 501, 1; else getitem 501, 10; #guild_package_claimed = 1; } } attachrid .@origin; close;}
  6. Upvote
    AnnieRuru got a reaction from Legend in *setmobdata & *getmobdata   
    again, 2nd PM come in and asked me to convert this into rathena
    because they claimed this script isn't working in rathena
     
    ... and I don't believe rathena will release stuffs that are "full of bugs"
     
    1st reason
    I was scripting moderator at rathena forum during year 2013,
    so I knew how strict they are when they recruit a core developer
    there is no way their developer will make things full of bugs
     
    2nd reason
    emistry server is probably based on rathena emulator
    I'm confident emistry know how to write his mvp ladder with setunitdata
    if setunitdata is bug, then he wont be able to make that mvp ladder script with
    -> Boss Max HP will increase depend on total amount of party members who joined currently.
     
    and, this is the script I tested on my rathena test server

    prontera,159,185,5 script kjdsfkshfs 1_F_MARIA,{monster "this", -1,-1, "--ja--", 1002, 1, "";setunitdata $@mobid[0], 3, 10000000;setunitdata $@mobid[0], 2, 10000000;} .

     
     
    the main difference is at the *monster script command
     
    hercules *monster script command can be set with any variable, however, only 1 monster at a time
    if want to modify 10 monsters, has to use a loop

    prontera,155,185,5 script kdjhfksfdh 1_F_MARIA,{for ( .@i = 0; .@i < 10; .@i++ ) {.@id[.@i] = monster( "this", -1,-1, "--ja--", PORING, 1, "" );setmobdata .@id[.@i], MOBDATA_MAXHP, 10000000;setmobdata .@id[.@i], MOBDATA_HP, 10000000;}end;} .
    rathena *monster script command cannot be set, it push $@mobid in an array

    prontera,159,185,5 script kjdsfkshfs 1_F_MARIA,{monster "this", -1,-1, "--ja--", 1002, 10, "";for ( .@i = 0; .@i < 10; .@i++ ) {setunitdata $@mobid[.@i], 3, 10000000;setunitdata $@mobid[.@i], 2, 10000000;}end;} .
    so the way rathena and hercules write them are totally different
    ... and yes, rathena also can't use constant
     
     
    EDIT : codebox is broken ...
    EDIT2 : nvm leave it ....
  7. Upvote
    AnnieRuru got a reaction from Legend in *setmobdata & *getmobdata   
    I don't want rathena members come and steal my source edits anymore hahaha
     
    1.1
    plugin
    - remove MOBDATA_NAME field and MOBDATA_DIRECTION field
    - add monster's emote constants (found in src/map/status.h)
  8. Upvote
    AnnieRuru got a reaction from Legend in *setmobdata & *getmobdata   
    need to summon a hp 10,000,000 poring ?
    or you want to make emperium move ?
    yes, this plugin allows you to customize your monsters attribute
     
    Download : 1.2
    patch <-- rathena fellows, you are welcome to plagiarize this command, since your setunitdata can't change stats LOL
     
    I experienced in the past that, sometimes when my internet connection reset, my post will looks like rubbish
    this time I will make multiple posts to reduce the risk of my explanation so they wont get edited
     
     
     
  9. Upvote
    AnnieRuru got a reaction from Like it~* in Scuffle Event 2.1   
    this one ... Paskie sent me the topic link asked me to write so ...
    http://rathena.org/board/topic/93022-random-pker/
    I finished it...
     
    Download 2.1
    scuffle_event_2.1.txt
    also needs source modification of -> getmemberaid
     
    this is a twist to last man standing event
    every few hours (configurable), this event will randomly select a few players
    those players who are quick enough to type '@scuffle' will be able to join the event
    then its a last man standing ... the last one who stay in the map gains the prize
     
    the condition to pick the players for the registrations are : ( by default )
    - not a vendor
    - not in a chatroom
    - not inside an event map (nowarp and nowarpto mapflag)
    - not a GM
    - active in last 30 seconds
    - base level above 55
    - no same ip
     
    to configure the time, simply change
    OnClock0000: // Configure time here ...OnClock0600:OnClock1200:OnClock1800:..
     
     
  10. Upvote
    AnnieRuru got a reaction from Like it~* in getmemberaid checkmes   
    Download: 1.3
    plugin
     
     
    --------------------------------
     
    everything is inside this sample
    http://upaste.me/10bb21957e0971185
    its meant to attachrid online players
     
    checkmes ...
    is just like addrid with type 1 ... means only attachrid on players that doesn't have a npc dialog
    - script test dialog -1,{Onaaa: mes "hi"; close;OnInit: while (1) { getmemberaid ALL_CLIENT; for ( .@i = 0; .@i < $@onlinecount; .@i++ ) { if ( !checkmes( $@onlineaid[.@i] ) ) { // if don't have a npc dialog attachrid $@onlineaid[.@i]; addtimer 1, strnpcinfo(0)+"::Onaaa"; } } sleep 1000; }}  
  11. Upvote
    AnnieRuru got a reaction from IndieRO in King of Emperium Hill   
    I think its better to have a release topic for this instead of me update the script across separate topics
     
    Download: Hercules 1.3
    Script
    Plugin for Hercules
    Download: rAthena 1.2
    Script.
    Patch for rAthena
     
    what this event do ? ( huh ? so popular script and I still need to explain ? )
    1. make a guild
    2. join this event
    3. whack the emperium
    4. defends it until times up
    hahaha ....
     
     
    How to configure the time:
    L_start: <-- the label to start the event
    change OnClock2000: into OnSat2000: to start this event on Saturday 8pm
    L_end: <-- the label to end the event
    change OnClock2030: into OnSat2030: to end this event on Saturday 8:30pm,
    effectively makes this event runs 30 minutes
     
     
    Frequently Asked Questions:
    Question : why the Guild member can hit their own Emperium ?
    Answer : because you didn't patch and recompile
    Question: there is an exploit in this event, guild master can use Emergency Recall to abuse the prize
    Answer : I already fixed it in this topic, now the prize reward will be given after the winner warp outside the map
     
     
    original topic from eathena forum
    http://www.eathena.ws/board/index.php?showtopic=174222
    yeah ... I have been fixing this script since 7 years ago
     
     
  12. Upvote
    AnnieRuru got a reaction from caspe in Maintenance mode   
    Download: 1.5
    plugin
     
    create table maintenance ( id int primary key auto_increment, account_id int, name varchar(23), reason varchar(99), minlv2connect tinyint, order_time datetime, start_time datetime, end_time datetime ) engine = innodb;   .
    remember to enable HPMHooking to enable this modification
    plugins_list: [ /* Enable HPMHooking when plugins in use rely on Hooking */ "HPMHooking", .
    .
    Note:
    sometimes the server countdown jumps 1 second ahead
    this is normal because the timetick from time->add is unstable
    so I use unix_time to synchronize the countdown to server time
     
    .
    .
    so, if you found some script/source code having bugs and you need to shut down your server for a short while
    then you come to the right place
    .
    @maintenance <Group ID can stay 1~99> <duration to kick in minute> <maintenance duration in minute> <reason> then a GM99 can commence the maintenance
     
    Example : '@maintenance 40 5 10 need to fix announcer script'
     
    every player with group ID 40 and below will be kick after 5 minutes
    and the server will start counting down by an announcement,
    during the maintenance of 10 minutes, group ID 40 and below will deny from login into the server
    `maintenance` table will also generate a new line, with the `reason` field as 'need to fix announcer script'
    which is useful to know when and how many times you did emergency server shutdown
    though, the actual reason for using SQL is to persist the data after server shutdown
    so the server will continue being in maintenance mode despite how many times you have shut down the server
    until it times up ( `end_time` field ), or manually do `@maintenanceoff`
     
    Note:
    you can't generate a new line using 'INSERT INTO' Sql syntax when server is online
    because I declare a bunch of variables to for them, for the purpose of saving memory consumption
    you have to login the game and type `@maintenance` to initiate the maintenance mode, otherwise it wont work.
    .
    .
    .
    @maintenanceoff if you have already finished fixing the script/source code, and there's still a lot of time left
    you can type '@maintenanceoff' to immediately turn off the maintenance mode so players can login before the schedule.
    .
    .
    .
    .
    -- Script commands --
    .
    *maintenance <Group ID can stay 1~99>, <duration to kick in minute>, <maintenance duration in minute> { , <reason> }; .
    .
    actually I have no idea why I wanna make a script command ... maybe just for fun ?
    .
    - script jsdfksdj FAKE_NPC,{ OnMon0255: maintenance 40, 5, 60; end; } .
    this will make an announcement on Monday, 2:55AM that the server will have a regular server maintenance starts from 3AM to 4AM
    during that time, player with group ID 40 will be kicked and blocked from entering the server
    the `reason` field in `maintenance` table will be defaulted to '*Regular server maintenance*'
    .
    maintenance 40, 5, 60, "系统保养";
    this will overwrite the `reason` field in `maintenance` table to '系统保养' instead of regular maintenance
    .
    .
    *maintenanceoff { <reason> }; uhh ... useless I think ...
    .
    .
    *maintenancecheck( <type> ); use 'maintenance()' to check the server is currently in maintenance mode or not
    return 0 if server is normal
    return 1 if server is going to have maintenance
    return 2 if server is having maintenance
    all other types are meant to myself to debug this junk
     
     
     
     
  13. Upvote
    AnnieRuru got a reaction from Legend in Script Command : setmobdata / getmobdata   
    setmobdata and getmobdata was made by [Lance], was in eathena all the while until ultramage took it out
    https://eathena.ws/board/Eathena-Mob-Controller-System-t194375.html
    and I noticed rathena copy almost all the fields in that patch
    I always knew that patch isn't complete, that's why I trying to rewrite that patch
     
    at that time, mob controller system isn't needed, was considered custom
    but right now, this is official, as newer instance script might want to use it, thus its needed to be merged
     
    and nah ... I was just inactive at that time, it isn't just me can write it, many people also can write them
  14. Upvote
    AnnieRuru got a reaction from Legend in Script Command : setmobdata / getmobdata   
    like I said, I'll do this very very slowly
     
    so today I submit this ... the 1st one of that ... awesome yet inaccurate ... system from rathena
    https://github.com/HerculesWS/Hercules/pull/871
     
    and immediately, now you see, their getunittype is flawed
    their getunittype return values are
    0 - Monster 1 - Homunculus 2 - Pet 3 - Mercenary 4 - Elemental 5 - NPCI have no idea how they use this valueYet ? why PC type is not included ?? omfg ...
     
    if Haru permit my pull request, then ours will follow the types from existing *getmapxy
    then can do like this
    OnPCDieEvent: if ( !killerrid ) end; getmapxy .@map$, .@x, .@y, getunittype(killerrid), killerrid; dispbottom .@map$ +" "+ .@x +" "+ .@y; end;
  15. Upvote
    AnnieRuru got a reaction from Dduwsmitt in MaxLvExpGain   
    I saw a lot of methods on how to stop players from gaining exp after certain level
    but all of them have flaws, so I release mine, its from my google drive
     
    Download: 1.3
    plugin
     
    Full Description of what this plugin DO
    stop players gain exp through killing monsters, mvp exp, or share party experience allows to gain exp by *getexp script command or BaseExp++ / JobExp++ allows players to pay guild tax exp after they hit your capped level value if your server has heal_exp, resurrection_exp or shop_exp enable,
    they will stop gain exp from these action after they hit your cap level if the player do SA_LEVELUP ( a random skill from Hocos-Pocus ) after the cap level, they can't gain exp if it doesn't follow this list, then this is bug
     
    there is a small issue with this plugin,
    everything else in the above list will still works, don't worry, tested
     
     
  16. Upvote
    AnnieRuru got a reaction from caspe in map_zone_db.conf allows to restrict an ITEM TYPE   
    ok ... its my turn to give suggestion time ..
     
    http://rathena.org/board/topic/77088-certain-map-weapon-restriction/?p=239342
    noitem mapflag meant for rathena
     
    when compare my code and hercules map_zone_db.conf
    hercules can already restrict items by ID
    but my modifications can allow to restrict an item type
     
    example
    pvp_y_1-1 mapflag noitem 0this pvp map cannot use healing itemsevent_gm mapflag noitem 4,5this gm hosting event will disallow players to equip any kind of equipments 
    so how about hercules have the same thing
    { name: "PvP no Pot" inherit: ( "PvP" ) disabled_items: { IT_HEALING: true }}, { name: "GM event" disabled_items: { IT_WEAPON: true IT_ARMOR: true }},
  17. Upvote
    AnnieRuru got a reaction from Clare in Dynamic shop support   
    https://github.com/HerculesWS/Hercules/blob/master/doc/sample/npc_trader_sample.txt
    prontera,153,182,1 trader TestCustom2 4_F_EDEN_OFFICER,{ end; OnPayFunds: dispbottom "Hi: price = "+ @price +" and points = "+ @points ; if ( #KILLPOINTS < @price ) end; #KILLPOINTS -= @price; purchaseok(); end; OnCountFunds: setcurrency #KILLPOINTS, 0; end; OnInit: tradertype NST_CUSTOM; sellitem TCG_Card, 5; end; } /* prontera,156,182,1 trader give credit 1_F_MARIA,{ input #KILLPOINTS; end; } */
  18. Upvote
    AnnieRuru got a reaction from nakatto in party vs party (blue team v.s. red team)   
    my 1st impression is that ... why not just use my setbgid ?
    just setbgid the whole party into battleground team without having to use waitingroom
    .
    .
    .
    try thishttp://upaste.me/309471
     
    though, not only this script uses older techniques, those custom stuffs are too unoptimized
    that will be a lot of time needed if I want to rewrite everything from scratch
    so ... just stick with it
  19. Upvote
    AnnieRuru got a reaction from bWolfie in movespeed mapflag   
    this is useful for certain events when you want your players to move at a fixed speed
    eg: even if the player has agi up, mount peco or using Authoritative Badge,
    all players movement speed are fixed at your desire value
     
    Download: 1.3
    plugin
     
    Example:
    prontera mapflag movespeed 150 setmf_movespeed "prontera", 150; all players at prontera will move at default speed
    the value capped between 20~1000 
     
    prontera mapflag movespeed 150 99 setmf_movespeed "prontera", 150, 99; all players except GM99 at prontera will move at default speed
     
    removemf_movespeed "prontera"; remove the movespeed mapflag in prontera, without using "@reloadscript"
     
    dispbottom getmf_movespeed( "prontera" ) +""; dispbottom getmf_movespeed( "prontera", 0 ) +""; dispbottom getmf_movespeed( "prontera", 1 ) +""; first 2 lines return the movespeed value, 3rd line return the GM level bypass restriction
    Note: since the minimum value is 20, if the mapflag is off, return 0
     
     
  20. Upvote
    AnnieRuru got a reaction from Legend in All in one Event Manager -> help me find all the event scripts !   
    one of my customer sent me Euphy's Event Manager script
    and asked me to write -> join the event simply using bindatcmd @joinevent
    means, yeah, all 7 events in that script, use 1 command @joinevent will warp you to the map that event is on
    Add -> there is also a command @eventlist to tell which event going to have next, since the time is configure by GMs
    now that the script is in my hand,
    (of course I can't distribute it, but I can always reproduce it)
    I have to say that idea is very well made
    but I'm not satisfy to just limit to 7 events,
    I want to integrate ALL event scripts across eAthena/rAthena/Hercules forums
    so everyone help me search out ALL event script you can find, and post in this topic
    oh and, of course this is a free release
    I always thinking of some ways to pull rathena member to use hercules
    this project should be enough to attract some of them enough, I guess ?
    since most of the scripts I write will be hercules only script commands
  21. Upvote
    AnnieRuru got a reaction from edwardluciano in Help for item   
    then you need to make 12 items
    1 to catch the valkyrie in the inventory
    11 for the box to open with different refine rates -> 0~10
    /*replace into item_db2 ( id, name_english, name_japanese, type, price_buy, price_sell, weight, equip_upper, script ) values( 31000, 'Valkyrie_box_catch', 'Valkyrie_box_catch', 11, 1,1,10, 63, 'callfunc "catch_valkyrie_armor";' ),( 31001, 'Valkyrie_box_open_0', 'Valkyrie_box_open_0', 11, 1,1,10, 63, 'callfunc "get_valkyrie_armor", 31001, 0;' ),( 31002, 'Valkyrie_box_open_1', 'Valkyrie_box_open_1', 11, 1,1,10, 63, 'callfunc "get_valkyrie_armor", 31002, 1;' ),( 31003, 'Valkyrie_box_open_2', 'Valkyrie_box_open_2', 11, 1,1,10, 63, 'callfunc "get_valkyrie_armor", 31003, 2;' ),( 31004, 'Valkyrie_box_open_3', 'Valkyrie_box_open_3', 11, 1,1,10, 63, 'callfunc "get_valkyrie_armor", 31004, 3;' ),( 31005, 'Valkyrie_box_open_4', 'Valkyrie_box_open_4', 11, 1,1,10, 63, 'callfunc "get_valkyrie_armor", 31005, 4;' ),( 31006, 'Valkyrie_box_open_5', 'Valkyrie_box_open_5', 11, 1,1,10, 63, 'callfunc "get_valkyrie_armor", 31006, 5;' ),( 31007, 'Valkyrie_box_open_6', 'Valkyrie_box_open_6', 11, 1,1,10, 63, 'callfunc "get_valkyrie_armor", 31007, 6;' ),( 31008, 'Valkyrie_box_open_7', 'Valkyrie_box_open_7', 11, 1,1,10, 63, 'callfunc "get_valkyrie_armor", 31008, 7;' ),( 31009, 'Valkyrie_box_open_8', 'Valkyrie_box_open_8', 11, 1,1,10, 63, 'callfunc "get_valkyrie_armor", 31009, 8;' ),( 31010, 'Valkyrie_box_open_9', 'Valkyrie_box_open_9', 11, 1,1,10, 63, 'callfunc "get_valkyrie_armor", 31010, 9;' ),( 31011, 'Valkyrie_box_open_10', 'Valkyrie_box_open_10', 11, 1,1,10, 63, 'callfunc "get_valkyrie_armor", 31011, 10;' );*/function script catch_valkyrie_armor { getinventorylist; for ( .@i = 0; .@i < @inventorylist_count; .@i++ ) { if ( @inventorylist_id[.@i] == Valkyrie_Armor ) { delitem2 @inventorylist_id[.@i], 1, @inventorylist_identify[.@i], @inventorylist_refine[.@i], @inventorylist_attribute[.@i], @inventorylist_card1[.@i], @inventorylist_card2[.@i], @inventorylist_card3[.@i], @inventorylist_card4[.@i]; getitem2 31001 + @inventorylist_refine[.@i], 1, 1, 0, 0, @inventorylist_card1[.@i], @inventorylist_card2[.@i], @inventorylist_card3[.@i], @inventorylist_card4[.@i]; delitem Valkyrie_box_catch, 1; end; } } dispbottom "You don't have "+ getitemname(Valkyrie_Armor) +" in your inventory"; end;}function script get_valkyrie_armor { getinventorylist; for ( .@i = 0; .@i < @inventorylist_count; .@i++ ) { if ( @inventorylist_id[.@i] == getarg(0) ) { delitem2 @inventorylist_id[.@i], 1, 1, 0, 0, @inventorylist_card1[.@i], @inventorylist_card2[.@i], @inventorylist_card3[.@i], @inventorylist_card4[.@i]; getitem2 Valkyrie_Armor, 1, 1, getarg(1), 0, @inventorylist_card1[.@i], @inventorylist_card2[.@i], @inventorylist_card3[.@i], @inventorylist_card4[.@i]; end; } } dispbottom "shouldn't reach here ... if reach here, then its bug"; end;}EDITED ...
  22. Upvote
    AnnieRuru got a reaction from Ehwaz in *setmobdata & *getmobdata   
    hmm ...
    I actually didn't know rathena already has it when I opened this topic
    I admit they at least tried to "make stuffs happens", although some of their design is flaw
     
    I think mine is a little bit better, because mine can modify attack damage for monster, which they can't
    but rathena also has a few stuffs that I didn't have, like the monster no cast skill flag, and I haven't code setmoblook
     
    erm .... HAHAHAHA !!
    so rathena monster's stat cannot change due to a bug
    https://github.com/rathena/rathena/issues/462
    https://github.com/rathena/rathena/issues/516
    https://github.com/rathena/rathena/issues/751
     
    it doesn't matter now, I copy all their good stuffs, so now mine is better than them
     
    patch 1.2
    http://upaste.me/ed6c2196382229bc7
    crazy 500 lines modification, hercules seriously missing many stuffs
  23. Upvote
    AnnieRuru got a reaction from Tsuuu in Run Or Die event ( aka. Poring Bomb )   
    ok another script that should deserve in the script release section
    ... after having countless fix in script request ...
     
    Download: 2.3a
    script
    Make sure your hercules server is compile after 2015-11-15
     
    ok what this event do ...
    Run ! or you gonna DIE !
    this event will keep spawning Bomb Poring and BOOM and KABOOM every player they came across
    until the last player who are still alive on the map will be declare winner
     
    this should be a simple script ...
    hope you guys know how to edit by your own ...
     
     
     
     
    original topic in eathena
    it was just a simple script request ... however it went popular for some reason
     
     
     
     
  24. Upvote
    AnnieRuru got a reaction from Nebraskka in OnPCUseSkillEvent   
    After so many years of hearing rumor of this modification,
    finally today is the day I can release this to public
     
    Download : 1.5
    plugin
     
    original topic from eathena
     
     
  25. Upvote
    AnnieRuru got a reaction from Random756 in MaxLvExpGain   
    I saw a lot of methods on how to stop players from gaining exp after certain level
    but all of them have flaws, so I release mine, its from my google drive
     
    Download: 1.3
    plugin
     
    Full Description of what this plugin DO
    stop players gain exp through killing monsters, mvp exp, or share party experience allows to gain exp by *getexp script command or BaseExp++ / JobExp++ allows players to pay guild tax exp after they hit your capped level value if your server has heal_exp, resurrection_exp or shop_exp enable,
    they will stop gain exp from these action after they hit your cap level if the player do SA_LEVELUP ( a random skill from Hocos-Pocus ) after the cap level, they can't gain exp if it doesn't follow this list, then this is bug
     
    there is a small issue with this plugin,
    everything else in the above list will still works, don't worry, tested
     
     
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.