Jump to content

popochun

Members
  • Posts

    5
  • Joined

  • Last visited

Everything posted by popochun

  1. As the title says, What I'm attempting is how do I go about changing Acolyte's skill Signum Crucis to reduce all monster's defense instead of just Undead's and Demon's? I am currently looking at a section of this skill in src/map/skill.cpp and I can't seem to find where exactly does it perform a check whether monsters on screen are Undead/Demon or not. If anyone could point me to the right direction I would greatly appreciate it. Here's the snippet of where I think modification should be made (again, not sure if this is correct or not) case AL_CRUCIS: if (flag&1) sc_start(src,bl,type, 23+skill_lv*4 +status_get_lv(src) -status_get_lv(bl), skill_lv,skill_get_time(skill_id,skill_lv)); else { map_foreachinallrange(skill_area_sub, src, skill_get_splash(skill_id, skill_lv), BL_CHAR, src, skill_id, skill_lv, tick, flag|BCT_ENEMY|1, skill_castend_nodamage_id); clif_skill_nodamage(src, bl, skill_id, skill_lv, 1); } break;
  2. Sorry I posted this in a wrong forum. Please feel free to delete this. As the title says, What I'm attempting is how do I go about changing Acolyte's skill Signum Crucis to reduce all monster's defense instead of just Undead's and Demon's? I am currently looking at a section of this skill in src/map/skill.cpp and I can't seem to find where exactly does it perform a check whether monsters on screen are Undead/Demon or not. If anyone could point me to the right direction I would greatly appreciate it. Here's the snippet of where I think modification should be made (again, not sure if this is correct or not) case AL_CRUCIS: if (flag&1) sc_start(src,bl,type, 23+skill_lv*4 +status_get_lv(src) -status_get_lv(bl), skill_lv,skill_get_time(skill_id,skill_lv)); else { map_foreachinallrange(skill_area_sub, src, skill_get_splash(skill_id, skill_lv), BL_CHAR, src, skill_id, skill_lv, tick, flag|BCT_ENEMY|1, skill_castend_nodamage_id); clif_skill_nodamage(src, bl, skill_id, skill_lv, 1); } break;
  3. I have browsed around the forum and found the following threads. [Release+Guide] Common Ailment Status Icon [Unofficial] Extra Status Icons I followed the instruction detailed in those threads and found partial success ( server compiled and executed without any errors ). However the status icon still did not show up and I'm not sure what I missed. I'm hoping that someone might be able to point me to the right direction. Here's what I did Server-side: Status.hpp: add EFST_VIPSTATE before EFST_MAX /// @APIHOOK_END /// Do not modify code above this, since it will be automatically generated by the API again EFST_VIPSTATE = 1500, EFST_MAX, }; add SC_VIPSTATE before SC_MAX SC_VIPSTATE, SC_MAX, //Automatically updated max, used in for's to check we are within bounds. }; Status.cpp add the following line into initChangeTables function StatusIconChangeTable[SC_VIPSTATE] = EFST_VIPSTATE; map/script_constants.hpp export script efst_vipstate constant export_constant(EFST_VIPSTATE); Client Side: Create "custom.grf" and set itas the first index in DATA.INI add required files into data\luafiles\lua files\stateicon (efstids.lub, stateiconimginfop.lub, stateiconinfo.lub, stateiconinfo_f.lub) add vip status icon called "VIP1.TGA" to data\texture\effect data\luafiles514\lua files\stateicon\efstids.lub: add EFST_VIPSTATE to the bottom like so: EFST_REF_T_POTION = 1169, EFST_ADD_ATK_DAMAGE = 1170, EFST_ADD_MATK_DAMAGE = 1171, EFST_VIPSTATE = 1500, __newindex = function() error("unknown state") end } data\luafiles514\lua files\stateicon\stateiconimginfo.lub: point EFST_VIPSTATE to the .tga file (in PRIORITY_WHITE section) [EFST_IDs.EFST_AURABLADE] = "icon04.tga", [EFST_IDs.EFST_HELLS_PLANT_ARMOR] = "hells_plant_armor.tga", [EFST_IDs.EFST_VIPSTATE] = "VIP1.TGA" } data\luafiles514\lua files\stateicon\stateiconinfo.lub: add description to the end of file StateIconList[EFST_IDs.EFST_VIPSTATE] = { descript = { {"VIP STATUS"} } } Testing To trigger vip: I use a usable item with the following script vip_time 60; To see vip status: I used the following script with on PC login event to display status in the chatbox and add effect/status effect to activate status icon. OnPcloginEvent: bonus_script_clear EFST_VIPSTATE; if(vip_status(1)) { bonus_script "{}",99999999,0,0,EFST_VIPSTATE; dispbottom "TEST EFST_VIPSTATE" + EFST_VIPSTATE; dispbottom "TEST EFST_MAX" + EFST_MAX; //not quite needed yet sc_start SC_VIPSTATE,-1,0; set .@timer, vip_status(2); dispbottom "--- VIP ----"; dispbottom "=========================="; dispbottom "VIP Player"; dispbottom Remaining VIP duration :"+callfunc("Time2Str",.@timer); dispbottom "=========================="; end; } } Result: - after using vip activation item and re-login nothing shows up - server was compiled/built/executed without any errors/warnings - VIP status icon did not show up on the sidebar at all (other buffs showed up fine) Any help would be appreciated!
  4. Came a cross this post and checked the code. There's a minor bug in your first code segment. .@numbers = ex_cd_pts / .limit; must comes before ex_cd_pts = ex_cd_pts % .limit; Otherwise this is working great! nice job and thanks for the script!
×
×
  • Create New...