Jump to content

Angelmelody

Members
  • Content Count

    772
  • Joined

  • Last visited

  • Days Won

    23

Reputation Activity

  1. Upvote
    Angelmelody reacted to Garr in Instances crash   
    Iirc for instances you can't use such long map names, limit is like 6 or 7 characters, I don't quite remember.
     
    Client is crashing because your instance map name gets cut off, and is sent to client like "1@eleme" or something. Try to make map name shorter (4~5 characters after "@", 4 just to be sure) or use map name emulation (you'd still need to change map name client-side, but that'll be easy since you already set resnametable entries.)
  2. Upvote
    Angelmelody got a reaction from evilpuncker in Devotion(Increasing limit)   
    I think that wouldn't work as you expect
    look here  and here
     
    you should change the formula of var 'count'
     
    maybe you can try my method.
     
    count = (sd)? min((skill_lv>=5 ? 10: skill_lv),MAX_PC_DEVOTION) : 1;
  3. Upvote
    Angelmelody reacted to Dastgir in [GUIDE] Adding New Items without itemInfo.lub   
    Hello Community,
     
    Once Again, I was doing something and found something unusual, the kRO have other methods of loading Items too....
    They also load some idnum tables but with different names
     
    Unidentified items goes to
    eventnum2itemdisplaynametable.txt , eventnum2itemdesctable.txt , eventnum2itemresnametable.txt  
    Identified items:
     
    eventidnum2itemdisplaynametable.txt , eventidnum2itemdesctable.txt , eventidnum2itemresnametable.txt  
    (Just add event prefix to all file names )
     
    Points to Remember:
    This file is loaded before itemInfo, so if you have same item in itemInfo, resname and displayname will be overwritten with one on itemInfo, while both Description will appear one below one. It Works, and I have tested. These Files go inside GRF(data folder) as idnum tables used to..(before) Works on All clients with itemInfo.lub support  
    How it Looks When Overwritten:


  4. Upvote
    Angelmelody got a reaction from Jey in Implement addrid Script Command   
    https://github.com/rathena/rathena/commit/6572a9f
     
     
    Many people like this script command,it's pretty useful .
  5. Upvote
    Angelmelody reacted to AnnieRuru 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
  6. Upvote
    Angelmelody reacted to Dastgir in [Suggestion] Add *getequipuniqueid script cmd   
    But then, we cannot perform actions on string, if its integer, we can perform many things...
  7. Upvote
    Angelmelody reacted to AnnieRuru in [Suggestion] Add *getequipuniqueid script cmd   
    check Haru's post
    pc->setreg(sd, script->add_str("@expire_uniqueid_lo"), (int)(sd->status.inventory[i].unique_id&0xffffffff));pc->setreg(sd, script->add_str("@expire_uniqueid_hi"), (int)((sd->status.inventory[i].unique_id>>32)&0xffffffff));
  8. Upvote
    Angelmelody reacted to Dastgir in Charms [Item gift effect while in inventory]   
    http://upaste.me/f8b42118100b0bab2
    ^ This is as it is version, made months ago, there's no compile warnings/errors, but dont' know if it works or not with new rev,
     
    How it works?
    Add Following to item:
    Charm: true in item_db.conf in whichever item you want.
  9. Upvote
    Angelmelody reacted to AnnieRuru in About Skid Trap effect   
    no, better use pushpc script command
    prontera,155,185,5 script sdfjhsdfk FAKE_NPC,2,2,{ pushpc DIR_NORTH, 5;}if want to change player's facing direction, can try setunitdir custom script command
  10. Upvote
    Angelmelody reacted to AnnieRuru in OnPCStatCalcEvent   
    rathena already has this by default -> https://github.com/rathena/rathena/commit/27a0f3f
    someone else has tried to pull request in hercules, -> https://github.com/HerculesWS/Hercules/pull/351
    but it was denied, so have to leave this as plugin
    UPDATE: rathena has taken out -> https://github.com/rathena/rathena/commit/b65443d8f564175196d57ef9bc1d000a5661fbdc
     
    Download : 2.1
    plugin
     
    Tested with:
    conf\import\OnPCStatCalcEvent.conf
    both `@reloadscript` and `@reloadonpcstatcalcevent` command can reload conf\import\OnPCStatCalcEvent.conf file 
     
    `@reloadscript` = reload everything -> cause destruction on live server
    `@reloadonpcstatcalcevent` = only reload conf\import\OnPCStatCalcEvent.conf file , combine with `@reloadnpc` command -> not so destructive
    script: ( { // give GM permanent bonus ? OnPCStatCalcEvent: <" bonus bVit, 1234; end; "> }, { // for xxx event OnPCStatCalcEvent: <" skill TF_HIDING, 1; end; "> }, { // npc/custom/xxxevent.txt OnPCStatCalcEvent: <" if (@a) { bonus bStr, 1000; skill WZ_ICEWALL, 1; } end; "> }, ) script
    prontera,158,185,5 script djk2sfhsd 1_F_MARIA,{ @a ^= 1; mes "hmm..."; recalculatestat(); next; mes "what ?"; @a ^= 1; recalculatestat(); next; mes "maybe..."; @a ^= 1; recalculatestat(); next; mes "probably..."; @a ^= 1; recalculatestat(); next; mes "yeah..."; @a ^= 1; recalculatestat(); close; } yes, this actually works !!
     
    with version 2.0 onwards,
    no more spamming <npc name>::OnPCStatCalcEvent !!
    and even `*skill` working perfectly fine now
     
     
  11. Upvote
    Angelmelody got a reaction from AnnieRuru in OnHour00 player's value recover   
    maybe same as this issue
    http://herc.ws/board/tracker/issue-8177-some-of-gettimestr-time-format-crash-map-server/
  12. Upvote
    Angelmelody reacted to AnnieRuru in OnHour00 player's value recover   
    hmm ... I can't search on rathena forum ... stupid ... seriously rathena should fix their advance search engine
    nvm, write a new one ...
    function script F_today { return atoi( gettimestr("%Y%m%d", 9) );}prontera,155,185,5 script I Hate Doctor 1_F_MARIA,{ if ( callfunc("F_today") == last_apple_taken ) { mes "you already receive an apple"; close; } mes "an apple a day, kick the doctor away"; getitem Apple, 1; last_apple_taken = callfunc("F_today"); close;}thx to emistry 
    some server out there uses gettime(GETTIME_DAYOFYEAR), which is gettime(8) to track
    I still prefer to save in date format so I can see the value in the sql
  13. Upvote
    Angelmelody reacted to Haru in Mob DB file structure overhaul   
    Yes, it's pretty much ready, I fixed various issues yesterday. It still needs more testing, but I should be able to pull request it today
  14. Upvote
    Angelmelody got a reaction from Legend in [script cmd] cartcountitem   
    *cartcountitem( <item id> or "<item name>" )*cartcountitem2(<item id> or "<item name>",<identify>,<refine>,<attribute>,<card1>,<card2>,<card3>,<card4>)  
     
     
    This cmd will return the number of items for the specified item ID that the invoking character has in the cart inventory
     
     
     
    download:
    cartcountitem.c
  15. Upvote
    Angelmelody reacted to Rytech in New Improved 3RD JOB Sprites.   
    Does this answer your question???
     
    Male and Female Guillotine Cross standing while wearing the alternate outfit.

     
    Male and Female Guillotine Cross in battle pose.

     
    2 female Guillotine Cross's sitting. One with the alternate outfit and the other with the original.

     
  16. Upvote
    Angelmelody reacted to AnnieRuru in OnPCUseSkillEvent   
    you mean this ?
    http://herc.ws/board/topic/11292-onpcstatcalcevent/
  17. Upvote
    Angelmelody reacted to AnnieRuru in OnPCUseSkillEvent   
    Tested with
    db/re/skill_db.conf
    { Id: 2991 Name: "CUSTOM_damage" Description: "CUSTOM_damage" MaxLevel: 1 Range: 15 SkillType: { Enemy: true } Event_Label: "qwer::Ontarget" }, { Id: 2992 Name: "CUSTOM_nodamage" Description: "CUSTOM_nodamage" MaxLevel: 1 Range: 15 SkillType: { Friend: true } Event_Label: "qwer::Ontarget" }, { Id: 2993 Name: "CUSTOM_setpos" Description: "CUSTOM_setpos" MaxLevel: 3 Range: 15 SkillType: { Place: true } Event_Label: "qwer::Onpos" }, { Id: 2994 Name: "CUSTOM_self" Description: "CUSTOM_self" MaxLevel: 1 Range: 15 SkillType: { Self: true } Event_Label: "qwer::Onself" },
    data/luafiles514/lua files/skillinfoz/skillinfolist.lub
    [SKID.CUSTOM_damage] = { "CUSTOM_damage"; SkillName = "Get Target enemy", MaxLv = 1, Type = "Quest", SpAmount = { 0 }, bSeperateLv = true, AttackRange = { 15 }, }, [SKID.CUSTOM_nodamage] = { "CUSTOM_nodamage"; SkillName = "Get Target friend", MaxLv = 1, Type = "Quest", SpAmount = { 0 }, bSeperateLv = true, AttackRange = { 15 }, }, [SKID.CUSTOM_setpos] = { "CUSTOM_setpos"; SkillName = "Get Position", MaxLv = 3, Type = "Quest", SpAmount = { 0 }, bSeperateLv = true, AttackRange = { 15 }, }, [SKID.CUSTOM_self] = { "CUSTOM_self"; SkillName = "Self Cast", MaxLv = 1, Type = "Quest", SpAmount = { 0 }, bSeperateLv = true, AttackRange = { 1 }, },
    data/luafiles514/lua files/skillinfoz/skillid.lub
    CUSTOM_damage = 2991, CUSTOM_nodamage = 2992, CUSTOM_setpos = 2993, CUSTOM_self = 2994,
    data/luafiles514/lua files/skillinfoz/skilldescript.lub
    [SKID.CUSTOM_damage] = { "Test Target Enemy", "MAX Lv : 1 ", "push these variables :-", "'@useskilllv' for the skill level.", "'@useskilltarget' for the GID.", }, [SKID.CUSTOM_nodamage] = { "Test Target Friend", "MAX Lv : 1 ", "push these variables :-", "'@useskilllv' for the skill level.", "'@useskilltarget' for the GID.", }, [SKID.CUSTOM_setpos] = { "Test Coordinate", "MAX Lv : 3 ", "push these variables :-", "'@useskilllv' for the skill level.", "'@useskillx' for the X coordinate.", "'@useskilly' for the Y coordinate.", }, [SKID.CUSTOM_self] = { "Test Self", "MAX Lv : 1 ", "push these variables :-", "'@useskilllv' for the skill level.", }  
    and finally the npc script
    - script qwer FAKE_NPC,{ Ontarget: dispbottom "lv: "+ @useskilllv +" | target "+ @useskilltarget; unittalk @useskilltarget, "from "+ strcharinfo(PC_NAME); end; Onpos: dispbottom "lv: "+ @useskilllv +" | x: "+ @useskillx +" | y: "+ @useskilly; end; Onself: dispbottom "lv: "+ @useskilllv; end; OnPCStatCalcEvent: skill CUSTOM_damage, 1; skill CUSTOM_nodamage, 1; skill CUSTOM_setpos, 3; skill CUSTOM_self, 1; end; }  
    fuh !
    so, yes, this is basically making a new skill, so read this wiki on how to make a new skill
    http://herc.ws/wiki/Adding_new_skills

    Frequently Asked Question
    Why some skill ID doesn't work ?
    see this inside skill_get_index function
    //[Ind/Hercules] GO GO GO LESS! - http://herc.ws/board/topic/512-skill-id-processing-overhaul/ else if( skill_id > 1019 && skill_id < 8001 ) { if( skill_id < 2058 ) // 1020 - 2000 are empty skill_id = 1020 + skill_id - 2001; else if( skill_id < 2549 ) // 2058 - 2200 are empty - 1020+57 skill_id = (1077) + skill_id - 2201; else if ( skill_id < 3036 ) // 2549 - 3000 are empty - 1020+57+348 skill_id = (1425) + skill_id - 3001; else if ( skill_id < 5044 ) // 3036 - 5000 are empty - 1020+57+348+35 skill_id = (1460) + skill_id - 5001; else ShowWarning("skill_get_index: skill id '%d' is not being handled!\n",skill_id); }  
    because eathena forum down, let me rephrase again what this modification does
    if the skill inf type is INF_ATTACK_SKILL (target enemy only) - Enemy: true
    - kill the unit with *unitkill
    - zap another player's health with *heal -1000, 0;
    - apply curse status with *sc_start
    - make the target *unittalk ...
    - etc etc etc...
    if the skill inf type is INF_SUPPORT_SKILL (target friends and enemy) - Friend: true
    - check if the player is party members, give buff by *sc_start
    - check if the player is guild members, give buff by *sc_start during events
    - make the player show emotion
    - warp the target player to somewhere else
    - give players item/stat/cashpoints .... by *getitem/*statusup  ... *attachrid + #CASHPOINTS
    if the skill inf type is INF_GROUND_SKILL (target ground) - Place: true
    - use *monster script command to summon monsters
    - *makeitem to rain items ... skill level determine the item ID ...
    - create a temporary npc .... using duplicatenpc plugin
    - etc etc etc ...
    this is just things I can think of, basically you can do ANYTHING with any script commands available
    2nd thing is, when the skill type is INF_SUPPORT_SKILL, (Friend: true)
    you have to hold shift to target players
    this is client side limitation, require client hexing ... which I dunno how to do
    History:
    Question: Why there is no OnPCUseSkillEvent label in the npc script, but using the title OnPCUseSkillEvent ?
    ... eathena forum down
    because the original modification made during eathena was something like this
    OnPCUseSkillEvent: switch ( @useskillid ) { case 2991: switch ( @useskilllv ) { case 1: case 2: case 3: ... } break; case 2992: switch ( @useskilllv ) { ... } break; ... default: end; } which runs this label every time a player use ANY skill
    and the original custom modification tax very heavily on server resources
    that's why now this (revamp) version only pick which skill ID to run, along with your configurable event label
  18. Upvote
    Angelmelody reacted to AnnieRuru in port *preg_match from rathena   
    after 1 year ++....
    https://github.com/HerculesWS/Hercules/issues/909#issuecomment-163911353
    finally able to solve this
    #include "common/hercules.h"#include <stdio.h>#include <string.h>#include <stdlib.h>#include "map/script.h"#include "../3rdparty/pcre/include/pcre.h"#include "common/HPMDataCheck.h" // should always be the last file included! (if you don't make it last, it'll intentionally break compile time)HPExport struct hplugin_info pinfo = { "regexp", // Plugin name SERVER_TYPE_MAP,// Which server types this plugin works with? "0.1", // Plugin version HPM_VERSION, // HPM Version (don't change, macro is automatically updated)};BUILDIN(regexp) { pcre *re; pcre_extra *pcreExtra; const char *error; int erroffset, r, offset = 0; int subStrVec[30]; const char* pattern = script_getstr(st,2); const char* subject = script_getstr(st,3); if (script_hasdata(st,4)) offset = script_getnum(st,4); re = pcre_compile(pattern, 0, &error, &erroffset, NULL); pcreExtra = pcre_study(re, 0, &error); r = pcre_exec(re, pcreExtra, subject, (int)strlen(subject), offset, 0, subStrVec, 30); pcre_free(re); if (pcreExtra != NULL) pcre_free(pcreExtra); if (r < 0) script_pushint(st,0); else script_pushint(st,(r > 0) ? r : 30 / 3); return true;}HPExport void plugin_init (void) { addScriptCommand( "regexp", "ss?", regexp );}I also edited the wiki to reflect the changehttp://herc.ws/wiki/Building_HPM_Plugin_for_MSVC#PCRE_SUPPORT
  19. Upvote
    Angelmelody got a reaction from AnnieRuru in Skill modification monster summon   
    Ruru , I recommend you to use this kind of hyperlink which is with a git version
    ,why so ?it can always  keep the correct line after tons of updates
    https://github.com/HerculesWS/Hercules/blob/bb3afb0/doc/script_commands.txt#L6105
  20. Upvote
    Angelmelody got a reaction from Mikhail von Hohenheim in Spider Web Limit   
    this?
    skill_db.txt
    405,7,6,1,0,0x1,0,1,1,no,0,0,3,magic,0, PF_SPIDERWEB,Fiber Lock
  21. Upvote
    Angelmelody got a reaction from IndieRO in Spider Web Limit   
    this?
    skill_db.txt
    405,7,6,1,0,0x1,0,1,1,no,0,0,3,magic,0, PF_SPIDERWEB,Fiber Lock
  22. Upvote
    Angelmelody got a reaction from Mikhail von Hohenheim in Help, need code cell pvp   
    I covert to hercules
    http://herc.ws/board/topic/7552-pk-area-error-while-compiling/
     
    maybe some typo
    http://herc.ws/board/topic/8587-cell-pvp-pk-area-patch/
  23. Upvote
    Angelmelody got a reaction from Tsuuu in PK Area Error while compiling   
    I m not using clean emulator to create patch ,so ~ patch it by manual
    this mod should be given criedit to Mr. Postman from Thailand
    cell_pvp.diff
  24. Upvote
    Angelmelody got a reaction from evilpuncker in Item restrictions   
    An easier method , change your account  group from 99 to 100
  25. Upvote
    Angelmelody reacted to kyeme in Help me to connecting my server   
    Try :
    Open conf/network.conf 
     
    /* * List here any IP ranges a char- or map-server can connect from. * A wildcard of "0.0.0.0:0.0.0.0" means that server connections are allowed * from ANY IP. (not recommended). */allowed: ( //"0.0.0.0:0.0.0.0", <-- comment "127.0.0.1:255.0.0.0", "x.x.x.x:255.0.0.0", // <-- change x to your Lan IP or Char-Server)  
     
    or 
     
    /* * List here any IP ranges a char- or map-server can connect from. These ranges * will also be excluded from the automatic ipban in casee of password failure. * Any entry present in this list is also automatically included in the * allowed IP list. * Note: This may be a security threat. Only edit this list if you know what * you are doing. */trusted: ( "127.0.0.1:255.0.0.0", "x.x.x.x:255.0.0.0", // x is IP of your Char-Server  
    @Dev which is much better?
     
    Maybe this issue related to https://github.com/HerculesWS/Hercules/issues/737
×
×
  • Create New...

Important Information

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