A Part of Chkdraft

Advantages

Disadvantages

A Standalone Program

What's provided

Advantages

Disadvantages

A Plugin

What's provided

Advantages

Disadvantages

Getting Started:

Examples:

Plugins

Standalone Programs

Post has been edited 5 time(s), last time on Jun 6 2014, 12:03 am by jjf28.





Reached the top of StarCraft theory crafting 2:12 AM CST, August 2nd, 2014. Rs_yes-im4real - Clan Aura - jjf28.net84.net

So you're looking to make a plugin... first thing's first, you need to decide whether it should be a part of Chkdraft, a standalone program with some of Chkdraft's code to get you started, or a a plugin, each holds advantages and disadvantages.: If whatever you're creating has very little abstraction from blizzards map format and is justifiably useful to everyone that might use Chkdraft, pitch it to me, gather a bit of what others think about it, if it seems to fit or has a lot of demand we can work together to get it integrated, the source is included with every official release of Chkdraft so you can look at doing the code yourself if I approve and don't show high enough interest to do it straight away (please track your changes if this is the case).: Can use all of Chkdraft's code, no hassle for users, easier distribution of your feature: Need to get my approval, your code may be altered from time to time: If you want to read a map or make some one-time changes a standalone program's the right way to go.: Code for opening and saving, almost all code used by Chkdraft to read and make changes to the map: Easier and quicker to code than plugins (starts the same way): Map may be saved over by this or another program, you're in charge of distribution: If you're making something that would be most useful modifying open maps, this is the right path, it's a little more difficult to get started then a standalone program.: Everything you have with standalone programs plus... messages for saving the map, importing and exporting scenario files from/to Chkdraft, and sending new triggers in text or raw TRIG section form: Can work near-seamlessly with open maps, instant synchronization: More difficult to code than standalone programs, you're in charge of distribution1. Obtain a compiler, ideally Visual Studios 20122. Create a new project for your plugin/program3. Download the latest copy of Chkdraft4. Browse to //Chkdraft/src/Chkdraft/Source Files/ and copy the entire Mapping Core folder to your projects code folder5. Include SFmpq_MT.lib for your release configuration and SFmpq_MTd.lib for your debug configuration����- In VS2012 go to project->properties, select your configuration in the top left box, select linker->input and in addition dependencies put "Mapping Core/SFmpq_MT.lib;" and "Mapping Core/SFmpq_MTd.lib;" for release and debug configurations respectively.6. In project->properties, under C/C++ All Options, change runtime library to /MT (for release configuration) and /MTd (for debug configuration)7. Include all the .h and .cpp files from mapping core in your project, preferably under their own filters8. Put #include "Mapping Core/MappingCore.h" at the top of your main and any other project files that need it9. Copy ChkdPlugins.h from Chkdraft to your project code folder, include it in your project and #include "ChkdPlugins.h" in any files necessary10. If your project doesn't have a window, setup a message-only window for communicating with Chkdraft (see example programs if necessary)11. Get a handle to Chkdraft ( HWND hChkdraft = FindWindow("MainChkdraftWin", NULL); )12. Send messages as ChkdPlugins.h specifies to communicate with Chkdraft���� http://www.staredit.net/files/2962/ ����ATextTrigGenerator (link pending)���� http://www.staredit.net/files/2901/ ����TerrainScale (link pending)����TrigAnalysis (link pending)����TrigCount (link pending)