Monday, 2007-06-18

*** tpb has joined #tp00:00
*** ChanServ sets mode: +o tpb00:00
*** mithro has joined #tp00:09
*** mithro has quit IRC01:48
*** mithro has joined #tp01:53
*** tuna-fish has joined #tp02:31
*** tuna-fish has quit IRC02:35
*** llnz has joined #tp03:05
llnzhi all03:10
* llnz answers xdotx's email03:10
*** nash has quit IRC03:40
*** mithro has quit IRC03:42
xdotxback03:42
llnzhi xdotx03:43
xdotxhey llnz03:43
*** mithro has joined #tp03:45
*** Demitar has quit IRC03:53
xdotxllnz: ah, so omitting galaxy would be fine too?04:06
llnzyes04:06
xdotxmakes sense04:06
llnzthe idea was to have multiple galaxies, kind of having multiple games in one server04:06
llnzbut it's definitely not necessary04:07
* xdotx nods04:07
jothamanyone do C++ here?04:18
jotham http://channel.sourceforge.net/boost_join/libs/join/doc/boost_join_design.html#mozTocId38745704:19
tpb<http://ln-s.net/cYc> (at channel.sourceforge.net)04:19
llnzyes04:19
jothamcheck that out04:19
jothaminteresting04:19
xdotxi <3 C++04:20
* xdotx <3 boost04:22
jotham C++ sure gives you plenty of ropes to hang yourself with04:22
xdotxheheh04:23
xdotxthat definitely looks interesting and useful04:23
llnzinteresting04:24
xdotxon further inspection though, it's a part of boost... but it certainly would be nice to see something like that in it04:26
*** mithro has quit IRC04:51
*** mithro has joined #tp04:55
mithrohrm....05:25
*** tuna-fish has joined #tp05:25
mithroI don't understand that boost_join_design stuff05:25
mithroa queue should be inheriantly thread safe05:25
xdotxmithro: how could anything other than single instructions be thread safe?05:33
mithroxdotx: because you put the data into the queue, then incremete the counter05:37
mithroso the data is aways there before anybody can know about it05:38
xdotxwhat if you don't want dupes?05:38
mithrodupes?05:39
xdotxscenario: add x to the queue, <contact switch>, if queue doesn't contain x, add x to queue05:40
mithroyou want to add x to the queue as long as x isn't in the queue?05:41
xdotxright05:41
mithrohrm... why would you want to do that?05:41
xdotxor well, so long as it's not the front05:41
mithrotechnically thats not a queue :P05:42
xdotxhmm. off the top of my head.. heh, an affliction healing script (like in a game.. with afflictions)05:42
xdotxi corrected myself :p05:42
mithrohence it doesn't have the nice property05:43
mithroI think you are probably solving the wrong problem with that idea?05:44
xdotxin a game, say a MUD, you get an affliction, it may result in multiple, different msgs saying you just got the affliction. your script get two of them, but of course you don't want to heal the affliction twice05:44
xdotxjust replace "the list" with "the front" it still applies05:44
mithrobut your solution doesn't work, if the two different messages have a delay between then05:44
xdotxwhat if they don't?05:45
mithroIE message 1, heal, message 205:45
xdotxi did that all the time to mess with people...05:45
xdotx(some classes could "illusion" msgs)05:45
mithroyou should see that message1 and message2 refer to the same action and that you have already dealt with it05:45
xdotxyou can't always heal right away?05:46
mithroso you are saying you want to add a heal to the queue if it doesn't already exist?05:47
xdotxand you can have the same action, cure, for different afflictions05:47
xdotxwell, an affliction to the queue05:47
mithrohrm....05:48
xdotxthat was actually a common problem in people's healing system back when i used to play... i exploited it whenever possible05:49
mithroyou queue a "if I still have this afflication, cast heal"?05:50
xdotxyou queue a "i have this affliction"05:50
xdotxwhen you're removing from the queue, you look up the heal05:50
*** nash has joined #tp05:51
mithrothat doesn't make much sense05:51
mithroyou want to queue actions - not afflictions05:51
nashNor does that statement05:51
xdotxchecking which afflictions you have is costly in most cases, it would be wasteful to check often05:51
* nash waves05:52
mithrohey nash05:52
mithroxdotx: what happens if somebody else heals your afflication?05:52
xdotxyou don't necessarily want to queue actions though, because then you don't even know your current afflictions.05:52
mithroor the affliction resolves itself before you can cast heal05:52
xdotxwell clearly you need to set up your system to handle that?05:53
nashWhat are you talking about?05:53
xdotxheh. an in-depth case of when a queue would not be thread safe05:54
mithronash: well technically, boost_join_design - but we have kind of diverged05:54
mithroxdotx: but we arn't talking about a queue anymore05:54
* xdotx nods05:54
nashokay05:54
xdotxmithro: the concept should still apply05:55
mithroa queue has two methods, push and pop05:55
xdotxbut a double push is still possible, and in some cases inappropriate05:56
nashmithro: Can you get fro's code to run?05:56
mithroas soon as you have any other method which lets you look inside the queue, it's not really a queue05:56
mithronash: yeah, works fine05:56
nashokay: Which pythn/platform are you using?05:57
xdotxeven if you're just looking at the front though. you may not want the same thing listed twice05:57
nashAny operation which can be implemented in terms of operatons on the queue, still means it is a queue05:57
nashmithro: ?  I get   File "/home/nash/work/thousandparsec/tpruledev/src/core/ObjectManagement.py", line 69, in loadObjectNodes05:58
nash    self.objects[name] = [game_objects.ObjectUtilities.ObjectNode(self, filename.partition('.')[0], module) for filename in os.listdir(object_dir)]05:58
nashAttributeError: 'str' object has no attribute 'partition'05:58
nashlots of crud before hand of course/05:58
mithroxdotx: do a = queue.pop(), while <a not what I want>05:59
mithronash: python 2.505:59
mithronash: can you give me the line numbers?05:59
nashI have 2.4.4  do I need to upgrade to 2.5 then?05:59
mithronash: I doubt it05:59
nashLine is pasted above: line 69 of ObjectManagement.py05:59
mithroopps06:02
nashBasically it fails calling 'partition' retuned on a string returned from os.listdir06:02
mithroit is actually a python 2.5 method06:03
nashright06:03
nashSo I need python 2.5 then06:03
mithropartition(  sep)06:03
mithro    Split the string at the first occurrence of sep, and return a 3-tuple containing the part before the separator, the separator itself, and the part after the separator. If the separator is not found, return a 3-tuple containing the string itself, followed by two empty strings. New in version 2.5.06:03
nash*sigh*06:03
mithronash: don't upgrade yet06:03
* nash gets the joy of upgrading all the python2.4 modules to the python2.5 equivs... 06:03
nashmithro: okay06:04
* xdotx is goin' to bed06:07
mithronash: give that email patch a try06:09
llnzcya xdotx06:09
nashmithro: okay06:09
* nash is about to eat06:09
xdotxbyes06:11
nashhave a good one06:11
nashCool - much better06:12
*** xdotx has quit IRC06:12
nashWow - this has some drawing issues06:12
nashAre python wx windows apps always bad as far as redraw is concerned?06:12
nashOtherwise... looks cool06:13
nashSweet06:13
nashmithro: Were there any galaxie issues you wanted me to look at?06:15
nashAnyway - food time06:18
nashBack in a while06:18
mithronash: umm - the redraw issues are only bad when you haven't got everything hooked up correctly06:51
mithrohe appears to be rebuilding the tree every time (rather then just setting the background color)06:52
*** Demitar has joined #tp08:54
*** Demitar has quit IRC09:30
*** DystopicFro has joined #tp10:16
CIA-3frodough tpruledev * r1a177e727d25 / (3 files in 2 dirs):10:23
CIA-3Skeleton of menubar10:23
CIA-3Quick and dirty, just something to do while the mechanics worked on10:23
CIA-3my car and decided that, in fact, they needed a part from the dealer,10:23
CIA-3and that, woah boy would it cost a bit and I can come in tomorrow to10:23
CIA-3get it fixed all up. Meh.10:23
CIA-3mithro tpruledev * ra262881cd01a /src/core/ObjectManagement.py:10:23
CIA-32.4 Compatibility Change10:23
CIA-3str.partition is only in Python 2.5 and up...whoops, fixed to work around10:23
CIA-3that now10:23
* llnz wanders off10:23
llnzlater all10:23
*** llnz has quit IRC10:23
*** DystopicFro has quit IRC10:30
*** Demitar has joined #tp10:42
*** CIA-3 has quit IRC15:22
*** Demitar has quit IRC15:22
*** Epyon has quit IRC15:22
*** JLP has quit IRC15:22
*** tuna-fish has quit IRC15:22
*** drdevice has quit IRC15:22
*** zipola has quit IRC15:22
*** jotham has quit IRC15:22
*** mithro has quit IRC15:22
*** daxxar has quit IRC15:22
*** TBBle has quit IRC15:22
*** tuna-fish has joined #tp15:25
*** mithro has joined #tp15:25
*** zipola has joined #tp15:25
*** CIA-3 has joined #tp15:25
*** drdevice has joined #tp15:25
*** TBBle has joined #tp15:25
*** jotham has joined #tp15:25
*** daxxar has joined #tp15:25
*** JLP has joined #tp15:26
*** Demitar has joined #tp15:35
*** Epyon has joined #tp15:36
CIA-3frodough tpruledev * rc3c1d6ae7747 / (45 files in 8 dirs):16:41
CIA-3Removing CRLF16:41
CIA-3That's what I get for using Windows. Meh. Cleaned up the erroneous16:41
CIA-3line endings and added have set my editor to use UNIX stile line16:41
CIA-3endings. Didn't know a CRLF messed up the shebang line...16:41
*** nash has quit IRC17:16
CIA-3mithro web * rb39bd8e5e97b /dev/documents/ncl.php: Added tips anchor.17:34
CIA-3mithro web * r0fc93fd0a7e2 /news/2007-06-08-1220.news: Merge with git+ssh://[email protected]/git/web.git17:34
*** mithro has quit IRC19:02
*** nash has joined #tp19:17
*** xdotx has joined #tp21:03
*** nash has quit IRC22:56
*** tuna-fish has quit IRC22:58

Generated by irclog2html.py 2.5 by Marius Gedminas - find it at mg.pov.lt!