Skip to content

Commit

Permalink
Update README, revert version bump
Browse files Browse the repository at this point in the history
- Updated Readme with instructions
- Revert version bump
- Added seperate emulator Trinity 3.3.5a 2019 (not functional yet)
  • Loading branch information
Nadromar committed Jan 20, 2019
1 parent 2c123b9 commit 7728492
Show file tree
Hide file tree
Showing 9 changed files with 148 additions and 97 deletions.
11 changes: 7 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,18 +3,21 @@ This tool allows you to easily create items, creatures and quests for WoW emulat
Trinity Creator can be used by beginners to learn emulator server customization and by experts who just want to do it easier and faster.

### Getting started ###
* [Download Latest Version](https://github.com/Nadromar/TrinityCreator/blob/master/TrinityCreatorSetup/bin/Release/TrinityCreatorSetup.msi?raw=true)
* [Download & install the latest version](https://github.com/Nadromar/TrinityCreator/blob/master/TrinityCreatorSetup/bin/Release/TrinityCreatorSetup.msi?raw=true)
* Use the top menu to select your emulator
* Enter your database info & DBC directory (optional, adds extra features)
* Start creating!
NOTE: You need to reload tables or restart your server before you can see your new creation.

### Supported emulators ###
* TrinityCore WotLK 3.3.5a
* CMangos WotLK 3.3.5a
* TrinityCore WotLK 3.3.5a (full, TDB 335.64 & latest version (2019-01-17))
* CMangos WotLK 3.3.5a (full, 2016 DB)
* AzerothCore 3.3.5a (Items, quests & creatures)
* CMangos Zero 1.12 (Items, quests & creatures)

### Requirements ###
* Windows 10 (has all requirements pre-installed)
* Windows 7 (Install [.NET Framework 4.5](https://www.microsoft.com/en-us/download/details.aspx?id=30653) and use the [Windows 7 version of TrinityCreator](https://github.com/Nadromar/TrinityCreator/blob/no-modelviewer/TrinityCreatorSetup/bin/Release/TrinityCreatorSetup.msi))
* Windows 7 (Install [.NET Framework 4.5.2](https://www.microsoft.com/en-us/download/details.aspx?id=42642) and may need the [Windows 7 version of TrinityCreator](https://github.com/Nadromar/TrinityCreator/blob/no-modelviewer/TrinityCreatorSetup/bin/Release/TrinityCreatorSetup.msi))

### Development ###
Please report any bugs and suggestions on GitHub.
4 changes: 2 additions & 2 deletions TrinityCreator/App.config
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,13 @@
<value>True</value>
</setting>
<setting name="worldDb" serializeAs="String">
<value/>
<value />
</setting>
<setting name="emulator" serializeAs="String">
<value>0</value>
</setting>
<setting name="DbcDir" serializeAs="String">
<value/>
<value />
</setting>
<setting name="lookupToolWidth" serializeAs="String">
<value>400</value>
Expand Down
5 changes: 4 additions & 1 deletion TrinityCreator/Emulator/EmulatorHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -27,14 +27,17 @@ private static void SetSelectedEmulator()
switch (Properties.Settings.Default.emulator)
{
case 0:
_selectedEmulator = new Trinity335a();
_selectedEmulator = new Trinity335aTDB64();
break;
case 1:
_selectedEmulator = new cmangosZero();
break;
case 2:
_selectedEmulator = new Azeroth335a();
break;
case 3:
_selectedEmulator = new Trinity335a201901();
break;
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@

namespace TrinityCreator.Emulator
{
class Trinity335a : IEmulator
class Trinity335a201901 : IEmulator
{
public Trinity335a()
public Trinity335a201901()
{
ID = 0;
}
Expand All @@ -20,7 +20,7 @@ public Trinity335a()
public string GenerateQuery(TrinityItem item)
{
return SqlQuery.GenerateInsert("item_template", ItemTemplate(item));
}
}

public string GenerateQuery(TrinityQuest quest)
{
Expand All @@ -34,15 +34,8 @@ public string GenerateQuery(TrinityQuest quest)

public string GenerateQuery(TrinityCreature creature)
{
string result = SqlQuery.GenerateInsert("creature_template", CreatureTemplate(creature)) +
return SqlQuery.GenerateInsert("creature_template", CreatureTemplate(creature)) +
SqlQuery.GenerateInsert("creature_template_addon", CreatureTemplateAddon(creature));

if (creature.Trainer.TrainerType != 0)
{
result += SqlQuery.GenerateInsert("trainer", Trainer(creature)) +
SqlQuery.GenerateInsert("trainer_spell", TrainerSpell(creature));
}
return result;
}

public string GenerateQuery(LootPage loot)
Expand All @@ -60,7 +53,7 @@ public string GenerateQuery(VendorPage vendor)

private Dictionary<string, string> ItemTemplate(TrinityItem item)
{
var kvplist = new Dictionary<string, string>
var kvplist = new Dictionary<string, string>
{
{"entry", item.EntryId.ToString()},
{"name", SqlQuery.CleanText(item.Name)},
Expand Down Expand Up @@ -114,7 +107,7 @@ public string GenerateQuery(VendorPage vendor)
{
throw new Exception("Invalid value in magic resistance.");
}

if (item.InventoryType.Id == 15 || item.InventoryType.Id == 26)
kvplist.Add("RangedModRange", "100");

Expand Down Expand Up @@ -246,6 +239,10 @@ public string GenerateQuery(VendorPage vendor)
{"unit_flags2", creature.UnitFlags2.BitmaskValue.ToString()},
{"dynamicflags", creature.DynamicFlags.BitmaskValue.ToString()},
{"family", creature.Family.Id.ToString()},
{"trainer_type", creature.Trainer.TrainerType.ToString()},
{"trainer_spell", creature.Trainer.TrainerSpell.ToString()},
{"trainer_class", creature.Trainer.TrainerClass.ToString()},
{"trainer_race", creature.Trainer.TrainerRace.ToString()},
{"type", creature._CreatureType.Id.ToString()},
{"type_flags", creature.TypeFlags.BitmaskValue.ToString()},
{"lootid", creature.LootId.ToString()},
Expand Down Expand Up @@ -292,35 +289,10 @@ public string GenerateQuery(VendorPage vendor)
return kvplist;
}

private Dictionary<string, string> Trainer(TrinityCreature creature)
{
var kvplist = new Dictionary<string, string>
{
{ "Id", creature.Entry.ToString()},
{ "Type", creature.Trainer.TrainerType.ToString()},
//{ "trainer_class", creature.Trainer.TrainerClass.ToString()}, <-- removed?
//{ "trainer_race", creature.Trainer.TrainerRace.ToString()} <-- removed?
};

return kvplist;
}
private Dictionary<string, string> TrainerSpell(TrinityCreature creature)
{
var kvplist = new Dictionary<string, string>
{
{ "TrainerId", creature.Entry.ToString()},
{ "SpellId", creature.Trainer.TrainerSpell.ToString()},

// todo: This needs to be updated with price & reqs
};

return kvplist;
}


private Dictionary<string, string>[] LootTemplates(LootPage loot)
{
List<Dictionary<string,string>> result = new List<Dictionary<string,string>>();
List<Dictionary<string, string>> result = new List<Dictionary<string, string>>();
foreach (LootRowControl row in loot.lootRowSp.Children)
{
var kvplist = new Dictionary<string, string>
Expand Down

0 comments on commit 7728492

Please sign in to comment.