Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  

Author Topic: Writing plugin got compiler errors and don't know why [SOLVED]  (Read 817 times)

Chain

  • Bay Watcher
  • When God closes a door, punch him through it!
    • View Profile
Writing plugin got compiler errors and don't know why [SOLVED]
« on: December 04, 2013, 11:31:07 am »

Hello I look for a tool which monitors the current Items in stock.
If this does not exist I'm looking for the necessary pointers to them.
I'm able to write C++ and C# code so I would write the tool my self.

If someone could give me some tips or got what I'm looking for please let me know.

Thank you

#EDIT: Solved Thank you for your help! The Stockpile Stalker plugin is in development :)
#EDIT2: Since I did not like to open a new Post I'm recycling this one. I got wiered compiler errors because of inheritance and my VS is not recognising classes. Please take a look at my last post. To find the compile errors.
#EDIT3: Nvm. it compiles now. I just did rip out most of it.
« Last Edit: December 08, 2013, 12:47:21 pm by Chain »
Logged

Putnam

  • Bay Watcher
  • DAT WIZARD
    • View Profile
Re: Looking for tool/pointers Items in Stock v.0.34.11
« Reply #1 on: December 05, 2013, 04:08:49 am »

C++? You're in luck.

What exactly are you looking for in monitoring them?

I believe the name for the vector for every item in DFHack is df::global::world->items.all
« Last Edit: December 05, 2013, 04:14:18 am by Putnam »
Logged

Chain

  • Bay Watcher
  • When God closes a door, punch him through it!
    • View Profile
Re: Looking for tool/pointers Items in Stock v.0.34.11
« Reply #2 on: December 05, 2013, 06:30:37 pm »

Thanks for the link and vector.
Now I have to find out how to use DFHack as library for an 3rd party tool.
Do you know if I have to do some special stuff to get it to work or if I can use it like any other library?

I like to create a simple program with a window in which it shows all the goods you currently have in your Stockpiles because I'm too lazy to always press Z and search through the menu.

Cheers
« Last Edit: December 05, 2013, 06:33:21 pm by Chain »
Logged

Putnam

  • Bay Watcher
  • DAT WIZARD
    • View Profile
Re: Looking for tool/pointers Items in Stock v.0.34.11
« Reply #3 on: December 05, 2013, 06:47:08 pm »

Pretty sure you'll have to make it a plugin, but I'm also pretty sure you can still open separate windows through plugins (E.G stonesense)

Chain

  • Bay Watcher
  • When God closes a door, punch him through it!
    • View Profile
Re: Looking for tool/pointers Items in Stock v.0.34.11
« Reply #4 on: December 06, 2013, 01:27:10 pm »

Pretty sure you'll have to make it a plugin, but I'm also pretty sure you can still open separate windows through plugins (E.G stonesense)

Thank you :), I've just started working on the plugin.
It could take some time till I got something to show since I have to learn first how to use it properly.
But I'm currently dumping the whole vector to the console this is a good sign :).

This thread is solved.
cya
Logged

Chain

  • Bay Watcher
  • When God closes a door, punch him through it!
    • View Profile
Re: Looking for tool/pointers Items in Stock v.0.34.11 [Solved]
« Reply #5 on: December 08, 2013, 12:14:21 pm »

I get some serious compiling errors. Because of inheritance and the compiler don't recognizes my classes.
Can please someone take a look, it's driving me nuts.

Stackoverflow post: http://stackoverflow.com/questions/20455091/inheritance-of-class-throws-undeclared-identifier-errors-and-dont-know-why
Logged

Deon

  • Bay Watcher
  • 💀 💀 💀 💀 💀
    • View Profile
Re: Writing plugin got compiler errors and don't know why [SOLVED]
« Reply #6 on: December 18, 2013, 07:24:17 am »

Removing SOLVED from the thread title may be good to find help. Also I would suggest asking in DFHack thread or PMing active plugin developers, I don't think average modders can help you with coding.
Logged
▬(ஜ۩۞۩ஜ)▬
✫ DF Wanderer ✫ - the adventure mode crafting and tweaks
✫ Cartographer's Lounge ✫ - a custom worldgen repository