Page 1 of 1

Mob drops

Posted: 13 Oct 2004, 20:07
by Mav
Allez les gars, on bosse sur les Drop svp...

Vla un debut :

Code: Select all

using System;
using DOL.GS ;
using DOL.Events ;
using DOL.Database ;
using DOL.Database.Attributes;

namespace DOL.Database
{
	/// <summary>
	/// Database Storage of Tasks
	/// </summary>
	[DataTable(TableName="MobDrops")]
	public class MobDrops : DataObject
	{
		protected string	m_MobName = "";
		protected string	m_ItemID = "";
		protected int m_Chance = 99;
		static bool			m_autoSave;

		static bool m_init ;
		
		public MobDrops()
		{
			m_autoSave = false;
		}

		override public bool AutoSave
		{
			get	{return m_autoSave;}
			set	{m_autoSave = value;}
		}
		
		[DataElement(AllowDbNull=false)]
		public string MobName
		{
			get {return m_MobName;}
			set	
			{
				Dirty = true;
				m_MobName = value;
			}
		}

		[DataElement(AllowDbNull=false)]
		public string ItemID
		{
			get {return m_ItemID;}
			set	
			{
				Dirty = true;
				m_ItemID = value;
			}
		}

		[DataElement(AllowDbNull=false)]
		public int Chance
		{
			get {return m_Chance;}
			set	
			{
				Dirty = true;
				m_Chance = value;
			}
		}

		[ScriptLoadedEvent]
		public static void OnScriptCompiled(DOLEvent e, object sender, EventArgs args)
		{
			if ( !m_init && (GameServer.Database != null) )
			{
				GameServer.Database.RegisterDataObject ( typeof ( MobDrops ) ) ;
				GameServer.Database.LoadDatabaseTable ( typeof ( MobDrops ) ) ;
				m_init = true ;
			}
		}
		[ScriptUnloadedEvent]
		public static void OnScriptUnloaded(DOLEvent e, object sender, EventArgs args)
		{
		

:D

Posted: 13 Oct 2004, 20:08
by Mysterius
j'avais pour projet d'aller manger mais finalement j'ai l'impression d'avoir trop bouffé :?

Posted: 13 Oct 2004, 20:11
by Sarek
LOOOL ca ou rien c'etait pareil Mav, c'est un bout de code qui montre pas grand chose :lol:

Par contre GG a DOL, ils avancent vraiment bien ;)

Posted: 13 Oct 2004, 20:15
by Dre
http://www.doldata.fleetingclarity.com/ ... .php?t=283

Il y a tout au moin, mais je sais pas si ca marche j'ai pas testé :roll: ...

Posted: 13 Oct 2004, 21:01
by Phoenx
Drop objets communs ? drop d'objets spéciaux sur named ?

P.S : gg pour le taff encore.

Posted: 13 Oct 2004, 21:04
by Sarek
Phoenx wrote:Drop objets communs ? drop d'objets spéciaux sur named ?

P.S : gg pour le taff encore.
Phoenx arrete la folie des grandeur :lol:

Laisse le temps venir et surtout commençons par le debut ^^

Posted: 13 Oct 2004, 21:40
by Sp4M
Lol .. c'est raiment pas la priorité, en effet.