Jump to content

GmOcean

Community Contributors
  • Content Count

    371
  • Joined

  • Last visited

  • Days Won

    8

Everything posted by GmOcean

  1. What you need to do is make sure they are online such as this: .@na = query_sql("SELECT `char_id`,`online` FROM `char`", .@c_id,.@online);.@nb = query_sql("SELECT `char_id` FROM `char_reg_num_db` WHERE `key`='hunter' && `value`='1'", .@char_id ); for( .@i = 0; .@i < .@nb; .@i++ ) { //Loops through second sql_query for( .@a = 0; .@a < .@na; .@a++ ) { //Loops through first sql_query if (.@c_id[.@a] == .@char_id[.@i] && .@online[.@a]) { //Compares Character IDs, and then checks if player is online. // If player is online, then we send the information out. Else, it should skip ahead to the next player who is online. dispbottom "(From Hunter Academy) : "+strcharinfo(0)+" just got online.",0xFFFF00,.@char_id[.@i]; } } } Granted there is a cleaner way to do this using a better sql_query, and/or using the command " while() " instead of " for() ". However, both should get the job done, and depending on the player base, the amount of resources saved is minimal at best. Edit: Haven't tested, but based on scripts I've written in the past this should work, barring any syntax errors.
  2. You are putting this label in the same NPC that's in the instance right?
  3. Uhh, something like Traveling to Pay_fild10 finding a Hunter NPC there, and talking to him. (Unless this is the old Falcon Quest, been a looong time since iRO days :/)
  4. soooo..... a Homunculus. Edit: But in all seriousness, you should probably look for a modification on this: http://herc.ws/board/topic/7076-monster-loyalty-mod/ Or something similar in general. The only issue with how it is currently is that, if 2 people are loyal to the monster, and 1 of them dies to the other, than the summoned monster won't attack either. This can be solved somewhat easily without a modification to that src-mod (does that make sense?). Just create a few extra monsters that will only be used for this particular script. For instance, create 10 extra Atroce's that will only be summoned when a player dies. Modify it so that it doesnt have any items to drop, maybe stats as well. Then make your script so that the monster only lives for 1min or something, and is only loyal to that player who died. Then remove the loyalty. So, i dunno, it's something.
  5. - script test1235678 -1,{end;OnInit: bindatcmd "flooritem", strnpcinfo(0)+"::OnFI", 60,90; ; end;OnFI: .@hditemid = atoi(.@atcmd_parameters$[0]); .@damount = atoi(.@atcmd_parameters$[1]); if ( !.@damount ) { message strcharinfo(0), "@flooritem <Itemid or itemname> <amount>"; end; } if ( .@damount < 0 ) { message strcharinfo(0), "@flooritem -> Invalid amount"; end; } if ( getitemname(.@hditemid) == "null" && !searchitem(.@temp[0],.@atcmd_parameters$[0]) ) { message strcharinfo(0), "@alootnoitem -> Invalid Item ID"; end; } if(.@temp[0]) .@dropitemid = .@temp[0]; else .@dropitemid = .@hditemid; .@r = (sqrt(.@damount) > 16 ? 16 :sqrt(.@damount)); getmapxy(.@m$,.@px,.@py,0); .@min_x =((.@px-.@r) < 1?1:(.@px-.@r)); .@max_x =((.@px+.@r) > 512 ? 512:(.@px+.@r)); .@min_y =((.@py-.@r) < 1?1:(.@py-.@r)); .@max_y =((.@py+.@r) > 512 ? 512:(.@py+.@r)); freeloop(1); for(.@j=0;.@j< .@damount;.@j++) { while (checkcell(.@m$[.@i],.@px=rand(.@min_x, .@max_x),.@py=rand(.@min_y , .@max_y), cell_chknopass)); makeitem .@dropitemid,1,.@m$,.@px,.@py; } freeloop(0); end;} Just copy that, save it to a new text document. Then add it to your server like you would any other NPC. That's all this is. An invisible NPC script, which will give you a command. You should know how to add NPC's to your server already.
  6. It is not a src edit, it's a script, that mimics making a new command. Install it like any other script, and it will let you use the command @flooritem it will also not require a recompile, just either use @reloadscript ingame, or just restart the server after installing it. But this does require using Hercules Emulator
  7. Seems to be the same request as this: http://herc.ws/board/topic/6924-request-plugin-flooritem/
  8. The issue is this right here: while (checkcell(.dm$[.@i],.@dx=rand(.@min_x, .@max_x),.@dy=rand(.@min_y , .@max_y), cell_chknopass)); change to this: while (checkcell(.@m$[.@i],.@px=rand(.@min_x, .@max_x),.@py=rand(.@min_y , .@max_y), cell_chknopass)); it was checking for a map using a variable that contained no data.
  9. I agree with Mysterious on this one, you'll need to test ingame to see if @summon will have the monster attack when you die ( @[member=]clone. SHOULD have them still attack ). But this is another reason why we need those mob controll commands D: Edit: Abusing forum code manipulation to make @[member=]clone appear as it should >.>
  10. Explain more please. All I can gather from this is that it's a script for Mid-Headgear, and something to do with Piercing ( Pierce Armor? Magic Resist? ).
  11. I don't have any of my RO files anymore, since I recently wiped my work station. Unlucky me got hit with a currupt drive :/ @inventorylist_bound will tell you exactly which bound type it is. It will return the values: 0 - (Not bound) 1 - (Account Bound) 2 - (Guild Bound) 3 - (Party Bound) 4 - (Character Bound) The same goes for *getcartinventorylist and @cartinventorylist_bound
  12. @@Lord Ganja - *getinventorylist;This command sets a bunch of arrays with a complete list of whatever the invoking character has in its inventory, including all the data needed to recreate these items perfectly if they are destroyed. Here's what you get:@inventorylist_id[] - array of item ids.@inventorylist_amount[] - their corresponding item amounts.@inventorylist_equip[] - will return the slot the item is equipped on, if at all.@inventorylist_refine[] - for how much it is refined.@inventorylist_identify[] - whether it is identified.@inventorylist_attribute[] - whether it is broken.@inventorylist_card1[] - These four arrays contain card data for the@inventorylist_card2[] items. These data slots are also used to store@inventorylist_card3[] names inscribed on the items, so you can@inventorylist_card4[] explicitly check if the character owns an item made by a specific craftsman.@inventorylist_expire[] - expire time (Unix time stamp). 0 means never expires.@inventorylist_bound - whether it is an account bounded item or not.@inventorylist_count - the number of items in these lists.This could be handy to save/restore a character's inventory, since no other command returns such a complete set of data, and could also be theonly way to correctly handle an NPC trader for carded and named items who could resell them - since NPC objects cannot own items, so they have to store item data in variables and recreate the items.Notice that the variables this command generates are all temporary, attached to the character, and integer.Be sure to use @inventorylist_count to go through these arrays, and not 'getarraysize', because the arrays are not automatically cleared between runs of 'getinventorylist'. This returns @inventory_expire which gives you the rental time, if it has data ( not a 0 ) then it's a rental item. You can even see how long until it expires. Additionally, @inventory_bound SHOULD return the type of bound item it is (account, character, party, guild) or 0 if it's not bound at all. The reason I say SHOULD is because, I remember submitting an update to the command that would return the value of the bound type, rather than just return 1 (saying it's bound) and 0 (saying it's not bound), this way you should get all the information needed. But lastly, I also created this command awhile back to check specifically for bound items, if theres a need for it. *checkbound(<item_id>{,<bound_type>{,<refine>{,<attribute>{,<card_1>{,<card_2>{,<card_3>{,<card_4>}}}}}}});This command allows you to check whether or not the attached player has the specified bound item in their inventory.If a bound type is not specified or a bound type of 0 is used, it will search the player's inventory for a bound itemof any type, so long as the other parameters match. In all cases, this command will return the bound type of theitem found, or 0 if the specified item was not found.Valid bound types are: 0 - All Bound types. 1 - Account Bound 2 - Guild Bound 3 - Party Bound 4 - Character BoundOptional Parameters: bound_type - checks to see if the item has the specified bound type. refine - checks to see if the item is refined to the given number. attribute - whether the item is broken (1) or not (0). card 1,2,3,4 - checks to see if the specified cards are compounded on the item as well.Example: // This will check if you have a bound (any type) 1205 (Cutter). if (checkbound(1205)) { mes "You have a bound Cutter"; } else { mes "You do not have a bound Cutter"; } close; // This will also check if you have a bound (any type) 1205 (Cutter). if (checkbound(1205,0)) { mes "You have a bound Cutter"; } else { mes "You do not have a bound Cutter"; } close; // This will check if the player doesn't have a bound 1205 (Cutter). if (!checkbound(1205)) { mes "You do not have a bound Cutter"; } else { mes "You do have a bound Cutter"; } close; // This will check if the item found, has a bound type of 2 (guild_bound) if (checkbound(1205) == 2) { mes "You have a guild_bound Cutter"; } else { mes "You do not have a guild_bound Cutter."; } close; // This will check if you have a 'guild_bound' +7 1205 (Cutter). if (checkbound(1205, 2, 7)) { mes "You have a +7 guild_bound Cutter."; } else { mes "You don't have the required item."; } close; Best of luck.
  13. Judging by that, the arrow just spins around. With my cutin the items spin around. But meh, I'm not making the script so either way pick which ever works for you guys.
  14. Well, the reason I asked for a list of items is for the pictures themselves. Editing bmp's aren't that much of an issue for most people but meh, we'll see. Edit: @@Dastgir - Well, here's the cutin files I made. 24 bmps, I also included the PSD file for w/e reason. I was going to make more, but then I realized you could just loop through them over again to make it run longer. Spinwheel Cutin
  15. O.o lol, this is like my slot machine script... I'll try and see if I can make some cutins for it. The current image has 24 items. Sadly, I lost all my server files, so I wont be writing a script for it. So, i'll try and make it about ~12-16 items displayed. Edit: Almost forgot, I kinda need the list of items that are winable. Or, it'll just be a spinning wheel with an arrow xD Going for 24 items. If not, I'll just throw in my own set of items. Some pots, OBB, the usual freebie stuff.
  16. Probably already checked but, is this server live? You need to make sure your host has PERL installed. I've noticed a few people have been checking their local comps/work stations but the host doesn't have it. So as a precaution try checking with them to see if they have support for it. Edit: I forgot to mention that due to clients updating and certain langtype's being used in clientinfo.xml, you may just have an issue of 'password' recognition so to speak. Simply try adding a (Space) before your answers. This is a common issue with langtype's 1, 20 and 21 from what i've seen. e.g: poring = Server may not see as correct poring = Server may regonize this one though. If this is the case for you, and adding a space before your answer makes it work, try changing server langtype to 0. This will affect how the client produces text. Lastly if that still doesn't work, there are multiple posts here that have had this very same issue and have solved it by changing the script's PERL speech pattern. I can't remember how to do it as it has been a few years. Sorry I couldn't be of much more help. Good luck.
  17. She meant to place .test as arg(0), which would make it pass the info from .test. But if I'm not mistaken, only .test[0]. If you REALLY need to copy an array over to a function for w/e reason, turn it into a temp global array $@test. You can also use setd/getd to dynamically create these names so they are unique each time you make them, so they don't overlap with one another and cause errors.
  18. I 100% agree, this is defintely something we should have. Especially if it's going to be needed in the future.
  19. My question is how is your Queue system being run, src or via script? If it's through script, a smart algorithm for a queue system to seperate dps,tank, and support isn't too hard. Simply storing classes into an array and expanding the query to search through upto ~50 players will make it easier. I've done a similar system for a dungeon queue. I made it so player's who joined the queue selected their intended role, ofcourse you couldn't select DPS if you were a priest, so it prevented people from claiming a role they can't effectively do. Also this wouldn't affect a premade party. So mainly for those who solo que. Lastly you give priority to certain roles over others, if you don't have the others available. I used this small rule of guidance. Tank>Support>DPS this is because DPS classes are in abundance in RO, since most people play those. Ratio I go for is, 1 tank, 1 support, 3 dps. Then cycle over. Obviously this can all be adjusted for how large parties are intended to be. But this should suffice for a 10v10, 2 Tanks, 2 Supports, and 6 DPS. Edit; @Below - Sorry lol, I didn't mean it that way. I'm very sure you could do it easily. This was just my suggestion on how it could be done, if you lacked ideas.
  20. Right now it's checking for BaseClass. That will always return a 1-1 Class unless they have not become any of those classes. In which case it returns Job_Novice. BaseClass - The character's 1-1 'normal' job, regardless of Upper value. For example, this will return Job_Acolyte for Acolyte, Priest/Monk, High Priest/Champion, and Arch Bishop/Sura. If the character has not reached a 1-1 class, it will return Job_Novice. You'll need to check for each class using Class. { if(Class==Job_Hunter || Class==Job_Sniper) {bonus3 bAutoSpell,SN_SHARPSHOOTING,5,50;} } (Can't remember if you can do this with Upper or not).
  21. Popping in every now and then.

  22. OnInit: .Length = 28; //EDIT THE LENGTH OF CHARACTERS TO BE TYPED .Round = 5; //EDIT THE ROUNDS setarray .List$,";","B","_","D","E","%","=","H","I","J","/","L","M","N","6","P","Q","]","S","T",","; //YOU CAN ADD LETTERS, DIGITS & SYMBOLS HERE.. end; You make it so the script sets the rounds to 5 at the begining of server launch. Then, when the announcements starts, it announces it +1. Simply delete that line or set it to 0 and it'll be fine. OnInit: .Length = 28; //EDIT THE LENGTH OF CHARACTERS TO BE TYPED setarray .List$,";","B","_","D","E","%","=","H","I","J","/","L","M","N","6","P","Q","]","S","T",","; //YOU CAN ADD LETTERS, DIGITS & SYMBOLS HERE.. end;
  23. Sweet mother of god! This, just made things sooo much better. Now I can rewrite sooo many scripts that rely on hard-coded duplicates, and just soft-duplicate them when needed and then remove. Efficiency + Over 100% less resource consumption since they don't all need to be active at once anymore. Thanks, Dastgir. Though it sucks school started for me... not much time to play with it T.T; Edit: Just 1 question. The duplicateremove command. Does it work in such that, it can remove just 1 duplicate or all if so chosen? Because, I had originally hoped that, we'd be able to remove 1 specific duplicate and/or all of them, by specifying either a DuplicateNPC's name, or the Source NPC name. (Sorry, don't actually have time to play around with it @work/@school).
  24. In order for a skill to equip an item, it must be in their inventory. You could have the skill create the item, and then equip it. But regardless of the choice, it must be in the inventory.
  25. Glad it worked. And again sorry, this is a client x server limitation, that can't be fixed. Unless theoretically we can detect what langtype a client is using, and then we could write the script to make proper adjustments for individual players. However, that's all speculation.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.