-
Content Count
174 -
Joined
-
Last visited
-
Days Won
10
Posts posted by Naruto
-
-
your location and type is messed up
{ Id: 2220 AegisName: "Hat" Name: "Army Jacket" Type: "IT_ARMOR" Buy: 1000 Weight: 200 Def: 2 Loc: "EQP_HEAD_MID" ViewSprite: 1 },
Type: Item Type (string, defaults to "IT_ETC")
Loc: Equip location (bitmask array, string or int, required value for equipment)
try copying an item or fill it out properly
-
get it off of steam
-
atk = battle->calc_base_damage(src, target, skill_id, skill_lv, nk, false, s_ele, ELE_NEUTRAL, EQI_HAND_R, (sc && sc->data[SC_MAXIMIZEPOWER]?1:0)|(sc && sc->data[SC_WEAPONPERFECT]?8:0), md.flag);
gonna say its this
ELE_NEUTRAL
but im not seeing a ELE_WEAPON
enum elements { ELE_NEUTRAL=0, ELE_WATER, ELE_EARTH, ELE_FIRE, ELE_WIND, ELE_POISON, ELE_HOLY, ELE_DARK, ELE_GHOST, ELE_UNDEAD, ELE_MAX, ELE_ALL = 0xFF };
might have to re write it or monkey around until it works how you want it
the magic damage might be affected ? Any change in damage at all when you swap elements
-
-
5 hours ago, Reick said:i checked the iteminfo.lua and all those items are there, so i diffed and changed to iteminfo.lua on the pop up but still fail when i use @item.
those ids doesnt exist on item_db.conf, i think the iteminfo isnt the only problem
if it fails in game that means you dont have it in the associated id in your item_db.conf, re or pre re ... for most of them you can just copy and paste
-
-
cant stop my client from blowing up doing it with garment, but older clients can probably get away with it, all your have to do is change the structure of it again and add the new one on top
if(pos == EQP_ACC) { pos = req_pos&EQP_ACC; if (pos == EQP_ACC && (sd->equip_index[EQP_ACC_L] >= 1)) pos = sd->equip_index[EQP_SHOES] >= 0 ? EQP_GARMENT : EQP_SHOES; else if (pos == EQP_ACC && (sd->equip_index[EQI_ACC_R] >= 1)) pos = sd->equip_index[EQI_ACC_L] >= 0 ? EQP_SHOES : EQP_ACC_L; else if(pos == EQP_ACC) pos = sd->equip_index[EQI_ACC_R] >= 0 ? EQP_ACC_L : EQP_ACC_R; }
and again in the pc.h just add EQP_GARMENT to eqp_acc
-
Working on my UI and didnt find a practical use for garment slot and a few personal changes , but its a little more complicated to remove and ill save it for the second post
so as you see im equiping into the old shoe slot, and once all my slots are filled the shoe slot gets replaced
pc.h
find
#define EQP_ACC (EQP_ACC_L|EQP_ACC_R)
replace with
#define EQP_ACC (EQP_ACC_L|EQP_ACC_R|EQP_SHOES)
pc.c
find this, top of a block of code
if(pos == EQP_ACC) { pos = req_pos&EQP_ACC; if (pos == EQP_ACC) pos = sd->equip_index[EQI_ACC_R] >= 0 ? EQP_ACC_L : EQP_ACC_R; }
replace it with this
if(pos == EQP_ACC) { pos = req_pos&EQP_ACC; if (pos == EQP_ACC && (sd->equip_index[EQI_ACC_R] >= 1)) pos = sd->equip_index[EQI_ACC_L] >= 0 ? EQP_SHOES : EQP_ACC_L; else if(pos == EQP_ACC) pos = sd->equip_index[EQI_ACC_R] >= 0 ? EQP_ACC_L : EQP_ACC_R; }
Couldnt figure out what the
pos = req_pos&eqp_acc .... does but whatever
so basically this part is in charge of where the first accessory is place ( on your right looking straight at your equipment window )
pos = sd->equip_index[EQI_ACC_R] >= 0 ? EQP_ACC_L : EQP_ACC_R;
and if false, it picks the second slot and replaces it
so my addition, takes highest priority, changing the entire structure * * * *
if (pos == EQP_ACC && (sd->equip_index[EQI_ACC_R] >= 1)) pos = sd->equip_index[EQI_ACC_L] >= 0 ? EQP_SHOES : EQP_ACC_L;
so now we check if the right accessory is filled and if it is, continue with this line
now we replace shoe slot instead of right accessory
-
convert it to rsm like you would any 3ds model using the built in feature of browedit
btw Im pretty sure if you miss even 1 model not uvmapped you will get errors in game... that shut you down totally
-
Playing Cards Set
I needed something small to add to my map and i thought some playing cards would make good easter eggs at the same time
Easily modifiable,..
If you change the ace of hearts, Only the ace of hearts will be changed
These are EXTREMELY small and dont look too good big... on the numbers side
But the back side , I used an archangeling since this is a ragnarok emulator.... is quite modifiable
Dont ask me for any changes and if you need help making lines view this guide
-
Submitter
-
Submitted08/30/19
-
Category
-
-
So after testing it doesnt seem like the monster with the AI dedicated to setting off a skill when their target is effect by a status
Lets go over the code together if( mmd->bl.id == bl->id && !(battle_config.mob_ai&0x10) ) return 0; if( mmd->bl.id == bl->id && !(battle_config.mob_ai&0x10) ) return 0; Quote // 0x010: If set, mob skills defined for friends will also trigger on themselves. Not positive what the first part is about but its not important to my release so lets just delete this entire thing... thinking about it i need to test if it effects themselves without it... really easy to spot though so lets leave it be
But
It seems like cloaking is messing with my followers... let me know if you notice anything strange though if you plan on using this code
-
Hi im trying to develop some advance monster commands/conditions
Having issues... i think linking the sub protocol with the primary function ?
But It works fine when i replace it completely in the src
mob.c
static int mob_getfriendstatus_sub(struct block_list *bl, va_list ap) { int cond1,cond2; struct mob_data **fr = NULL, *md = NULL, *mmd = NULL; int flag=0; nullpo_ret(bl); Assert_ret(bl->type == BL_MOB); md = BL_UCAST(BL_MOB, bl); nullpo_ret(mmd=va_arg(ap,struct mob_data *)); if( mmd->bl.id == bl->id && !(battle_config.mob_ai&0x10) ) return 0; if (battle->check_target(&mmd->bl,bl,BCT_ENEMY)>0) return 0; cond1=va_arg(ap,int); cond2=va_arg(ap,int); fr=va_arg(ap,struct mob_data **); if( cond2==-1 ){ int j; for(j=SC_COMMON_MIN;j<=SC_MAX && !flag;j++){ if ((flag=(md->sc.data[j] != NULL))) //Once an effect was found, break out. [Skotlex] break; } }else flag=( md->sc.data[cond2] != NULL ); if( flag^( cond1==MSC_FRIENDSTATUSOFF ) ) (*fr)=md; return 0; }
Lets go over the code together
if( mmd->bl.id == bl->id && !(battle_config.mob_ai&0x10) ) return 0;
Quote// 0x010: If set, mob skills defined for friends will also trigger on themselves.
Not positive what the first part is about but its not important to my release so lets just delete this entire thing... thinking about it i need to test if it effects themselves without it... really easy to spot though so lets leave it be
if (battle->check_target(&mmd->bl,bl,BCT_ENEMY)>0) return 0;
This is what limits it to friends
static int mob_getfriendstatus_sub(struct block_list *bl, va_list ap) { int cond1,cond2; struct mob_data **fr = NULL, *md = NULL, *mmd = NULL; int flag=0; nullpo_ret(bl); Assert_ret(bl->type == BL_MOB); md = BL_UCAST(BL_MOB, bl); nullpo_ret(mmd=va_arg(ap,struct mob_data *)); cond1=va_arg(ap,int); cond2=va_arg(ap,int); fr=va_arg(ap,struct mob_data **); if( cond2==-1 ){ int j; for(j=SC_COMMON_MIN;j<=SC_COMMON_MAX && !flag;j++){ if ((flag=(md->sc.data[j] != NULL))) //Once an effect was found, break out. [Skotlex] break; } }else flag=( md->sc.data[cond2] != NULL ); if( flag^( cond1==MSC_FRIENDSTATUSOFF ) ) (*fr)=md; return 0; }
so now in your mob skill db
nanobot: { NPC_SELFDESTRUCTION: { SkillState: "MSS_ANY" SkillLevel: 1 Rate: 10000 Delay: 0 Cancelable: false SkillTarget: "MST_SELF" CastCondition: "MSC_FRIENDSTATUSON" ConditionData: "SC_BERSERK" } }
so now we should trigger skills on monster status
Now im having an issue with using my CUSTOM status as triggers though...
Ive tried adding them to my constants file...Ill let you know if i figure out more
BTW: the rest wont bother you.... and i plan on replacing onfriendstatusoff with the old onfriendstatuson . . .
-
-
possibly the same thing here
pc.c
if ((sd->job & MAPID_BASEMASK) == MAPID_TAEKWON) { // Better check for class rather than skill to prevent "skill resets" from unsetting this sd->mission_mobid = pc_readglobalreg(sd,script->add_variable("TK_MISSION_ID")); sd->mission_count = pc_readglobalreg(sd,script->add_variable("TK_MISSION_COUNT")); }
-
case TK_MISSION: if ((sd->job & MAPID_UPPERMASK) != MAPID_TAEKWON) { // Cannot be used by Non-Taekwon classes clif->skill_fail(sd, skill_id, USESKILL_FAIL_LEVEL, 0, 0); return 0; } break;
to
case TK_MISSION: if ((sd->job & MAPID_UPPERMASK) != MAPID_TAEKWON || MAPID_STAR_GLADIATOR) { // Cannot be used by Non-Taekwon classes clif->skill_fail(sd, skill_id, USESKILL_FAIL_LEVEL, 0, 0); return 0; } break;
something like that i dont use it too often
but != means if not taekwon
so make it if not taekwon OR sg
-
Updates :
case UNT_MOLOTOV: group->unit_id = skill->get_unit_id(GS_DESPERADO, 1); clif->changelook(&su->bl, LOOK_BASE, group->unit_id); group->limit = skill->get_time(group->skill_id,group->skill_lv); su->limit = skill->get_time(group->skill_id,group->skill_lv); break;
2 bottom lines reset the limit timer we used earlier to make the old unt dissipate
I was having trouble linking multiple skills together... no idea what to do about it
ex:
Using hammer fall animation slot ( unt place animation + screen shake)
using it like this
case BS_HAMMERFALL: if (pc->checkskill(sd, BS_HAMMERFALL) == 1) skill->unitsetting(src,skill_id,skill_lv,x,y,0); if (pc->checkskill(sd, BS_HAMMERFALL) == 2) skill->unitsetting(src,UT_MOLOTOV,skill_lv,x,y,0); break;
and trying to get the second bounce to effect skilldata1 time? I can make it dissapear a number of ways but couldnt attach a timer to it...
Using it alone like warp portal, making timed skills possible i just couldnt chain it anymoe 😕
probably make some really cool skills using it...
I was gonna rip it apart and remove flag for a skill lvl but meh... i dont know about doing both. . .
-
18 minutes ago, skusi123 said:@KirieZ ahh Thanks... this is new system. But...watch the video pls...how is it possible. that guy has all items in english.
He play kRO - Server Baphometyou could change your data.grf compeltly and still be fine on most servers
just swap the iteminfo folders in the system folder,
would you even get view errors ? dont think hats have a view id in the iteminfo lua
40 minutes ago, KirieZ said:What 4144 saying is that you can only change files read by Sakray (test server) client. For sakray client you have to edit the itemInfo_Sak file. For main client (kro live server) you can't edit and translate it because kRO has anti-cheat enabled and the anti-cheat will prevent you from editting it.
I dont believe a word of this though
-
-
Hi so Ive been working on making a universal skill for some unts....
In our database we have this section under a few skills who use the unt system ;
Unit: { Id: 0x86 Layout: 3 Interval: 100 Target: "Enemy" }
However we only have the option of giving a flag to the Id, unlike range and layout who can be seperated like so :
Unit: { Id: 0xbb Layout: { Lv1: 1 Lv2: 1 Lv3: 1 Lv4: 2 Lv5: 2 Lv6: 2 Lv7: 3 Lv8: 3 Lv9: 3 Lv10: 4 } Interval: -1 Target: "All" Flag: { UF_PATHCHECK: true } }
Adding a skill level modifier is possible, but heres something we can all do:
Take a look at the use of flag
Unit: { Id: [ 0x86, 0xf4 ] Layout: 3 Interval: 100 Target: "Enemy" }
Alone it will have no effect on your skill and just serves its own purpose with whatever its told to do in the src.. ( Might wanna look at the skill). . .
So warp portal uses 2 effects, the pulse then the stand still which are 2 different unts
case UNT_WARP_ACTIVE: // warp portal opens (morph to a UNT_WARP_WAITING cell) group->unit_id = skill->get_unit_id(group->skill_id, 1); // UNT_WARP_WAITING clif->changelook(&su->bl, LOOK_BASE, group->unit_id); // restart timers group->limit = skill->get_time(group->skill_id,group->skill_lv); su->limit = skill->get_time(group->skill_id,group->skill_lv); // apply effect to all units standing on it map->foreachincell(skill->unit_effect,su->bl.m,su->bl.x,su->bl.y,group->bl_flag,&su->bl,timer->gettick(),1); break;
this is the transition
group->unit_id = skill->get_unit_id(group->skill_id, 1); // UNT_WARP_WAITING clif->changelook(&su->bl, LOOK_BASE, group->unit_id);
So you could do this :
group->unit_id = skill->get_unit_id(GS_DESPERADO, 1);
looking at GS_DESPERADO in my db
Unit: { Id: [ 0x86, 0xf4 ] Layout: 3 Interval: 100 Target: "Enemy" }
I added the flag for some black fire i dont know
So my use is to have a reusuable skill.... a throwing animation that lays down whatever effect i want it too
however being reduced to 1 flag i can only attach one to the base throwing animation...
so by making new skills , or just adding them next to skills that wont bother you,
you can potentially change your skill effects however you want....
And the timer is like so :
limit = skill->get_time(skill_id,skill_lv);
case AL_WARP: val1=skill_lv+6; if(!(flag&1)) { limit=2000; } else { // previous implementation (not used anymore) //Warp Portal morphing to active mode, extract relevant data from src. [Skotlex] struct skill_unit *su = BL_CAST(BL_SKILL, src); if (su == NULL) return NULL; group = su->group; src = map->id2bl(group->src_id); if (src == NULL) return NULL; val2 = group->val2; //Copy the (x,y) position you warp to val3 = group->val3; //as well as the mapindex to warp to. } break;
so back check for flag....
Quote* flag&1 is used to determine when the skill 'morphs' (Warp portal becomes active, or Fire Pillar becomes active)
So this is how we do it the normal way :
skill.c
add your new one :
case MG_FIREWALL: if(sc && sc->data[SC_VIOLENTGALE]) limit = limit*3/2; val2=4+skill_lv; break; case BS_HAMMERFALL: if(!(flag&1)) limit=2000; break;
Im using bs_hammerfall in this case
limit is the timer to change
I gave it its own space for testing... but add it to ground skills
case BS_HAMMERFALL: skill->unitsetting(src,skill_id,skill_lv,x,y,0); break; case WZ_ICEWALL: flag |= 1; if( skill->unitsetting(src,skill_id,skill_lv,x,y,0) ) map->list[src->m].setcell(src->m, x, y, CELL_NOICEWALL, true); break;
and finally the unt I attached to it from the skill_db
{ Id: 110 Name: "BS_HAMMERFALL" Description: "Hammer Fall" MaxLevel: 5 Range: -9 Hit: "BDT_SKILL" SkillType: { Place: true } SkillInfo: { IgnoreLandProtector: true AllowReproduce: true } AttackType: "Weapon" Element: "Ele_Weapon" KnockBackTiles: 2 SkillData1: 6000 SkillData1: 2000 CoolDown: 0 Requirements: { SPCost: 15 } Unit: { Id: 0x10a Range: 2 Layout: 3 Interval: 100 Target: "Enemy" Flag: { UF_SKILL: true } } },
I made this one
Id: 0x10a
back in skill.c
case UNT_MOLOTOV: group->unit_id = skill->get_unit_id(GS_DESPERADO, 1); clif->changelook(&su->bl, LOOK_BASE, group->unit_id); group->limit = skill->get_time(group->skill_id,group->skill_lv); su->limit = skill->get_time(group->skill_id,group->skill_lv); map->foreachincell(skill->unit_effect,su->bl.m,su->bl.x,su->bl.y,group->bl_flag,&su->bl,timer->gettick(),1); break;
this is dirty but working, need to clean it up but im going to bed now o/
last thing I seperated them like this so i can reuse the same skill effect i use for throwing in a place skill :
Earlier i said we seperated the groud placement, well lets go do this to it
case BS_HAMMERFALL: if (pc->checkskill(sd, BS_HAMMERFALL) == 1) skill->unitsetting(src,skill_id,skill_lv,x,y,0); if (pc->checkskill(sd, BS_HAMMERFALL) == 2) skill->unitsetting(src,MG_FIREWALL,skill_lv,x,y,0); break;
-
So ive been trying to deal with the movement on the grid but had issues with direcitonal, and lagging when you get hit
Ive tried many things but the problem kept persisting until someone asked me why the lag doesnt happen on flying side kick....
case MR_LUNGE: if (unit->movepos(src, bl->x, bl->y, 1, 1)) { skill->brandishspear(src, bl, skill_id, skill_lv, tick, flag); clif->slide(src, bl->x, bl->y); } break;
for my skill.c im using brandishspear function in an attack that lunges me towards the target
before i would get caught during my cast time and i could move 3-4 times before the game elastic banned me
if (unit->movepos(src, bl->x, bl->y, 1, 1)) {
if we wrote it like this
case MR_LUNGE: unit->movepos(src, bl->x, bl->y, 1, 1); skill->brandishspear(src, bl, skill_id, skill_lv, tick, flag); break;
it looks like the zombies walk to the location i pointed at, but then i get shot there after a second or two...
but then i set it to this :
case MR_LUNGE: unit->movepos(src, bl->x, bl->y, 0, 0); skill->brandishspear(src, bl, skill_id, skill_lv, tick, flag); break;
So it seems to me that unit_movepos is just another modifier we can use
the final 2 moifiers are
int easy, bool checkpath
these are either 1 or 0... and i have no idea how they work without going through all the skills that use them however it seems to do the same things in game with my current code so just pick something your trying to match or flip em around if they dont work for whatever reason
So in order to move visually we actually have to use these functions OR CLICK THE MOUSE ANYWHERE AND YOU WILL ZAP TO THAT CELL WITH THE WRITTEN ABOVE:
clif->snap
clif->slide
skill->blown
All are usuable in different ways... I just wanted to clearify how to remove the lag
Actually a few notes from my clif.c jjust trying to go over and find this immediately
static void clif_blown(struct block_list *bl) { //Aegis packets says fixpos, but it's unsure whether slide works better or not. nullpo_retv(bl); clif->fixpos(bl); clif->slide(bl, bl->x, bl->y); }
Oh it turns out
clif->fixpos is also a way to move you around the map
-
just adding it to skilleffectinfo doc will override stuff,
or you can do this
case SM_PROVOKE: case SM_SELFPROVOKE: case MER_PROVOKE: { int failure; if( (tstatus->mode&MD_BOSS) || battle->check_undead(tstatus->race,tstatus->def_ele) ) { map->freeblock_unlock(); return 1; } //TODO: How much does base level affects? Dummy value of 1% per level difference used. [Skotlex] clif->skill_nodamage(src,bl,skill_id == SM_SELFPROVOKE ? SM_PROVOKE : skill_id,skill_lv, (failure = sc_start(src,bl,type, skill_id == SM_SELFPROVOKE ? 100:( 50 + 3*skill_lv + status->get_lv(src) - status->get_lv(bl)), skill_lv, skill->get_time(skill_id,skill_lv)))); if( !failure ) { if( sd ) clif->skill_fail(sd, skill_id, USESKILL_FAIL_LEVEL, 0, 0); map->freeblock_unlock(); return 0; } unit->skillcastcancel(bl, 2); if( tsc && tsc->count ) { status_change_end(bl, SC_FREEZE, INVALID_TIMER); if( tsc->data[SC_STONE] && tsc->opt1 == OPT1_STONE ) status_change_end(bl, SC_STONE, INVALID_TIMER); status_change_end(bl, SC_SLEEP, INVALID_TIMER); status_change_end(bl, SC_TRICKDEAD, INVALID_TIMER); } if( dstmd ) { dstmd->state.provoke_flag = src->id; mob->target(dstmd, src, skill->get_range2(src,skill_id,skill_lv)); } } break;
youd have to rip this line apart
clif->skill_nodamage(src,bl,skill_id,skill_lv, sc_start(src,bl,type,100,skill_lv,skill->get_time(skill_id,skill_lv)));
and change the last constant to this
case BD_ADAPTATION: clif->skill_nodamage(src,bl,skill_id,skill_lv,-1); break;
-1 makes it not display effect, skill still works.. havnt really tested it tho
thst means you would have to seperate the sc_start from it.. pretty simple
-
skill->brandishspear_dir(&tc,dir,4);
2 things
correction from original post :
Quote So this is why its flipped, the final number is the placement , so if you set it to 0, it would be closer to you... its weird but id leave it -4 for the same results that i get
I wrote -4 as a test and wrote it all up with it, but -4 would be back wards and 4 would be forward
and 2)
setting this to 0 caused some tile error with what i posted, probably fix able but would be a waste ? weird
-
Hi I was working on another skill for a bit today
I wanted to get certain mobs to spawn in certain squares...
I managed to make a skill that places an area similar to cultivation from creator
I couldnt figure out any other way to get them to spawn how I wanted but this should suffice...
Switching it to target and NOT GROUND PLACED might take a bit of tweaking though this is a PLACE skill
skill.c
case CL_MAGGOT: int md1 = mob->once_spawn_sub(src, src->m, x-5, y, clif->get_bl_name(src), 1005, "", SZ_SMALL, AI_NONE); int md2 = mob->once_spawn_sub(src, src->m, x+5, y, clif->get_bl_name(src), 1005, "", SZ_SMALL, AI_NONE); int md3 = mob->once_spawn_sub(src, src->m, x, y-5, clif->get_bl_name(src), 1005, "", SZ_SMALL, AI_NONE); int md4 = mob->once_spawn_sub(src, src->m, x, y+5, clif->get_bl_name(src), 1005, "", SZ_SMALL, AI_NONE); mob->spawn (md1); mob->spawn (md2); mob->spawn (md3); mob->spawn (md4); break;
I just declared a bunch of stuff, gave them numbers, you can name them whatever you want
as you can see where it casts, it spawns enemies about 5 cells in 4 directions from the targeted location, again, this is a PLACE skill
1005 is my monster ID,
feel free to change the SZ_ and AI_ to whatever you want
AI_ATTACK is your personal friendly summons
and skill.db
{ Id: 1614 Name: "CL_MAGGOT" Description: "Spawn Maggots" MaxLevel: 1 Range: 12 Hit: "BDT_SKILL" SkillType: { Place: true } DamageType: { NoDamage: true } SkillData1: 300000 CoolDown: 0 Requirements: { SPCost: 10 } },
ps :
If you want them to follow you i think you just need this
md->master_id = sd->bl.id;
I dont know how to use it though as of the time I am writing this
-
My Client Crashes
in Client-Side Support
Posted
no its the client thats incompatible with some things...
just grab the grf you updated off of kro main website and toss it in your folder
check your data.ini and make sure your thing is diffed for multiple grfs if its still not working