We moved our repositories to BitBucket!

If you can't login or you can't register to the forums do not rise an issue, instead please write to support (at) l2jserver.com

Check our wiki!

Report server issues here

Forum has been updated to phpBB 3.2, let's see if this fixes some minor bugs we had.

Thank you for visiting http://www.l2jserver.com/

[FIXED]Daily World Chat Point

Move here solved/invalid bug reports.
Please add manual tag [INVALID] to invalid reports, until we add new tag system, thanks.
Post Reply
Yunaleska
Posts: 17
Joined: Fri Jul 22, 2011 4:00 pm

[FIXED]Daily World Chat Point

Post by Yunaleska » Sat Jan 31, 2015 2:47 pm

Hello, one little problem on TaskDailyWorldChatPointReset.java

Server logs:
[31/01 06:30:00] Daily skill reuse cleaned.
[31/01 06:30:00] TaskDailyWorldChatPointReset: Could not reset daily world chat points: java.sql.SQLException: No value specified for parameter 2
[31/01 06:30:00] Daily world chat points has been resetted.
[31/01 06:30:00] Recommendations System reseted

Code: Select all

	@Override
	public void onTimeElapsed(ExecutedTask task)
	{
		// Update data for offline players.
		try (Connection con = L2DatabaseFactory.getInstance().getConnection();
			PreparedStatement ps = con.prepareStatement("UPDATE character_variables SET val = ? WHERE var = ?"))
		{
			ps.setInt(1, Config.WORLD_CHAT_POINTS_PER_DAY);
			ps.setString(1, L2PcInstance.WORLD_CHAT_VARIABLE_NAME); // THAT 1 must be 2
			ps.executeUpdate();
		}

Code: Select all

	@Override
	public void onTimeElapsed(ExecutedTask task)
	{
		// Update data for offline players.
		try (Connection con = L2DatabaseFactory.getInstance().getConnection();
			PreparedStatement ps = con.prepareStatement("UPDATE character_variables SET val = ? WHERE var = ?"))
		{
			ps.setInt(1, Config.WORLD_CHAT_POINTS_PER_DAY);
			ps.setString(2, L2PcInstance.WORLD_CHAT_VARIABLE_NAME);
			ps.executeUpdate();
		}

User avatar
St3eT
Posts: 961
Joined: Sun Mar 07, 2010 6:50 pm

Re: Daily World Chat Point

Post by St3eT » Sat Jan 31, 2015 3:54 pm

Look's correct, make Pull Request.
If i should be black sheep for sure no as punishment
Image

Yunaleska
Posts: 17
Joined: Fri Jul 22, 2011 4:00 pm

Re: Daily World Chat Point

Post by Yunaleska » Sat Jan 31, 2015 3:59 pm

Ok

it will be done tomorrow (AFK today :lol: )

User avatar
Sdw
L2j Veteran
L2j Veteran
Posts: 855
Joined: Mon May 03, 2010 8:38 am
Location: France

Re: Daily World Chat Point

Post by Sdw » Tue Feb 03, 2015 11:50 am

Sorry that one was pissing me off, couldn't wait :D

Fixed in [commit]6b1466d29f608a4e58259b76f713422fb04d8bad[/commit] thanks !

Post Reply