but i been having small problems,
last night i coded few stuff which i tested didnt work proper, then thx to sedat we fixed few stuff.
now there is this 1 thing i am stuck not sure what will it be and any kind of help will be nice.
so first here is the questtable.cs
Code:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Rise_Of_Medusa.Game;
using SubSonic;
namespace Rise_Of_Medusa.Database
{
public class QuestTable
{
public static void ResetQuests(Game.Entity client)
{
MySqlCommand Do = new MySqlCommand(MySqlCommandType.UPDATE);
Do.Update("quest").Set("StoneFindingQuest", 0).Where("EntityName", client.Name).Execute();
}
public static void FinishQuest(Game.Entity client)
{
MySqlCommand Do = new MySqlCommand(MySqlCommandType.UPDATE);
Do.Update("quest").Set("StoneFindingQuest", 1).Where("EntityName", client.Name).Execute();
}
}
}
program.cs
Code:
#region Quest Reset
if (DateTime.Now.Hour == 03 && DateTime.Now.Minute >= 00)
{
Database.QuestTable.ResetQuests(client.Entity);
}
#endregion
here is the last part of the npc
Code:
case 2:
{
if (client.Inventory.Contains(729306, 1))
{
client.Inventory.DeleteItem(729306, 1);
Database.QuestTable.FinishQuest(client.Entity);
client.Entity.Money += 10000000;
dialog.Text("Nice you did it.");
}
}
break;

but somehow when the quest is done its not saving the 1, its not sending anything to the database. any help will be grateful.
#request close
problem solve






