classy5 0 Posted November 26, 2015 (edited) Item use to -> target(Player&Monster) teleport the target to prontera (if possible please include that the target will be teleported back to where he was after 30 sec) [herc staff]: can u please move this to script request? thanks Edited November 26, 2015 by classy5 Quote Share this post Link to post Share on other sites
0 Aeromesi 180 Posted November 26, 2015 Moved to appropriate topic.Is this possible with the mobcontroller system @@AnnieRuru? Quote Share this post Link to post Share on other sites
0 AnnieRuru 957 Posted November 26, 2015 I don't even understand what the topic is asking about Quote Share this post Link to post Share on other sites
0 Aeromesi 180 Posted November 26, 2015 Warp a player OR monster to prontera for 30 seconds, then warps them back to previous map Quote Share this post Link to post Share on other sites
0 AnnieRuru 957 Posted November 26, 2015 require OnPCUseSkillEvent modification https://www.eathena.ws/board/index.php?showtopic=274088 the trick is, create a new skill, in the item script, use 'itemskill' script command, then unitwarp the target ID using variable @useskilltarget pssss.... at the moment I'm writing getitemname2 function ... then I have to update setmobdata .... busy .... so this is not in my top priority to do list Quote Share this post Link to post Share on other sites
0 classy5 0 Posted November 28, 2015 Warp a player OR monster to prontera for 30 seconds, then warps them back to previous map did you happen to figure it out sir? Quote Share this post Link to post Share on other sites
0 AnnieRuru 957 Posted November 30, 2015 (edited) ok its time to show the almighty OnPCUseSkillEvent @@classy5 although the topic title has the word 'Simple', but this isn't simple at all because have to create a new skill and create a new item hmm ... since have to move back the target of the monster to original position, have to use getmapxy with mobs https://github.com/HerculesWS/Hercules/pull/871 so ... confimportOnPCUseSkillEvent.txt warp_target,"warp_target::Onwarp".dbreskill_db.txt 1305,15,0,1,0,0,0,9,0,no,0,0x0,0,none,0, warp_target,warp_target.dbreskill_require_db.txt 1305,0,0,0,0,0,0,99,0,0,none,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0.dbreskill_cast_db.txt 1305,0,0,0,0,0,100,0.dbitem_db2.conf { Id: 32499 AegisName: "item_warp_target" Name: "warp_target" Type: 11 Weight: 1 Script: <" itemskill warp_target,1; ">},.clientSystemitemInfo.lub [32499] = { unidentifiedDisplayName = "Warp Target", unidentifiedResourceName = "파리의날개", unidentifiedDescriptionName = { "Warp the target into guild_vs2 and warp back in 10 seconds", }, identifiedDisplayName = "Warp Target", identifiedResourceName = "파리의날개", identifiedDescriptionName = { "Warp the target into guild_vs2 and warp back in 10 seconds", }, slotCount = 0, ClassNum = 0 },.dataluafiles514lua filesskillinfozskillid.lub warp_target = 1305,.dataluafiles514lua filesskillinfozskillinfolist.lub [SKID.warp_target] = { "warp_target"; SkillName = "Warp Target Unit", MaxLv = 1, Type = "Quest", SpAmount = { 0 }, bSeperateLv = true, AttackRange = { 15 }, },.and finally the npc script - script warp_target FAKE_NPC,{Onwarp: .@gid = @useskilltarget; getmapxy .@map$, .@x, .@y, UNITTYPE_PC; getmapxy .@map$, .@x2, .@y2, UNITTYPE_MOB, .@gid; unitwarp .@gid, "guild_vs2", 50,50; warp "guild_vs2", 50,50; .@origin = getcharid(3); sleep 10000; // 10 seconds if ( attachrid(.@origin) ) warp .@map$, .@x, .@y; if ( !getmapxy( .@dummy$, .@dummy, .@dummy, UNITTYPE_MOB, .@gid ) ) { // announce "still alive !", bc_all; unitwarp .@gid, .@map$, .@x2, .@y2; } end;}.Have Fun figure this out! EDIT: seems skill name and item name must not the same, so rename into "item_warp_target" Edited December 1, 2015 by AnnieRuru Quote Share this post Link to post Share on other sites
0 classy5 0 Posted December 1, 2015 @@AnnieRuru , my bad :/ well im idk if some script are simple or not. i got this from the process [warning]: skill_castend_damage_id: Unknown skill used:1305 i dont have OnPCUseSkillEvent.txt so i just created one. Quote Share this post Link to post Share on other sites
0 AnnieRuru 957 Posted December 1, 2015 seems like you are able to follow the process just didn't recompile with the plugin you need this plugin http://herc.ws/board/topic/11296-onpcuseskillevent/ and this patch from the pull request -> Haru already put code:ready tag but haven't merge yet ... http://upaste.me/45d422146a7e9357b Quote Share this post Link to post Share on other sites
0 classy5 0 Posted December 2, 2015 (edited) seems like you are able to follow the process just didn't recompile with the plugin you need this plugin http://herc.ws/board/topic/11296-onpcuseskillevent/ and this patch from the pull request -> Haru already put code:ready tag but haven't merge yet ... http://upaste.me/45d422146a7e9357b I actualy no experience on plugin or patch... im trying to figure out what i have to do with the info you provided i tried just creating a file name "hercules.h" after that "memmgr.h" then i get error when i start the server Edited December 4, 2015 by classy5 Quote Share this post Link to post Share on other sites
0 Kuya Jeo 120 Posted December 4, 2015 seems like you are able to follow the process just didn't recompile with the plugin you need this plugin http://herc.ws/board/topic/11296-onpcuseskillevent/ and this patch from the pull request -> Haru already put code:ready tag but haven't merge yet ... http://upaste.me/45d422146a7e9357b I actualy no experience on plugin or patch... im trying to figure out what i have to do with the info you provided i tried just creating a file name "hercules.h" after that "memmgr.h" then i get error when i start the server Just follow the Plugin Installation in Windows Don't forget to put it on conf/plugins.conf Quote Share this post Link to post Share on other sites
0 Dastgir 1246 Posted December 5, 2015 seems like you are able to follow the process just didn't recompile with the plugin you need this pluginhttp://herc.ws/board/topic/11296-onpcuseskillevent/ and this patch from the pull request -> Haru already put code:ready tag but haven't merge yet ...http://upaste.me/45d422146a7e9357b I actualy no experience on plugin or patch... im trying to figure out what i have to do with the info you provided i tried just creating a file name "hercules.h" after that "memmgr.h" then i get error when i start the server Update your Hercules, this plugin is meant for new Hercules. Quote Share this post Link to post Share on other sites
0 AnnieRuru 957 Posted December 5, 2015 I found that our plugin format keep changing, never consistent newer plugin cannot use on old hercules, and old plugin cannot use on new hercules hercules.h added on this commit, https://github.com/HerculesWS/Hercules/commit/51b7adcf4e5b2a347081ec9a6903102c4909a404 means ... if want to make that plugin compatible with your server, has to put all those GET_SYMBOL stuffs ... honestly without GET_SYMBOL is much better ... Quote Share this post Link to post Share on other sites
0 Dastgir 1246 Posted December 5, 2015 I found that our plugin format keep changing, never consistentnewer plugin cannot use on old hercules, and old plugin cannot use on new herculeshercules.h added on this commit,https://github.com/HerculesWS/Hercules/commit/51b7adcf4e5b2a347081ec9a6903102c4909a404means ... if want to make that plugin compatible with your server, has to put all those GET_SYMBOL stuffs ...honestly without GET_SYMBOL is much better ...Plugin format is much better now, it used to keep changing to remove all the limitations like that of GET_SYMBOL. @@classy5 also if you want to make plugin for old hercules, you need to change #include directory too Example: #include "map/map.h" To #include "../map/map.h" And so on, with other includes too. Quote Share this post Link to post Share on other sites
Item use to -> target(Player&Monster)
teleport the target to prontera (if possible please include that the target will be teleported back to where he was after 30 sec)
[herc staff]: can u please move this to script request? thanks
Edited by classy5Share this post
Link to post
Share on other sites