Jump to content
  • 0

Question

4 answers to this question

Recommended Posts

  • 0
Posted
		if(_activeChar.isInOlympiadMode())
	{
		final String POINTS = "olympiad_points";
		final int charId = _activeChar.getObjectId();

		OlympiadGame game = Olympiad.getInstance().getOlympiadGames().get(_activeChar.getOlympiadGameId())

		L2PcInstance _opponent = L2World.getInstance().getPlayer(_activeChar.getOlympiadOpponentId());

		final StatsSet playerStat = Olympiad.getNobleStats(charId);
		final int playerPoints = playerStat.getInteger(POINTS);
		final int lostPoints = playerPoints / 3;

		playerStat.set(POINTS, playerPoints - lostPoints);
		Olympiad.updateNobleStats(charId, playerStat);
		SystemMessage sm = new SystemMessage(SystemMessageId.C1_HAS_LOST_S2_OLYMPIAD_POINTS);
		sm.addString(_activeChar.getName());
		sm.addNumber(lostPoints);
		_opponent.sendPacket(sm);
	}

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