fiction

Members
  • Content count

    49
  • Joined

  • Last visited

1 Follower

About fiction

  • Rank
    Advanced Member
  • Birthday 07/05/93

Profile Information

  • Gender
    Male
  • Location:
    Santiago, Chile
  • Emulator:
    Hercules

Recent Profile Visitors

1817 profile views
  1. oh.. what a pity. Thank you Annie Well if something is searching for something like rentitem for specific job, a workaround that i did, is this: [email protected] = eaclass(); if (([email protected]&EAJ_BASEMASK) == EAJ_SWORDMAN){ rentitem 1117,86400; equip 1117; setequipoption EQI_HAND_L, 1, [email protected], [email protected]; } if (([email protected]&EAJ_BASEMASK) == EAJ_MAGE){ rentitem 1619,86400; equip 1619; setequipoption EQI_HAND_R, 1, [email protected], [email protected]; } if (([email protected]&EAJ_BASEMASK) == EAJ_ARCHER){ rentitem 1705,86400; equip 1705; setequipoption EQI_HAND_R, 1, [email protected], [email protected]; } if (([email protected]&EAJ_BASEMASK) == EAJ_ACOLYTE){ rentitem 1601,86400; equip 1601; setequipoption EQI_HAND_R, 1, [email protected], [email protected]; }
  2. Hi, in Herc, exist any method to use rentitem with random option system?. For example, in rathena exist rentitem3, where i can use the flag RandomIDarray, RandomValueArray, etc *rentitem3 <item id>,<time>,<identify>,<refine>,<attribute>,<card1>,<card2>,<card3>,<card4>,<RandomIDArray>,<RandomValueArray>,<RandomParamArray>{,<account_id>}; Greetings!.-
  3. Hi, what is the use for tb_layer_priority in lua files/datainfo i've added some customs items to my server, and the client return the follow error: Client: 20181226
  4. Wonderful!, i'm gonna try it at home, thank you so much!
  5. Thank you @AnnieRuru, @4144 and yes, indeed is part of your script, but i made some modification (I hope you do not mind hehe), because i don't want to trade in Zeny, i want to trade in custom items. I'll try to re-read the documentation of herc and try to adapt it.
  6. In case that i use SQL Queries to fill the entry, how can i do here?. In rathena i use query sqls to fill my menu and the shop, and then order alphabetically. For example: OnInit: [email protected]_db$ = "mob_db"; [email protected]_db$ = "item_db"; [email protected] = query_sql( "SELECT DISTINCT LEFT( `name_japanese`, 1 ) AS alphabets FROM `"+ [email protected]_db$ +"` RIGHT JOIN `"+ [email protected]_db$ +"` ON `"+ [email protected]_db$ +"`.`id` = `"+ [email protected]_db$ +"`.`dropcardid` WHERE `type` = 6 AND `mexp` = 0 GROUP BY `name_japanese` ORDER BY alphabets;", .alphabet$ ); for ( [email protected] = 0; [email protected] < [email protected]; [email protected]++ ) { .alphabet_menu$ = .alphabet_menu$ + .alphabet$[[email protected]] +" Cards:"; [email protected] = query_sql( "SELECT `"+ [email protected]_db$ +"`.`id` FROM `"+ [email protected]_db$ +"` RIGHT JOIN `"+ [email protected]_db$ +"` ON `"+ [email protected]_db$ +"`.`id` = `"+ [email protected]_db$ +"`.`dropcardid` WHERE ~(`MODE`) & 32 AND `type` = 6 AND `mexp` = 0 AND LEFT( `name_japanese`, 1 ) = '"+ .alphabet$[[email protected]] +"' GROUP BY `name_japanese` ORDER BY `name_japanese` LIMIT 128;", [email protected] ); for ( [email protected] = 0; [email protected] < [email protected]; [email protected]++ ) npcshopadditem "card_mob#"+ .alphabet$[[email protected]], [email protected][[email protected]], 3; } freeloop 0; end; } // Shop Normal Cards - itemshop card_mob#A -1,30004,1515:1 - itemshop card_mob#B -1,30004,1515:1 - itemshop card_mob#C -1,30004,1515:1 - ietmshop card_mob#D -1,30004,1515:1 ...
  7. Hi to all, In herc, what is the way to manipualte custom shops via npcshopdelitem, npcshopadditem, etc? For example, in rathena, when i use shops that the currency is an item, i use itemshop, like this... - itemshop asdfas -1,7828,13036:100,13411:100 and then i call that shop via callshop "asdfas",0; How can i do that here in herc? Greetings.-
  8. Hi, i wondering if someone can help me to fix the following code that i have from php. The problem that i have, it's that isn't counting the total card in the server, always stated in null valor.
  9. jolaperras
  10. UP
  11. Thank you for the response and sorry for the delay of my answer. I've tried your tips, and the only problem that i continue having is the HP storage of the mob. Now the change are working perfectly, but the transfer of the previous HP of the mob isn't working. For example, 1.- The monster 3500 has 1 milion of HP. 2.- Recive 100,000 damaged. The HP now is 900,000 3.- The monster changed its element (Mob 3501). 4.- The new monster obtain 900,000 HP, because it was the previous HP of the mob (3500), and so on. Here is the script: [email protected],50,50,4 script asdasd 4_NFWISP,{ donpcevent("#fff::OnStart"); } [email protected],1,5,3 script #fff CLEAR_NPC,{ OnStart: .GID = monster ("[email protected]", 50, 55, _("--ja--"), 3500, 1, "DarkThanatos::OnDead"); initnpctimer "fff#Start"; initnpctimer; set .temp, getcharid(0); set @temp, getcharid(0); end; OnTimer6000: // Utiliza 'getunitdata' en vez de 'getmonsterinfo' [email protected]_hp = getunitdata( .GID,UDT_MAXHP ); [email protected] = getunitdata( .GID,UDT_HP ); //Mob 3500 + rand(1,4) [email protected] = rand( 1,4 ); //Array de los 4 elementos setarray([email protected]$[1], "Fire", "Earth", "Water", "Wind"); // TODO: required mob controller script commands or other alternatives workaround. getmapxy([email protected]$, [email protected], [email protected], UNITTYPE_MOB, .GID); // Mata al monstruo después de obtener su posición killmonsterall "[email protected]"; .GID = monster( [email protected]$,[email protected],[email protected],"--ja--",[email protected],1,"DarkThanatos::OnDead" ); setunitdata( .GID,UDT_HP,[email protected] ); setunitdata( .GID,UDT_MAXHP,[email protected]_hp ); initnpctimer; // Simplificar el uso de 'switch' mapannounce "[email protected]","MOB changed to "[email protected]$[[email protected]]+" element!",bc_map; end; } Big thanks in advance !.
  12. UP
  13. Hi, I need some help to make a mob change the appareance every 25 sec, and store the previous HP and position. Is similar to Facewrom, This is that i have currently, but have error when i try to spawn the mob in the previous position. [email protected],50,50,4 script asdasd 4_NFWISP,{ donpcevent("fff#Start::OnStart"); } [email protected],0,0,0 script fff#Start HIDDEN_NPC,{ OnStart: [email protected] = monster ("[email protected]", 50, 55, _("--ja--"), 3500, 1, "DarkThanatos::OnDead"); initnpctimer "fff#Start"; initnpctimer; end; OnTimer6000: killmonsterall "[email protected]"; [email protected]_hp = getmonsterinfo( 3500,UDT_MAXHP ); [email protected] = getmonsterinfo( 3500,UDT_HP ); [email protected] = rand( 3501,3504 ); // TODO: required mob controller script commands or other alternatives workaround. getmapxy(@mapname$, @mapx, @mapx, UNITTYPE_MOB); [email protected] = monster( @mapname$,@mapx,@mapx,"--ja--",[email protected],1,"DarkThanatos::OnDead" ); setunitdata( [email protected],UDT_HP,[email protected] ); setunitdata( [email protected],UDT_MAXHP,[email protected]_hp ); initnpctimer; switch ( [email protected] ) { case 3501: mapannounce "[email protected]","MOB changed to Fire element!",bc_map; break; case 3502: mapannounce "[email protected]","MOB changed to Earth element!",bc_map; break; case 3503: mapannounce "[email protected]","MOB changed to Water element!",bc_map; break; case 3504: mapannounce "[email protected]","MOB changed to Wind element!",bc_map; break; } end; OnMyMobDead: end; OnDead: end; } [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: monster (7 parameters): [Debug]: Data: variable name='@mapname$' index=0 [Debug]: Data: variable name='@mapx' index=0 [Debug]: Data: variable name='@mapx' index=0 [Debug]: Data: string value="--ja--" [Debug]: Data: variable name='[email protected]' index=0 [Debug]: Data: number value=1 [Debug]: Data: string value="DarkThanatos::OnDead" [Debug]: Source (NPC): DarkThanatos2#Start at [email protected] (0,0) [Warning]: script_get_val: cannot access player variable '@mapname$', defaulting to "" [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: monster (7 parameters): [Debug]: Data: string value="" [Debug]: Data: variable name='@mapx' index=0 [Debug]: Data: variable name='@mapx' index=0 [Debug]: Data: string value="--ja--" [Debug]: Data: variable name='[email protected]' index=0 [Debug]: Data: number value=1 [Debug]: Data: string value="DarkThanatos::OnDead" [Debug]: Source (NPC): DarkThanatos2#Start at [email protected] (0,0) [Warning]: script_get_val: cannot access player variable '@mapx', defaulting to 0 [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: monster (7 parameters): [Debug]: Data: string value="" [Debug]: Data: number value=0 [Debug]: Data: variable name='@mapx' index=0 [Debug]: Data: string value="--ja--" [Debug]: Data: variable name='[email protected]' index=0 [Debug]: Data: number value=1 [Debug]: Data: string value="DarkThanatos::OnDead" [Debug]: Source (NPC): DarkThanatos2#Start at [email protected] (0,0) [Warning]: script_get_val: cannot access player variable '@mapx', defaulting to 0 [Debug]: mapindex_name2id: Map "" not found in index list! [Warning]: buildin_monster: Attempted to spawn monster class 3502 on non-existing map '' [Debug]: Source (NPC): DarkThanatos2#Start at [email protected] (0,0) Greetings.-
  14. Hello, Who can help me with an npc that restrict all the mvp cards in a certain map. I have an idea with the sql, but i don't know how to do it more perfectly. This is that i'm looking for: If a player enter in the map that is restricted a message will appear informing that the mvp cards isn't allowed. .mvpcards = query_sql("select item_db.id from item_db right join mob_db on item_db.id = mob_db.dropcardid where mexp > 0 and type = 6 group by name_japanese;", .idmvpcard); Greetings.- !
  15. Thank you, now its working !