Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 2 [3] 4 5 ... 7

Author Topic: Dwarven Guidance Counselor 0.0.6 11 May 2011  (Read 51655 times)

Pearlie

  • Escaped Lunatic
    • View Profile
Re: Dwarven Guidance Counselor 0.0.3 27 Apr 2011
« Reply #30 on: April 28, 2011, 08:43:32 am »

Your sample worked perfectly. My fortress has 40 dwarves, however it doesn't look like that's the issue, as I just tested and still had the same issue with a brand new fortress...

edit: I just retried and made the xml whilst on the embark screen instead of in game, and it worked perfectly.
« Last Edit: April 28, 2011, 08:51:19 am by Pearlie »
Logged

knaveofstaves

  • Bay Watcher
  • Likes bogeymen for their terror-inspiring antics.
    • View Profile
Re: Dwarven Guidance Counselor 0.0.3 27 Apr 2011
« Reply #31 on: April 28, 2011, 09:02:21 am »

Your sample worked perfectly. My fortress has 40 dwarves, however it doesn't look like that's the issue, as I just tested and still had the same issue with a brand new fortress...

edit: I just retried and made the xml whilst on the embark screen instead of in game, and it worked perfectly.

...!

You're right! I've never tested it anywhere but from the embark screen!

I've got to say I'm a little embarrassed and a lot relieved. My script doesn't completely suck :)
Logged
Dwarven Guidance Counselor, my little scripting project.

Rez

  • Bay Watcher
    • View Profile
Re: Dwarven Guidance Counselor 0.0.3 27 Apr 2011
« Reply #32 on: April 28, 2011, 07:41:42 pm »

bump for great justice!

This tool is awesome.
Logged

niku98

  • Escaped Lunatic
    • View Profile
Re: Dwarven Guidance Counselor 0.0.3 27 Apr 2011
« Reply #33 on: April 28, 2011, 10:05:00 pm »

There's a bug in the script, preventing the names of the dwarves from being picked up properly from Runesmith exports. The issue seems to be that Runesmith always includes a Skills dump even if you didn't request it, which includes a tag called "Name".

Hacky fix, but change line 105 to read this:

Code: [Select]
dwarfnames[i]=xmlDoc.getElementsByTagName("Creature")[i].getElementsByTagName("Name")[0].childNodes[0].nodeValue;
Logged

knaveofstaves

  • Bay Watcher
  • Likes bogeymen for their terror-inspiring antics.
    • View Profile
Re: Dwarven Guidance Counselor 0.0.3 27 Apr 2011
« Reply #34 on: April 28, 2011, 10:44:12 pm »

There's a bug in the script, preventing the names of the dwarves from being picked up properly from Runesmith exports. The issue seems to be that Runesmith always includes a Skills dump even if you didn't request it, which includes a tag called "Name".

Hacky fix, but change line 105 to read this:

Code: [Select]
dwarfnames[i]=xmlDoc.getElementsByTagName("Creature")[i].getElementsByTagName("Name")[0].childNodes[0].nodeValue;

Actual scriptfixes! Squee!

...right. When I generate the XML from embark, the dorfs don't HAVE any skills yet. So I wouldn't have noticed this.

And as you might have noticed, "hacky fix" is my default mode. So... thank you! I'll poke around at it.
Logged
Dwarven Guidance Counselor, my little scripting project.

knaveofstaves

  • Bay Watcher
  • Likes bogeymen for their terror-inspiring antics.
    • View Profile
Re: Dwarven Guidance Counselor 0.0.3 27 Apr 2011
« Reply #35 on: April 29, 2011, 01:04:28 am »

OK, I recreated the bug working with XML generated while the game is running, and it was fixed with the script edit niku98 posted. You also have to swap out line 183 to say this:

Code: [Select]
document.getElementById("dwarfname").value=xmlDoc.getElementsByTagName("Creature")[pick].getElementsByTagName("Name")[0].childNodes[0].nodeValue;

if you want the name display to work.

The next update will have this in it, if you prefer to wait. But I'm not updating until I figure out why IE isn't working, and that could take... a while.

UPDATE: Or, set line 183 to

Code: [Select]
document.getElementById("dwarfname").value=dwarfnames[pick];
See? I'm not that smart, but I'm learning.
« Last Edit: April 29, 2011, 01:32:15 am by knaveofstaves »
Logged
Dwarven Guidance Counselor, my little scripting project.

knaveofstaves

  • Bay Watcher
  • Likes bogeymen for their terror-inspiring antics.
    • View Profile
