[02:26] Join: Caelian_ joined #corewars [02:29] MSG: Ping timeout: 252 seconds [04:21] MSG: Ping timeout: 252 seconds [04:21] Join: Caelian|w joined #corewars [05:04] well, this is a standard morning [05:04] rainy morning, my bus-card might be dead, and first 3 hours were cancelled [10:52] Join: Core_new joined #corewars [14:05] MSG: Quit: Trillian (http://www.ceruleanstudios.com [14:09] Join: Core_new joined #corewars [15:01] m. [15:01] hrm. even [16:14] Join: Raptor joined #corewars [16:16] MSG: Client Quit [16:20] Join: Raptor joined #corewars [16:20] that's one stupid thing with chatzilla [16:21] when you install a new firefox entension it closes :( [16:35] Join: Nod_lesh joined #corewars [16:35] hello? [16:36] * Nod_lesh has almost forgotten irc ever existed [16:36] hehe, coo [16:37] hey, got some questions about core wars, anyone here mind giving me a minute of your time/ [16:37] ? [16:39] Hi Nod_lesh [16:40] watup watup [16:40] thought this room was dead for a second [16:40] (since it was) [16:40] everyone is probably at work [16:40] got some questions? [16:41] hmmm yeah [16:41] fire away! [16:41] so hmm [16:41] ok, before i go, i got some coding experiance from my school days [16:42] cpp pascal, some scripting... does ANY of that help? [16:43] yes because you now think like a programmer [16:43] you just have to learn the language [16:43] it's a bit lower level but that shouldn't be a problem [16:44] i see [16:44] ok, well, at least i have that [16:44] ok, so i got the list of commands [16:44] some 17 of them [16:44] seems like i can pass 2 paramaters to each command [16:44] there's also stuff like C-Robots [16:44] Yes [16:44] Ilmari's guide is best [16:44] well, this is for a class, i dont have a choice on the matter [16:45] Class? [16:45] What kind of project? [16:45] If you write a paper or report or something interesting please put it online [16:45] well, we need to make a bot [16:45] And feel free to ask for help and send the rest of the class here too [16:45] i wont [16:46] my project is to write a bot to kill all my classmates [16:46] is the bot to run using pmars or a different mars [16:46] holly damn [16:46] i have no clue [16:47] i'm on ARES [16:47] ares should be like pmars [16:47] i'll take your word for it oh great and powerfull raptor [16:47] I am just checking your lecturer isn't running something for an old standard, or even non-standard [16:47] :) [16:48] * Raptor suddenly likes Nod_lesh! [16:48] worship me :) [16:48] hahahaha [16:49] * Raptor strikes bvowk with a thunderbolt [16:49] quick, bring me a team of paleontologists and a rich guy in a jeep [16:49] just give me 10 seconds [16:50] i'm reading on the manual you gave me [16:50] but it doesnt explain what mov 0, 1 does [16:50] why 0? [16:51] mov copies something from the location referred to by the left hand field to the location referred to by the right hand field [16:51] why not 8? [16:51] oh [16:51] ok [16:51] all addresses are relative to the current instruction [16:51] so 0 is the current instruction [16:51] 1 is the next instruction [16:51] oooooh [16:52] so it's like saying "copy this instruction to the next instruction" [16:52] so mov 1, 2 would move the next command to the following line [16:52] then straight after executing that, i'tll execute the next instuction [16:52] yes [16:52] aha aha [16:53] ok, and all commands are either relative address or a number manipulator? [16:53] all addresses are relative [16:53] ok ok, i follow now [16:53] ok, who wins? [16:53] how do you win? [16:54] only numbers preceeded by an # are not relative, because they're immediate [16:54] win by causing your opponent to crash [16:54] by executing an invalid instruction, dat [16:54] i see [16:54] dat what? [16:54] if you write a dat on your opponent and he executes it, he dies [16:54] dat 0, 0? [16:55] dat anything [16:55] oh ok [16:55] so i can leave a dat bomb someplace, is that right? [16:55] no [16:55] you actually have to put in on your opponent [16:55] oh [16:55] k [16:55] hmmm how? [16:56] wait, where is my oponent? [16:56] you could put dats semi-randomly all over the place and hope you put one on your opponent [16:56] or you could put dats on consecutive locations. [16:56] i'm not sure i understand who i'm attacking [16:56] that will eventually overwrite your oppoent [16:56] there are two programs in memory at the same time [16:57] you and your class-mates program [16:57] both execute instructions alternately [16:57] you don't know where each other are [16:57] so would my opponent need to try and write to a dat cell to loose? [16:57] and you've got to crash him (or her) before they crash you [16:58] no, your opponent would need to try to execute a dat cell [16:58] you can safely write anywhere you like [16:58] though try not to overwrite yourself with dats ;) [16:58] i dont follow then [16:58] why not just write to a cell to eliminate a potential dat command [16:58] then write yourself [16:59] and move on and on [17:00] well that's what the imp does [17:00] you and your opponent execute instructions alternately [17:00] hmm [17:00] imp is mov 0,1 [17:01] i dont understand how to kill my opponent, why would they try and calc anything [17:01] if your opponent writes dat on a cell [17:01] and you overwrite it with you imp, then your imp executes on that cell, your imp lives [17:02] but if you write and imp on a cell, then your opponent overwrites it with a dat, the you execute that cell, your imp dies because it executed an invalid instruction [17:02] mov 0,1 won't kill your. [17:03] wait [17:03] i thought imp keeps moving on [17:03] (although some opponents occasionally kill themselves by accident when fighting imp) [17:03] imp keeps moving on, unless the opponent interferes [17:03] by bombing it, placing a dat on it [17:04] greetings [17:04] if the process which should execute the imp executes the dat an opponent overwrote it with, the imp will die [17:04] Hi Mizcu [17:05] yo mizcu [17:05] hmm [17:05] or changin the imp, so that instead of moving itself to *next* instruction, it moves to *next+1*, leaving a gap [17:05] ok [17:05] If you need to beat your opponent you ought to do something offensive [17:05] wait [17:05] mov 0, 1 [17:05] copies itself to cell x+1 [17:06] then there are 2 mov commands [17:06] would i now see 2 copys added to make 4 [17:06] and then 8 [17:06] etc? [17:06] if the opponent damages the imp, so the code becomes mov 0,2 it doesn't work properly [17:06] if copies itself 2 cells ahead [17:07] how can you damage an imp? [17:07] then when it executes the next cell, it probably executes empty core (which is dats) [17:07] It is possible to increment or decrement memory [17:07] after running one line, the next line is run; unless a jmp-command was run on which case next instruction run is the one jumped on [17:07] jesus [17:07] i'm gonna shoot my teacher [17:07] this is BS [17:07] have you read the guide? [17:07] hmm, somewhat [17:08] It explains it much better :) [17:08] i'm reading in paralel [17:10] the action behind is based on simple rules, but it can be overwhelming to read about what can be done with them [17:11] unfortunately we still could use a better newbie-guide, but no-one seems interested in starting the project [17:14] hmm [17:14] well, i might consider writing somthing down if i get this [17:14] brb, stupid coffee works better then metamusil [17:23] MSG: Quit: ChatZilla 0.9.78.1 [Firefox 2.0.0.7/2007091417] [17:36] k back [17:42] MSG: Quit: Nod_lesh [17:43] Join: Nod_lesh joined #corewars [17:52] MSG: Quit: Trillian (http://www.ceruleanstudios.com [17:56] Join: Core_new joined #corewars [17:56] MSG: Quit: Nod_lesh [18:06] Join: Nod_lesh joined #corewars [18:12] why doesnt mov 0, 2 [18:12] workk [18:13] i cant tell whats wrong with it [18:14] its a normal imp but with a slight mod and it just failsgrrr [18:14] :) [18:14] Hi everybody [18:14] sup fluffer [18:14] * Fluffy kicks Nod_lesh [18:15] ahem, woops:) my bad [18:15] * Nod_lesh feels terrible [18:15] And you should do that ;) [18:16] i'm sure i amyou [18:16] "mov 0,2" doesn't work, because it leaves a gap between the original "mov 0,2" and its copy. BUt unfortunately that gap contains a "dat 0, 0" and the warrior dies [18:20] oh [18:20] :) [18:20] so you can have an gap? [18:21] yes, that's what "mov 0,2" does. It creates a copy of itself 2 instructions away [18:21] a "mov 0,3" would create a larger gap [18:22] right, but why is that a problem? [18:23] Initially the core is filled with "DAT $ 0, $ 0" [18:23] and if you execute that instruction, you warrior (or rather the current process) dies [18:24] i seriosly dont see the diffrence betwin mov 01 and move o3 [18:24] so when you execute a "mov 0,2", it actually is a "mov 0,2" followed by "dat 0,0" and then a "mov 0,2", ... [18:24] and the DAT is executed as the second instruction [18:25] so the process (and in this case the warrior) dies [18:25] so ok,how do i leaves gaps without dieing? [18:25] a "mov 0,1" copies itself to the next instruction, overwriting the "dat 0,0" at the next position [18:26] that way it never executes any dat and runs infinitely [18:26] oooooh [18:26] :) [18:26] fluffy, asl? [18:26] huh? [18:26] what's "asl"? [18:30] found it, took a while to google that [18:30] -,male,- [18:31] its an oldschool irc term [18:31] not even a location [18:31] paranoid [18:31] anyway, that said... i understand what is going on [18:31] ok, how do i make a loop/ [18:31] ? [18:32] what kind of loop do you need? [18:32] a "jmp 0" is the shortest possible loop [18:32] ok [18:32] that was an easy one [18:32] i figured it out as well [18:32] i see [18:32] hmm [18:32] "nop 0,0" and the a "jmp -1" [18:32] *then [18:33] nop = no operation = some kind of placeholder [18:33] it does nothing [18:33] and the "jmp -1" jumps back to the NOP [18:34] ok [18:34] let me ask you this [18:34] wow, i'm actualy getting this [18:34] gimme a minute [18:34] How about 2 minutes? [18:34] ;) [18:36] ok ok ok [18:36] so my goal is to make the other guy get a dat command [18:36] why dont i just start dumping dat statments in a loop from the end of memory (or the other corner) [18:38] that's called a "core clear" [18:38] and is an effective strategy against some kind of warriors [18:38] i.e. stationary ones [18:38] well... [18:38] hmm [18:38] but there are warriors which endlessly create copies of themselves in the core [18:39] and they are hard to kill with a simple coreclear [18:39] well..... [18:39] hmm [18:39] (those warriors are called "papers") [18:40] k [18:40] whats the fastest way to clone? [18:40] there has to be a paralel way to produce ALOT of copies [18:40] unfortunately I have to answer with "depends" [18:40] k do tell [18:41] well, its serial [18:41] ok, here is a question [18:41] MOV 2, @2 [18:42] whats with the @ sign [18:42] @ works a little bit like a table loopkup [18:43] @2 means that I look at position 2 (relative to the current one) and then take the B-field of that instruction as an offset to the real address [18:44] example: [18:44] I execute a "mov 2@2" and 2 instructions further away is a "dat $ 1, $ 10" [18:45] so the @2 "goes" to that "dat $ 1, $ 10" and looks at the B-field [18:45] and finds a 10 [18:45] so the real address is 10 instructions away from the DAT [18:46] ... or 12 instructions away from the MOV [18:46] so a "mov 2, @2" copies something to the location, which is 12 instructions further away [18:47] clear enough? [18:48] gimme a sec here [18:48] :) [18:49] ok hold on [18:49] whats a & [18:49] or $ [18:50] oh i found a list [18:50] :) [18:51] http://vyznev.net/corewar/guide.html might be interesting [18:51] ... and there is no addressing mode "&" [18:52] the $ is usually left out, so a "mov 0,1" is actually a "mov $ 0, $ 1" [18:53] oh [18:53] grr [18:53] ok [18:54] so @number is just an added number to whatever is in the next field [18:54] man, this is complicated [18:54] afk telefphone [18:56] * Fluffy is back [18:56] I don't think that you can define "@" that way [18:57] hmm ... [18:57] "@ number" looks at the B-field of the instruction "number" instructions away [18:58] Let's call that number X [18:58] so in this cas"@ number" refers to the instruction "number + X" instructions away [18:59] *case [18:59] i see [19:00] So you only look at "the next field", if you have "@ 1" [19:01] It needs some time to get used to it [19:02] But with those kind of instruction you can create quite instresting warriors [19:02] *instructions [19:03] and sometimes changing one addressing mode can make the difference between a good and a really good warrior [19:04] At http://vyznev.net/corewar/guide.html you find a warrior called "Dwarf", which is a kind of standard example [19:05] It continously throws "DAT-bombs" to the core [19:05] at every 4th instruction [19:05] and it uses that "@" [19:13] * Fluffy is reading today's logs ... [19:17] So you've been burdened with the task to write a warrior, Nod_lesh :( Poor you! [19:19] hehe [19:20] well, no, since then i called my teacher with the intent of panic [19:20] he told me i dont need to write me from scratch [19:20] simply find one i like and understand how it works [19:20] that doesn't make it easier [19:20] sure it does [19:20] Then I'd suggest to use Neverland :) [19:20] why? [19:20] * Fluffy is looking for the URL ... [19:22] http://www.ociw.edu/~birk/COREWAR/94/HILL/neverland.red [19:22] It is reasonably short, beats most beginner-warriors [19:22] and is "easy" to understand [19:23] ... and if you are bold enough you can switch to Neverland II [19:23] http://www.ociw.edu/~birk/COREWAR/94/HILL/neverland2.red [19:23] which is way better and only one instruction longer [19:24] btw http://www.ociw.edu/~birk/COREWAR/94/hill_rec.html contains tons of warriors [19:24] http://www.ociw.edu/~birk/COREWAR/koenigstuhl.html has even more, but you have to be careful, because it contains lots of warriors for different settings [19:30] hehehe [19:30] neverland beat neverland2 [19:30] funny [19:31] usually you have to run a fight several times to get a statistically sound result [19:34] But if you need a really good warrior try Hullab3loo or Son of Vain. [19:34] easy to understand [19:34] just so we are clear [19:34] There is only the problem that it will take a tiny amount of time to understand them [19:34] to be honest i'm not sure why the files look nothing like the commands [19:34] huh? [19:34] well [19:35] blur equ (align-1)?? [19:35] whats that? [19:35] I see [19:36] to make creating warriors easier pmars (and ares) has some kind of preprocessor [19:36] example [19:36] I can write "value EQU 42" [19:36] that way I defin a constant [19:36] *define [19:37] then a "mov 0, value" is translated by the preprocessor to "mov 0, 42" [19:37] oh [19:37] hmm [19:37] i see [19:38] now you can do the following: [19:38] start_of_warrior: mov 0, value [19:38] jmp start_of_warrior [19:38] the "start_of_warrior" is called a label [19:39] But now the code is far more readable [19:39] at least more readable than: [19:39] mov 0, 42 [19:39] jmp -1 [19:53] Fluffy, you surprise me by being a teacher [19:53] Hi Miz [19:53] I would NEVER do such a thing [19:53] You can't even prove it! [20:00] Time to meat Morpheus ... [20:00] * Fluffy waves [20:00] * Fluffy pretends to be sleeping [20:04] MSG: Quit: Trillian (http://www.ceruleanstudios.com [20:20] MSG: Quit: Ex-Chat [21:14] Join: Caelian joined #corewars [21:17] Join: Core_new joined #corewars