A Project for Chronicle 4 based on L2JServer.


    Item restrictions on specific areas

    Share

    G-hamsteR

    Posts : 60
    Join date : 2013-04-26

    Item restrictions on specific areas

    Post  G-hamsteR on 30th May 2013, 22:08

    Hello,

    I would like to add item restrictions like Olympiads, but in some other locations. When players enter this location, all S grade weapons for example would be removed and they could not use them inside this area.

    Does anyone have any suggestions?

    Thank you for your time!
    avatar
    DnR
    Admin
    Admin

    Posts : 1027
    Join date : 2012-12-03

    Re: Item restrictions on specific areas

    Post  DnR on 9th June 2013, 14:53

    Here is one way to do this.

    A new zone type in core should do, L2NoGradeSZone for instance. Add zone in datapack, too (zones.xml, zone_vertices.sql). In this zonetype, you should add a check for S grade weapons in onEnter() method so as to be unequipped. Also, a check in useItem client packet should prevent players from equipping items when they are inside this zone. Such features are usually buggy though, and need more and more checks.
    For example, if player is inside zone, but close to exit, another player outside zone with S gear and long ranged attacks could kill him without entering zone.
    So, u also need a related protection.

    I know i didn' t help much, but this is an example of how you could do it.

    G-hamsteR

    Posts : 60
    Join date : 2013-04-26

    Re: Item restrictions on specific areas

    Post  G-hamsteR on 9th June 2013, 17:53

    Thank you very muc for your reply. I have found another topic in l2jserver. http://www.l2jserver.com/forum/viewtopic.php?f=81&t=17909&start=0#p94629

    I think I can adapt it, but if possible I need to know where to add this code, and which files to check to see how items are unequiped in Olympiads. After these, I can adapt them Smile

    I apologise for asking so many questions. Once again, thank you for your time!

    Sponsored content

    Re: Item restrictions on specific areas

    Post  Sponsored content


      Current date/time is 19th November 2017, 18:15