Re: Dwarven Guidance Counselor 0.0.4 29 Apr 2011
« Reply #36 on: April 29, 2011, 11:43:57 am »

Victory! IE submits!

And it only took a hackish wraparound of a proprietary, deprecated technology to get around a security feature that Microsoft claims shouldn't have stopped me in the first place.

MICROSOFT! Y U NO NOT SUCK!
Logged
Dwarven Guidance Counselor, my little scripting project.

Pearlie

  • Escaped Lunatic
    • View Profile
Re: Dwarven Guidance Counselor 0.0.4 29 Apr 2011
« Reply #37 on: April 30, 2011, 06:34:38 am »

Awesomeness :) Would you consider making it recognise nicknames so that new migrants can be easily identified?
Logged

knaveofstaves

  • Bay Watcher
  • Likes bogeymen for their terror-inspiring antics.
    • View Profile
Re: Dwarven Guidance Counselor 0.0.4 29 Apr 2011
« Reply #38 on: April 30, 2011, 07:15:47 am »

Awesomeness :) Would you consider making it recognise nicknames so that new migrants can be easily identified?

So... if you click the Nickname button on the Runesmith XML export, and if that dwarf has a nickname...

Should it not display the normal name at all, just the nickname? Or both? Both is kind of a lot of text for that little dropdown...
Logged
Dwarven Guidance Counselor, my little scripting project.

Pearlie

  • Escaped Lunatic
    • View Profile
Re: Dwarven Guidance Counselor 0.0.4 29 Apr 2011
« Reply #39 on: April 30, 2011, 07:55:30 am »

I'd love it if it displayed just the nickname :)
« Last Edit: April 30, 2011, 10:12:45 pm by Pearlie »
Logged

knaveofstaves

  • Bay Watcher
  • Likes bogeymen for their terror-inspiring antics.
    • View Profile
Re: Dwarven Guidance Counselor 0.0.5 03 May 2011
« Reply #40 on: May 03, 2011, 02:23:52 am »

The Find Best feature can suck down system resources pretty hard, especially if you have a lot of dorfs, your computer is old, or you're using IE. It hasn't crashed my browser, but I get spinny wheels for a while on my test of pop 224. My goal for 0.0.6 is a menu that lets you select dorfs for a "Find Best Among", and hopefully if I script it right that'll cut down on the resource use.

Nicknames are in, too.
Logged
Dwarven Guidance Counselor, my little scripting project.

Freddybear

  • Bay Watcher
    • View Profile
Re: Dwarven Guidance Counselor 0.0.5 03 May 2011
« Reply #41 on: May 04, 2011, 08:52:22 pm »

This is great! Out of the seven starting dwarfs, I got three "good" job matches, two "above average", and two who weren't good for much of anything.  :)
Logged

knaveofstaves

  • Bay Watcher
  • Likes bogeymen for their terror-inspiring antics.
    • View Profile
Re: Dwarven Guidance Counselor 0.0.5 03 May 2011
« Reply #42 on: May 05, 2011, 01:09:46 am »

This is great! Out of the seven starting dwarfs, I got three "good" job matches, two "above average", and two who weren't good for much of anything.  :)

Thanks, glad you like it!

If you have to take a below average, take it in manager/broker if you can. Or just reroll until you find a group you like. I've been scumming off the same Day 1 save for my past few forts, with a starting seven in the 93rd percentile for attr points. I've already scripted that in for 0.0.6, you'll know in the aggregate how good your numbers are. Of course the points might be all in Musicality or something useless like that, it won't be that smart.
Logged
Dwarven Guidance Counselor, my little scripting project.

Girlinhat

  • Bay Watcher
  • [PREFSTRING:large ears]
    • View Profile
Re: Dwarven Guidance Counselor 0.0.5 03 May 2011
« Reply #43 on: May 05, 2011, 01:28:35 am »

Can this be used to read and sort likes and preferences?  I want to find that one guy who likes slade in my fortress, and kill him, then take the one who likes gold and make him a metalsmith.

knaveofstaves

  • Bay Watcher
  • Likes bogeymen for their terror-inspiring antics.
    • View Profile
Re: Dwarven Guidance Counselor 0.0.5 03 May 2011
« Reply #44 on: May 05, 2011, 01:45:51 am »

Can this be used to read and sort likes and preferences?  I want to find that one guy who likes slade in my fortress, and kill him, then take the one who likes gold and make him a metalsmith.

Sorry, I only know what Runesmith tells me, and it doesn't export preferences. :(
Logged
Dwarven Guidance Counselor, my little scripting project.
Pages: 1 2 [3] 4 5 ... 7