소스 검색

lpst.pl - we can move a little dude around the board now!!

master
gashapwn 3 년 전
부모
커밋
60550fc47c
1개의 변경된 파일12개의 추가작업 그리고 4개의 파일을 삭제
  1. +12
    -4
      lpst.pl

+ 12
- 4
lpst.pl 파일 보기

@@ -238,7 +238,12 @@ sub disp_2($$){
my ($r0, $c0) = (shift, shift);
my $p;

$p = $board{$r0}{$c0};
# Cell notation
my $not;

$not = cell_index_rev($c0, $r0);

$p = $board{$not};
return f_1($p);
# my ($r0, $c0) = (shift, shift);
@@ -376,6 +381,10 @@ sub disp_board(){
printf("%s", $b);
}

sub cell_index_rev($$){
return $AXIS_RV{$_[0]}.$_[1];
}

sub cell_index($){
my ($chr1, $chr2) = (split(//, $_[0]));
return ($AXIS{$chr1}, $chr2);
@@ -393,11 +402,10 @@ sub cell_index($){
$AXIS_RV{$_}
}(1...11);

$board{"C3"} = $P1.$DIV.$MG_A;
$board{"D2"} = $P1.$DIV.$MG_A;


printf("%s\n", $board{"C3"});
# disp_board();
disp_board();

# disp_0("C1");
# printf(">>%s, %s\n", cell_index("C1"));

불러오는 중...
취소
저장