Jump to content
  • 0

Custom Pvp Scroll


Question

Posted (edited)

Hi all, Im looking for a mod...a custom scroll that every player have in the inventory at the char creation, which is not consumed or droppable or destroyable.

basically, the idea is that when the player double-click on it, it teleports the player where the pvp is going ON at the moment, so basically where purple players are.

 

now, the idea can be improved by adding some checks, like...minimum players being purple, so if there is a 1vs1 isnt worth the teleport.

and some protections also, not usable in siege, oly, instances, events, being purple at the moment of the use, etc.

 

thanks for your attention.

Edited by A-Style

9 answers to this question

Recommended Posts

  • 0
Posted (edited)

This is not a request section.

If you have any java knowledge and want us to help you to figure out how to do it, or to help you in some aspects, you're welcome. If you come requesting someone to code for you, you're not welcome here, go to MarketPlace.

Edited by ^Wyatt
  • 0
Guest Elfocrash
Posted

tell me how much this work is worth. thanks.

It worths nothing. It is fairly easy to do in in like one itemhandler.

You actually set a every single flagged player as a setting point and you keep looping around flagged players until you find one that has at least X flagged players in his radius and that's it. Get his loc and pos (x,y,z) and teleport there. Do not even think of paying about something so easy.

  • 0
Posted

It worths nothing. It is fairly easy to do in in like one itemhandler.

You actually set a every single flagged player as a setting point and you keep looping around flagged players until you find one that has at least X flagged players in his radius and that's it. Get his loc and pos (x,y,z) and teleport there. Do not even think of paying about something so easy.

Well it can worth money if the requestor has 0 knowledge and nobody code it for free.

 

//inside code

I'm not sure if it's a good idea to make a loop of all players and do the proper checks every time someone press the command, I guess it can generate lag. Probably a task should do it and then players when using the command should access to a static variable (?)

  • 0
Guest Elfocrash
Posted

//inside code

I'm not sure if it's a good idea to make a loop of all players and do the proper checks every time someone press the command, I guess it can generate lag. Probably a task should do it and then players when using the command should access to a static variable (?)

Mate what do you think you do when you use L2World.getInstance().getAllPlayers().values() ?

You loop arround all the players. Ofc what i said is the best idea. A task is not even close as good because pvp states change ever second.

Also saying that something like that might cuz lag is something  o never though i will hear from a developer of your calibre.

  • 0
Posted (edited)

About the item itself, almost anyone can make it.

 

About the itemhandler, if your PvP is contained in particular zones, it's far preferable to check zones players than world players (each zone stores such a list normally). Otherwise, if it's "free world" PvP, you have to do as Elfo suggests, but to avoid to make pointless checks, you have to :

  • store current player list in a new list.
  • loop the list, searching for pvpflag.
  • search in knownlist radius ppl, and DROP them from the list (iterator remove) after ++ a variable those who are in pvpflag state.
  • store in a map player name and number of pvpers (variable).
  • when the complete loop is done, search in the map the highest value, and teleport to the key, which is the player with highest number of pvpers around.

If you don't want to make it the highest but a random fight, it depends if :

  • a minimal amount of pvpflag is required (4 ppl min let's say), you have another cleanup to do.
  • no requirements : rnd.get the size of the map to get a random index.

If you don't do as I say, you will have pvp clones (3 ppl are fighting, 3 ppl will be registered as value "2"). It can be problematic if you got a "actual pvp counter" system. If you haven't such a counter, you can ignore the "remove iterator" part.

 

Finally the Map itself is required, because if multiple pvps got the same number of ppl, you will have to randomize it.

 

@Elfo the idea is easy to think, but harder to put in place if you think about things around ^^.

Edited by Tryskell
  • 0
Posted (edited)

Mate what do you think you do when you use L2World.getInstance().getAllPlayers().values() ?

You loop arround all the players. Ofc what i said is the best idea. A task is not even close as good because pvp states change ever second.

Also saying that something like that might cuz lag is something  o never though i will hear from a developer of your calibre.

I don't have such "calibre", keep dreaming biatch  :rage:

Then, I was wrong, I'll try to live with it  :happyforever:

Edited by ^Wyatt
  • 0
Guest Elfocrash
Posted (edited)

@Elfo the idea is easy to think, but harder to put in place if you think about things around ^^.

Ofc i did think of everything i just don't have your post patience to write everything :D

 

@Offtopic Sign for Hearthstone: Heroes of Warcraft. I need company on that strategy game!

Edited by Elfocrash

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...