|
Post by separ on Sept 11, 2009 15:49:21 GMT
Awesome that someone is picking this up. I use this daily and love it. I have to admit that I actually use the older version most of the time for only one reason, ecto/psy/vile/int damage. These make too many columns and push the mob name off the screen, unless I run it full screen. Being able to show/hide these damage types would be great, or reducing the horizontal space between the damages. I spend 70% of my time looking at the incoming damage window. Maybe you have same problem with a high-dpi display I had before the last changes? But added info requires a lot of space ... I'm running fullscreen too. Yeah, I know. But I have no clue how to do that. That's why I hope that somebody more knowledgable in perl and tk chimes in.
|
|
|
Post by nate on Sept 11, 2009 16:38:30 GMT
how do I actually run the script (that txt file)? I normally just run nwn.pl. I tried renaming it to that, but nothing happens when I launch it.
|
|
|
Post by separ on Sept 11, 2009 22:55:54 GMT
Renaming to yal.pl (and giving execute permissions) should be all you need to do. No idea about windows.
And if you try my version you also need the hgdata.xml file
|
|
|
Post by nate on Sept 12, 2009 3:27:52 GMT
When I run it a command prompt comes up, then disappears. that's it Can't locate Date/Format.pm in @inc (@inc contains: C:/Program Files (x86)/Perl/ site/lib C:/Program Files (x86)/Perl/lib .) at C:\NWN\logs\yal.pl line 35. BEGIN failed--compilation aborted at C:\NWN\logs\yal.pl line 35. My Date folder doesnt have the file Format.pm in it. Trying to use the Perl Package Manager to find the right one...
|
|
|
Post by nate on Sept 12, 2009 3:51:51 GMT
|
|
|
Post by nate on Sept 12, 2009 4:29:22 GMT
!who party class doesnt seem to fill in the party anymore, even after typing .who
|
|
|
Post by separ on Sept 12, 2009 8:02:26 GMT
!who party class doesnt seem to fill in the party anymore, even after typing .who commands (currently) use the whisper channel, you did try /w .who?
|
|
|
Post by separ on Sept 12, 2009 8:06:09 GMT
When I run it a command prompt comes up, then disappears. that's it Can't locate Date/Format.pm in @inc (@inc contains: C:/Program Files (x86)/Perl/ site/lib C:/Program Files (x86)/Perl/lib .) at C:\NWN\logs\yal.pl line 35. BEGIN failed--compilation aborted at C:\NWN\logs\yal.pl line 35. My Date folder doesnt have the file Format.pm in it. Trying to use the Perl Package Manager to find the right one... Oops, didn't think someone wouldn't have all the required perl-packages. I've added 3 new package-uses: use Date::Format; use Date::Parse; use XML::Simple;
|
|
|
Post by Yomi on Sept 12, 2009 15:59:45 GMT
I've written my logger without using those packages, I suspect it'd be easier if you could get away without using them. For instance: my %month_hash = ( 'Jan', 0, 'Feb', 1, 'Mar', 2, 'Apr', 3, 'May', 4, 'Jun', 5, 'Jul', 6, 'Aug', 7, 'Sep', 8, 'Oct', 9, 'Nov',10, 'Dec',11, ); sub parsetime { my($tm) = @_; # Convert to seconds using standard module my($dow, $mon, $day, $hr, $min, $sec) = $tm =~ /(\S+) (\S+) (\S+) (\d+):(\d+):(\d+)/; if ((!defined $sec) || (!defined $month_hash{$mon}) ) { warn "Unable to parse date string: '$tm'"; return 0; } my $t = timelocal $sec, $min, $hr, $day, $month_hash{$mon}, $serveryear; $t; }
which will turn NWN time into seconds without having to use a module. Now it's possible you're doing fancier things with times (I use Date::Calc for the web server stuff).
If you use the trivial XML parser you don't need XML::Simple. While that's a bit less flexible, hardly anyone has XML::Simple installed.
Another suggestion is to perhaps include a copy of the XML (or a stripped down version) in the source, and then if it can't find the hgdata.xml file it can give a little whine about it in the GUI but still work.
If you do add !echo support, I'd keep the whisper commands in for a while.
We should add it to git. I have an account on github, you think the xml file should be managed there?
|
|
|
Post by separ on Sept 12, 2009 18:15:56 GMT
I've written my logger without using those packages, I suspect it'd be easier if you could get away without using them. For instance: my %month_hash = ( 'Jan', 0, 'Feb', 1, 'Mar', 2, 'Apr', 3, 'May', 4, 'Jun', 5, 'Jul', 6, 'Aug', 7, 'Sep', 8, 'Oct', 9, 'Nov',10, 'Dec',11, ); sub parsetime { my($tm) = @_; # Convert to seconds using standard module my($dow, $mon, $day, $hr, $min, $sec) = $tm =~ /(\S+) (\S+) (\S+) (\d+):(\d+):(\d+)/; if ((!defined $sec) || (!defined $month_hash{$mon}) ) { warn "Unable to parse date string: '$tm'"; return 0; } my $t = timelocal $sec, $min, $hr, $day, $month_hash{$mon}, $serveryear; $t; }
which will turn NWN time into seconds without having to use a module. Now it's possible you're doing fancier things with times (I use Date::Calc for the web server stuff). I dont' do fancy things. But then, as I already have mentioned, I don't really know perl or tk. So, to get something I want done, I search for an example on the web and then adapt it with a bit pattern matching ... I'm sure there are better ways of doings things in perl than what I come up with. Same, see above. Maybe I'll find someone to rewrite import_hgdata_xml() without using XML::Simple once I'm done with some more changes. ... The idea was to offload the management of the data and just care about using it. And I don't think it's too much trouble to require the user to get an xml-file from a referenced thread. But it sure would make things easier if there was a common place to download all. Got a place on hgweb for that maybe? I'm in no hurry to change things, they work fine for me as they do now. But I'm doing a bit refactoring right now which should make such changes easier later on. Yeah, good idea. And yal.pl should probably be managed there too.
|
|
|
Post by separ on Sept 16, 2009 11:27:00 GMT
Interest seems to be limited, but for those who are interested in this work, go get a look at github.com/separ/hg-yalHave pushed a new version there a few minutes ago ... with a few changes. - restructuring work on parser (ongoing) - redid party summary dialog - nicer chatlog - config options to (not) display new mob-data and esoteric damage types - maybe more, will try to make smaller commits in the future so I don't forget to list stuff Also included in the repository is Yomi's hgdata.xml file since things probably don't work without it anymore. Comment welcome Edit: forgot to mention ... I removed the old download location, so if you want it, you get it from github
|
|
|
Post by illandous on Sept 29, 2009 2:04:04 GMT
Yes I'm very interested on what your doing with it. I'm actually adding your changes to my subversion repository. Did you complile it to a .exe? It would generally get more main stream support then.
|
|
|
Post by nate on Sept 29, 2009 4:32:58 GMT
Unterminated <> operator at C:\NWN\logs\yal.pl line 7. error on the new one. I'm trying to find the bug in the code myself, but i dont have any code editors anymore
|
|
|
Post by separ on Sept 30, 2009 16:06:21 GMT
Yes I'm very interested on what your doing with it. I'm actually adding your changes to my subversion repository. Did you complile it to a .exe? It would generally get more main stream support then. Ok ... if there is interest I maybe should push my changes more often out there ... No .exe since I don't use windows and therefore have no use for that. Have a lot of changes in my local working dir, that don't yet bring any new functionality, but will help me with my long-term plans ...
|
|
|
Post by gandoron on Sept 30, 2009 17:33:20 GMT
I haven't been able to get the new .pl to work at all. It immediately closes. the earlier version, think 1.2b, opens fine, but not the most recent. Is these another library or something else that i need to load to make the new .pl file open correctly?
using Vista Business x64
-G
|
|