With using terminal for a long time, PATH variable tends to be longer and longer due to duplicated path.
Here is simple sample script - with Perl - to resolve this.

# remove duplication at give PATH-format-string
unique_path() {
perl -w -e '
    my %path_hash;
    exit unless (defined $ARGV[0]);
    foreach $p (split (/\:/, $ARGV[0])) {
        unless (defined $path_hash{$p}) {
            $path_hash{$p} = 1;
            push @newpath, $p;
        }
    }
    print join ":", @newpath;
' $1
}
...(skip)...
PATH=$(unique_path "$PATH")
...(skip)

Done :-).

Most Android device is 32bit machine. So, many application assumes that host machine is 32bit system.
And in general, there is no difference developing Android-natvie-library between 64bit and 32bit build machine.

But, here is usual step for developing Android-native-library.
(1) Developing and verifying code at build machine.
(2) Porting to NDK build system.

Most developers turns on full-warning-option at compile to detect bugs at early stage.
But, building and verifying codes assuming 32bit host machine at 64bit machine always issues type casting warning due to different type size.
Especially, between pointer and integer.

For example, many Android JAVA application uses int - jint - as a type to contain native pointer with assumption of 32bit-host-system.
Building this code at 64bit build system to verify code issues type casting warning, even if code itself is built perfectly at NDK build system.
And it is worse that this code doesn't work at 64bit Android host machine, even though it is not popular.

To reduce this warnings (for easy-verifying of library code at build machine), in my opinion, using long - jlong - instead of jint as a type for containing native pointer is better unless memory space is extremely critical.
And to make compiler be happy, using macro can be a good choice.
Here is example of macro for type-casting between pointer and integer - jlong.
(This sample works well without warning at 32bit/64bit build/host system).

#define ptr2jlong(v) ((jlong)((intptr_t)(v)))
#define jlong2ptr(v) ((void*)((intptr_t)(v)))

This is just simple example for portability issues.
Making portable code is always very difficult...

상당히 유명한 게임이라고 하기에, PC버젼으로 나온 1편을 플레이 해봤다. 사실 집에 PC가 워낙 오래된 것이라 (이제 만으로 7년정도 된거 같군...-_-;) 약간만 사양이 높아도 돌리지도 못한다...
일단 일러스트를 보면 왠지모르게 굉장히 익숙한 느낌! 바로 랑그릿사의 우루시하라 사토시! 그가 일러스트를 맡았다고 한다.
뭐 그림이야기는 그렇고... 게임은...
스토리... 괜찮고, 일러스트... 당연히 괜찮고, 완성도... 이 정도면 뭐...
그런데... 문제는... encounter시 전투에 시간이 너무 오래 걸린다는 점... 특히 마법은 effect때문에.. 너무 많은 시간을 소모해서 집중력을 확~~ 떨어뜨려 버린다.
그래서... 한번 clear하고 나면 다시 하고 싶은 생각은 별로 들지 않는다.
또, 마법과 물리 공격간에 밸런스가 약간 무너져서... 마법이 없이는 아무것도 할 수 없는 것도 약간은 아쉬움이라고 할까...
(물약으로 버티는 전사파티의 로망은 불가능하다...-_-;)
그럼에도 불구하고, 각 캐릭터의 개성이 확실하고, 기타 요소들이 괜찮아서 상당히 잘 만든 게임임에는 틀림없는 것 같다.
그렇지만... 역시 훼자리안 던전의 잔인함은.. 짜증.. 지대루다..-_-;

'Essay > Review' 카테고리의 다른 글

[Review][Game] 총망라...  (0) 2011.11.23
[Review] 삼국군영전5  (0) 2011.11.23
[Review] Extreme Programming Explained 2/E  (0) 2011.08.05
[Review] Kingdom Under Fire - Gold Edition  (1) 2011.08.05
[Review] Numb3rs (넘버즈)  (0) 2011.07.06

+ Recent posts