|
Author |
Thread Statistics | Show CCP posts - 2 post(s) |

Talenram
|
Posted - 2009.03.30 21:39:00 -
[1]
I've been banging my head against this for a while. I want to get information about Agents out of EveAI.Core and I can't get it to work. From page 5 Amida Ta posted this code:
DataCore core = new DataCore (); DataReader reader = new DataReader (core); reader.Read (DataTypes.BasicMapData | DataTypes.Products);
The second line is invalid with the message "Cannot create an instance of the abstract class or interface 'EveAI.DataReader'". Could anyone help me out by pointing out how to actually get this to work? I know that i should use DataTypes.Agents in the third line, but I can't get the reader to point at the core.
|

Talenram
|
Posted - 2009.04.02 03:18:00 -
[2]
Turns out the agent information isn't contained in the EveAI.Core.dll file, thus the root of most of my problems. So now I have two options:
I'm stuck trying to figure out how to modify the .dll (can't get VCS to resolve the EveAI.DataDecoder reference, since it seems to me that this is a reference to the .dll itself).
Or I need to figure out how to get the code to become aware of the additional (although outdated) EveAI.Data.zip file.
Any help would be appreciated.
|

Talenram
|
Posted - 2009.04.03 02:18:00 -
[3]
I've tried almost every configuration of reading the data I can, but I keep getting exceptions every time I try to read data. My code follows:
DataCore data = new DataCore(); DataReader reader = new StaticDataDataReader(data, @"C:\"); reader.Read();
The EveAI.Data.Zip is in C:\. I've tried changing reader to StaticDataDataReader. I've tried giving Read() specific DataTypes, such as DataTypes.Agents and I still get exceptions. The exception code follows:
System.Collections.Generic.KeyNotFoundException was unhandled Message="The given key was not present in the dictionary." Source="mscorlib" StackTrace: at System.ThrowHelper.ThrowKeyNotFoundException() at System.Collections.Generic.Dictionary`2.get_Item(TKey key) at EveAI.StaticDataDataReader.ReadAgents() at EveAI.DataReader.Read(DataTypes typesToRead) at EveAI.DataReader.Read() at ConsoleApplication1.Program.Main(String[] args) in ...\Program.cs:line 39 at System.AppDomain._nExecuteAssembly(Assembly assembly, String[] args) at System.AppDomain.ExecuteAssembly(String assemblyFile, Evidence assemblySecurity, String[] args) at Microsoft.VisualStudio.HostingProcess.HostProc.RunUsersAssembly() at System.Threading.ThreadHelper.ThreadStart_Context(Object state) at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state) at System.Threading.ThreadHelper.ThreadStart() InnerException:
|

Talenram
|
Posted - 2009.04.04 00:46:00 -
[4]
That fixed things up pretty well. A comment and a request, though.
The first entry in the agtAgents file is
10$19$1000137$60012739$1$0$10
This 10 is not a valid agentID, and I can't locate an agent with a corporationID of 1000137 and a stationID of 60012739 so I assume this entry is just totally invalid and can be ignored.
As for my request, is there any way you could add the Corporation information to the Agent and/or Station? The information is in the data, it's just not available through the API that I've been able to locate. I could probably hack something together using a lookup table of all the station names and what corporation they belong to, but this seems inelegant.
Thanks for the work you've put into this project, Amida Ta, and sorry for the grief. :-)
|

Talenram
|
Posted - 2009.04.19 19:25:00 -
[5]
Originally by: Betty Rhage Where do I get the source code? I cant find it anywhere in the download :(
Read the thread. There is no source. You can deconstruct the .dll files if you want the source.
|
|
|
|