msecastro
-
Content Count
14 -
Joined
-
Last visited
Posts posted by msecastro
-
-
-
Thank you for your reply, Dastgir.
So basically, I have to edit the map or something to add them?
-
-
BUMP
I tried rummaging through the files and can't seem to find the proper one to edit. Can someone point me in the right direction?
-
Good day, Hercules forums
I was playing around the different trader types and came around the NST_CUSTOM type.
I was able to create an NPC which trades items for TCG, however, I would like to ask a few things because my OCD is killing me:
- Is it possible to change the text on the dialogue box that pops up before purchasing (or totally disable that)?
- Is it possible to remove the "Free Cash" text and the "Use Free Cash" input box?
I attached a screenshot of what I mean.
EDIT: Somehow the file isn't uploading so here's the screenshot:
Screenshot: https://prnt.sc/hlwmpt
Thanks!
-
I also can't view the links.
-
Problem now fixed! Thanks to both Nova and Angelmelody! I owe you guys one!
-
Huh weird, let's tone that down then.
prontera,158,180,4 script MapCheck 4_F_CAPEGIRL,{mes getmapflag(strcharinfo(3),mf_zone);close;}
If that won't work, maybe
prontera,158,180,4 script MapCheck 4_F_CAPEGIRL,{dispbottom getmapflag(strcharinfo(3),mf_zone);end;}
Sorry for the late reply, I had some problems with the internet.
An empty textbox appears on the first snippet. I may have not set the mapflag correctly.
Now, I'm having this on the dispbottom:
[Error]: script:conv_str: cannot convert to string, defaulting to ""[Debug]: Data: nothing (nil)[Debug]: Source (NPC): MapCheck at prontera (158,180)
-
Haha I just went back to edit my post, sorry :]
Just to make sure, you've already set your custom map zones right? And they're loaded?
Haha, I just made something similar to what you've edited. Yes, I think so, I will be testing now and will get back to you in a few minutes for the results.
@@Nova - I'm quite new to this but I'm quite a fast learner so it isn't disrespectful on your part.
Getting back, while running and talking the NPC I've made with your snippet, I am having these messages on my map-server:
[Error]: script:op_2: invalid data for operator C_ADD[Debug]: Data: C_ARG[Debug]: Data: string value="Mapflag: "[Debug]: Source (NPC): MapCheck at prontera (154,176)
-
I'm not running Herc so I can't test for you, but check this line.
getmapflag(strcharinfo(3),mf_zone);
If it returns something higher than 1 we should be able to do this easily.
Obviously test it on a zone you've marked as your custom zone.
Thank you, Nova!
How would I go about this?
Do I just:
- script testgetmapflag -1,{OnPCLoadMapEvent:getmapflag(strcharinfo(3),mf_zone);}prontera mapflag loadevent
..or am I misunderstanding something?
Thank you for your patience.
-
I recommend you learn Map Zone DB ,its better than running a while loop
example, go to the bottom of map_zone_db.conf and add BEFORE the last ) the following:
,{ name: "Custom" disabled_skills: { SA_ABRACADABRA: "PLAYER" } mapflags: ( "noknockback", )}
now go to any npc script file and add this:
yourmapname<tab>mapflag<tab>zone<tab>Custom
Thank you for your reply, Angelmelody!
Yes, I am currently looking into Map Zone DB for a while now and have been making tests. I'm also looking at related scripts using it to have knowledge on how to use it on scripts.
-
Just make 3 custom items, an NPC that checks what your citizenship is, and gives you the appropriate "Citizen ID" item.
Each one of the items can be something like this:
100000,Rune-Midgard ID,Rune-Midgard ID,11,0,,0,,,,0,0xFFFFFFFF,63,2,,,,,,{ warp "prontera",150,180; },{},{}
Obviously change the item ID, Name, and script to fit whatever you want it to be.
If you need more help with this feel free to PM me tomorrow, I'm headed to bed.
Thank you for replying to my inquiry, Nova! I'm truly grateful!
I have already made an NPC and the respective items required prior to the creation of this thread and I apologize for not mentioning it. What I want to clear up is: Is it possible to use map zone db in this case? I have read through Hercules' Map Zone DB but I cannot seem to find anything related to warping someone out of a zone if they have specific items in their inventory - or maybe I am misunderstanding something.
I made a temporary restriction by doing this:
- script ItemRestriction#from_midgard -1,{ OnPCLoadMapEvent: while ( strcharinfo(3) == "yuno" || strcharinfo(3) == "rachel" ) { if ( countitem(30200) ) { mes "[Citizenship Checker]"; mes "Halt, Stranger!"; next; mes "[Citizenship Checker]"; mes "Through checking you ID card, you are a citizen of the Rune-Midgard Kingdom! You are not allowed to enter!"; next; mes "[Citizenship Checker]"; mes "I will be teleporting you back to your capital city."; next; warp "SavePoint", 0, 0; end; } sleep2 1000; } end;}- script ItemRestriction#from_arunafeltz -1,{ OnPCLoadMapEvent: while ( strcharinfo(3) == "prontera" || strcharinfo(3) == "rachel" ) { if ( countitem(30201) ) { mes "[Citizenship Checker]"; mes "Halt, Stranger!"; next; mes "[Citizenship Checker]"; mes "Through checking you ID card, you are a citizen of the Arunafeltz States! You are not allowed to enter!"; next; mes "[Citizenship Checker]"; mes "I will be teleporting you back to your capital city."; next; warp "SavePoint", 0, 0; end; } sleep2 1000; } end;}- script ItemRestriction#from_schwartzvald -1,{ OnPCLoadMapEvent: while ( strcharinfo(3) == "prontera" || strcharinfo(3) == "yuno" ) { if ( countitem(30202) ) { mes "[Citizenship Checker]"; mes "Halt, Stranger!"; next; mes "[Citizenship Checker]"; mes "Through checking you ID card, you are a citizen of the Republic of Schwartzvald! You are not allowed to enter!"; next; mes "[Citizenship Checker]"; mes "I will be teleporting you back to your capital city."; next; warp "SavePoint", 0, 0; end; } sleep2 1000; } end;}prontera mapflag loadeventyuno mapflag loadeventrachel mapflag loadevent
..but it feels so memory intensive so I'm quite looking for alternatives.
-
Good day, Hercules Community!
I just switched from using rAthena to Hercules and I'm perfectly happy and satisfied with the switch! Good job on the project and more power to you guys!
I do have one question though:
I'm particularly new to scripting and have made my own scripts one way or another, but I have yet to learn about some more advanced scripting commands. I am currently developing an RP server where players can choose their citizenship (Rune-Midgard Kingdom, Republic of Schwartzvald, Arunafeltz States, etc..). Once they create a character and choose their country, they will be given an ID to prove their citizenship and then warp to its specific capital city/town. For instance, I've chosen to be part of the Rune-Midgard Kingdom, I will be given a Midgard ID Card and teleported to its capital city, Prontera. When I try to access a different country via warper or simply travelling all the way from Prontera to Yuno, I wil be warped out and sent back to my savepoint (Prontera). Is there any way to do this?
I tried looking into Hercules' Map Zone DB but I still cannot fully grasp it, but I feel that it has to be done here.
If anyone can extend their help, it would truly appreciated until I go over to the next life! More power to you guys!
Best regards,
msecastro
Client Crashes on Certain Maps
in Client-Side Support
Posted
Good day, Herc Community!
It has been a while since I had a server running so I'm quite not new to this. I have gotten an offline server running on a kRO 2018-08-13 Client and a 20180621 exe. All seems working fine but certain maps such as "prt_in", "alberta_in", and some izlude maps crashes my client. I have downloaded the old prontera maps which includes "prt_in", the church, and the old prontera - placed them inside my grf - and have already compiled mapcache and ran mapcache to rebuild these maps, however, I still crash.
Can anyone point me into the right direction or tell me if I am still missing something?