so I have this warrior...

G

Guest

Guest
Archived from groups: rec.games.corewar (More info?)

A couple of years ago I heard about this intriguing little subculture
and decided to try my hand at coding a warrior. About a month later I
produced this warrior, rather unimaginatively called Imp Factory. Since
I'm a big believer in open source, I'm releasing this warrior under the
GPL. ;-)

=========================================================
;name Imp Factory
;author Will Berry (wberry@wberry.org.x)
;license GNU General Public License
;strategy Spit out Imps relentlessly!

;assert 1
; but works best when gcd(coresize, scatter) is small
scatter equ 5
org start

; copy the Imp code to the new location, spawn a thread, repeat
; the first Imp will spawn at address imp
start: add.ab #scatter, 2
mul.a #scatter, -1
mov.i imp, imp - scatter
spl @-1
jmp start
imp: mov imp, 1
=========================================================

I put this warrior into the arena versus several of the evolved warriors
that came packaged with the graphical engine from
http://corewars.sourceforge.net/. Under the scoring criteria this
engine uses by default, which favors code coverage to "kills", this
warrior (in aggregate) beat the pants off everything I put it up
against, except in very small cores. Obviously it is a poor gladiator
because it never writes any DAT instructions.

But my questions are:

1) Is this warrior actually an original concept in any way, or is it a
re-implementation of some old hack?

2) Is anybody willing to post some anti-imp warriors that I can try out?

--
Will Berry
Director of Operations, Techwood Con gaming convention
http://www.techwoodcon.com/
 
Archived from groups: rec.games.corewar (More info?)

A) Idea may not be so original because there are already imppumps
which i think are more powerful and versatile.

;redcode-x2
;name Imp Pump 3
;author x
;assert 1

size equ (CORESIZE+1)/3
size2 equ size+1

pump spl 0,0
add.a #size+1,2
mov imp,>1
jmp imp-2*size2,1
imp mov 0,size


B) Anti-imp? Try HSA below. Should beat Imp to death in a very short
time!!

;redcode-94
;name He Scans Alone
;author P.Kline
;assert CORESIZE == 8000
;strategy 80% f-scanner switches from SPL to DAT carpet

tPtr dat 100 ,4100-4 ; widely-spaced pointers
dat 0,0
dat 0,0
dat 0,0
dat 0,0
dat 0,0

tWipe mov tSpl ,<tPtr ; positive wipe of opponent
mov >tPtr ,>tPtr
jmn.f tWipe ,>tPtr

tScan sub.x #-12 ,tPtr ; increment and look
sne *tPtr ,@tPtr
sub.x *pScan ,@tScan ; increment and look
jmn.f tSelf ,@tPtr
jmz.f tScan ,*tPtr
pScan mov.x @tScan ,@tScan ; swap pointers for attack
tSelf slt.b @tScan ,#tEnd+4-tPtr ; self-check
djn tWipe ,@tScan ; go to attack
djn *pScan ,#13 ; after 13 self-scans
jmp *pScan ,}tWipe ; switch to dat-wiping
dat 0,0
tSpl spl #1,{1
dat 0,0
dat 0,0
tEnd dat 0,0
for 61
dat 0,0
rof
tDecoy equ (tWipe+1-1196)
tStart mov <tDecoy+0,{tDecoy+2 ; make a quick-decoy
mov <tDecoy+3,{tDecoy+5 ; to foil one-shots
mov <tDecoy+6,{tDecoy+8 ; and the occasional q-scan
djn.f tScan+1 ,<tDecoy+10

end tStart
 
Archived from groups: rec.games.corewar (More info?)

Zul Nadzri wrote:
> A) Idea may not be so original because there are already imppumps
> which i think are more powerful and versatile.
>
> ;name Imp Pump 3

I am not surprised that the warrior I wrote is but one individual in a
named species; I just never saw another one before. I'm sort of new to
the whole thing...

But this specimen is quite beautiful. I'll have to remember the spl 0,0
trick. It could come in handy.


> ;name He Scans Alone

This one will require some thought before I can understand it. But
thanks; this will renew my interest in the sport, since I have more to
challenge me.


--
Will Berry
Director of Operations, Techwood Con gaming convention
http://www.techwoodcon.com/