Jump to content
  • 0

Vote Reward System(How To)


Question

Posted

Hi again,

 

I would like to make a vote reward npc. I found this code hre http://www.maxcheaters.com/topic/130368-hopzone-topzone-vote-reward-system/?hl=hopzonebut I do not know what to do with it. There too many codes on the forum, but I don't know how to use them and where to put them. Anyone care to help?

 

THanks a lot in advance!

Btw I use gracia final client!

4 answers to this question

Recommended Posts

  • 0
Posted

Hello,

I believe there should be a guide about adapting or patching code(I don't even know how it's called)

But I am gonnna try to help You a bit.

For example,this is a HopZone code from your linked thread: http://pastebin.com/ybQ6qkqR

There is a line like this: public class VoteRewardHopzone

It tells the name of your file (VoteRewardHopzone.java)

This one: package net.sf.l2j.gameserver.model.entity;

Tells the location of your file (net.sf.l2j.gameserver.model.entity)

I recommend You to use some IDE(Eclipse or NetBeans)

so if you are using some IDE just create a class called : VoteRewardHopzone at net.sf.l2j.gameserver.model.entity

Then just copy paste code from there: http://pastebin.com/ybQ6qkqR

Of course as this code is old and java has change quite a lot You will need a lot of adaption,plus this code was written for Interlude and You are using other chronicle

So either way You have to learn some Java.

In your linked thread anarchy just gives the files' names and doesn't tell at what lines that code should be added,so You will have to know it yourself.

Usually there is something like this:

Index: java/net/sf/l2j/custom/VoteRewardTopzone.java

===================================================================

--- java/net/sf/l2j/custom/VoteRewardTopzone.java (revision 0)

+++ java/net/sf/l2j/custom/VoteRewardTopzone.java (revision 0)

@@ -0,0 +1,314 @@

It tells you that you should add the code in VoteRewardTopzone code starting line - 0.

Anyways,I hope you understood at least something...

  • 0
Posted

do you have source of your server? :) also eclipse on your computer or workspace ( there where you make your works about core side ) ?

if yes, then say us what kind of project are you using

  • 0

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...