Check out Grant Acedrex, our featured variant for April, 2024.


[ Help | Earliest Comments | Latest Comments ]
[ List All Subjects of Discussion | Create New Subject of Discussion ]
[ List Earliest Comments Only For Pages | Games | Rated Pages | Rated Games | Subjects of Discussion ]

Single Comment

Chess piece names with period in them[Subject Thread] [Add Response]
wdtr2 wrote on Tue, Jul 21, 2020 10:14 PM UTC:

if fn friend $moved:
   set msg join join $moved #codename " is friend";
   echo #msg;
elseif fn enemy $moved:
   set msg join join $moved #codename " is enemy ";
   echo #msg;
else:
   set msg join join join $moved #codename " is not friend or foe " $moved;
   echo #msg;
endif;

I need advice on programming.  I have a piece that is .rf,  it appears to me the function friend / enemy is not working.  That function friend is using isupper or islower.  I am guessing that the Period in .rf prevents the function friend to determine if it islower.   

Any suggestions how I can add .rf to the function friend?