Jump to content
  • 0

Hero method for 2 weeks npc


Question

Posted

HI all, i set in my npc to make character hero. In next settings you will see. But, i want to set hero for 1 month. Now, if player buy hero, after restart, hero it's gone.
Here it is few setting.
 

else if (event.equalsIgnoreCase("hero"))
		{
			if (!player.isHero())
			{
				player.setHero(true);
				player.broadcastPacket(new SocialAction(player.getObjectId(), 20016)); // Hero Animation
				player.broadcastUserInfo();
				player.destroyItemByItemId("Get your hero!", 6391, 25000, player, true);
				return "character.htm";
			}
			else if (player.isHero())
			{
				player.setHero(false);
				player.broadcastUserInfo();
				return "character.htm";
			}
		}

How i can set a "period" ? I check olympiad method. But those settings are much and i don't understand nothing.
Greetings

7 answers to this question

Recommended Posts

  • 0
Posted

Agree. Thats a big system. You can make it very simple with a long type variable that check upon login if current Milliseconds is smaller than the variable to set hero and upon log out to store but thats an amateur way.

 

You better pay a dev or learn to make something good do not make amateur systems for servers with 2 lines of code just to have em

  • 0
Posted

And who can do this? I will pay it

I was scammed by EdithFinch
Anyone can come to fix this please? Not big deal. This guy make an incomplete code. I request a npc which gave hero for 1 day and second time to make a coin (handler) to give hero for 30 days. Coin and Npc take just required items and don't give Hero Status. Also i get time for this. Thank you!

Guest
This topic is now closed to further replies.


×
×
  • Create New...