2015年7月13日月曜日

程式碼部份都移往 github 這邊應該很少動了

github 的連結
不過 舊的程式碼還是放這邊 懶的整理 畢竟很少用
還有在使用的都會在 github 那邊更新

2012年8月11日土曜日

RHash 右鍵選單 REG+VBS

REG 部份:(VBS 的路徑要設定)
Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\*\shell\RHash]

[HKEY_CLASSES_ROOT\*\shell\RHash\command]
@="wscript.exe C:\\portable\\RHash.vbs \"%1\""
VBS 部份:(RHash 主程式的路徑要設定)
Set WshShell = WScript.CreateObject("WScript.Shell")
Dim argument(2)
argument(0) = "C:\portable\RHash-1.2.9-win64\rhash.exe" 'application path
Dim argumentselect
Do
argumentselect = InputBox("1 = MD5" &Chr(10) & _
                          "2 = SHA1" &Chr(10) & _
                          "3 = ED2K" &Chr(10) & _
                          "4 = CHECK" &Chr(10) & _
                          "Select Feature (Other Number=Exit)" , _
                          "Input A Number For Your Choice")
Loop While IsNumeric(argumentselect) = Flase
Select Case argumentselect
Case 1
 argument(1) = "-M"
Case 2
 argument(1) = "-H"
Case 3
 argument(1) = "-E"
Case 4
 argument(1) = "-c"
Case else
 WScript.Quit
End select
argument(2) = WScript.Arguments.Item(0)
Return = WshShell.run("%COMSPEC% /u /k" &Chr(32) &argument(0) _
                                        &Chr(32) &argument(1) _
                                        &Chr(32) &Chr(34) &argument(2) &Chr(34) , 1 , True)

2012年8月5日日曜日

CMD 輸出至 VIM

目錄按右鍵後 會有選單把該目錄檔名輸出至 VIM
Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Directory\shell\Vim(Directory)]

[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Directory\shell\Vim(Directory)\command]
@="\"C:\\Program Files (x86)\\Vim\\vim73\\gvim.exe\" \"+se shellcmdflag=/u/c\" \"+se enc=ucs-2le\" \"+lcd %1\" \"+0read !dir/on\""

Microsoft AppLocale Utility VBS 啟動範本

本來是用登錄檔做成右鍵選單
只是後來覺得雙擊還是比較方便使用

Set WshShell = WScript.CreateObject("WScript.Shell")
Dim argument(2)
argument(0) = "C:\Windows\AppPatch\AppLoc.exe"
argument(1) = "" 'application path(執行程式的完整路徑和檔名)
argument(2) = "" 'taiwan(/L0404),prc(/L0804),japan(/L0411),korea(/L0412) (想要執行的語系)
Return = WshShell.Run(argument(0) &Chr(32) _
                     &argument(1) &Chr(32) _
                     &argument(2) , 1, true)

2012年8月3日金曜日

Avira Free Antivirus (12) Disable Scheduler Service

Version : 12.0.0.1167

Extras -> Configuration
Expert mode -> Selected
General -> Security -> Product protection -> Protect files and registry entries from manipulation -> Not selected

cmd (require admin)
sc config AntiVirSchedulerService start= disabled

then reboot , it will disabled (only supply start , so need reboot)

***

when manual update VDF , require scheduler service

cmd (require admin)
sc config AntiVirSchedulerService start= auto
sc start AntiVirSchedulerService

this step will start scheduler service and can't stop
so when VDF update success , need disable scheduler service start mode and reboot

ps : can use services.msc to change start mode(auto/disabled)

2012年5月13日日曜日

Setting & Check Tool

Set WshShell = WScript.CreateObject("WScript.Shell")
MsgBox "Notice:" &Chr(10) & _
       "" &Chr(10) & _
       "1. Run With Administrator" &Chr(10) & _
       "2. Need Desktop Experience(WS2008R2)" &Chr(10) & _
       "3. Before Use , Please Read Readme" , 0 , "Setting & Check Tool"
Dim regpath(15)
 regpath(0) = "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\"
 regpath(1) = "RegisteredOwner"
 regpath(2) = "RegisteredOrganization"
 regpath(3) = "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\DisableAutoplay"
 regpath(4) = "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System\EnableLUA"
 regpath(5) = "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced\"
 regpath(6) = "Hidden"
 regpath(7) = "HideFileExt"
 regpath(8) = "ShowSuperHidden"
 regpath(9) = "SeparateProcess"
 regpath(10) = "ShowCompColor"
 regpath(11) = "SharingWizardOn"
 regpath(12) = "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced\IconsOnly"
Dim osselect
Do
osselect = InputBox("1 = Setting Windows 7" &Chr(10) & _
                    "2 = Setting Windows Server 2008 R2" &Chr(10) & _
                    "3 = Check Setting" &Chr(10) & _
                    "4 = Misc Setting" &Chr(10) & _
                    "9 = Readme" , _
                    "Select Feature (0=Exit)" , _
                    "Input A Number For Your Choice")
Loop While IsNumeric(osselect) = Flase
Select Case osselect
Case 0
Case 1
 ' Return = WshShell.run("%COMSPEC% /k sc config wscsvc start= disabled" , 1 , True)
 Return = WshShell.run("sc config wscsvc start= disabled" , 1 , True)
 Call sharesetting
Case 2
 Return = WshShell.run("sc config Themes start= auto" , 1 , True)
 Return = WshShell.run("sc config AudioSrv start= auto" , 1 , True)
 Call sharesetting
Case 3
 Call checksetting
Case 4
 Call miscsetting
Case 9
 Call readme
Case else
 MsgBox "Error Select & Exit" , 0 , "Message"
End select

Sub sharesetting
 Return = WshShell.run("sc config WinDefend start= disabled" , 1 , True)
 Return = WshShell.run("sc config MpsSvc start= disabled" , 1 , True)
 WshShell.RegWrite regpath(0) & regpath(1) , "Belldandy" , "REG_SZ"
 WshShell.RegWrite regpath(0) & regpath(2) , "Syaorin" , "REG_SZ"
 WshShell.RegWrite regpath(3) , 1 , "REG_DWORD"
 WshShell.RegWrite regpath(4) , 0 , "REG_DWORD"
 WshShell.RegWrite regpath(5) & regpath(6), 1 , "REG_DWORD"
 WshShell.RegWrite regpath(5) & regpath(7), 0 , "REG_DWORD"
 WshShell.RegWrite regpath(5) & regpath(8), 1 , "REG_DWORD"
 WshShell.RegWrite regpath(5) & regpath(9), 1 , "REG_DWORD"
 WshShell.RegWrite regpath(5) & regpath(10), 0 , "REG_DWORD"
 WshShell.RegWrite regpath(5) & regpath(11), 0 , "REG_DWORD"
 MsgBox "Setting Success" , 0 , "Message"
Exit Sub
End Sub

Sub checksetting
Dim co(15)
 co(0) = WshShell.RegRead(regpath(0) & regpath(1))
 co(1) = WshShell.RegRead(regpath(0) & regpath(2))
 co(2) = WshShell.RegRead(regpath(5) & regpath(6))
 co(3) = WshShell.RegRead(regpath(5) & regpath(7))
 co(4) = WshShell.RegRead(regpath(5) & regpath(8))
 co(5) = WshShell.RegRead(regpath(5) & regpath(9))
 co(6) = WshShell.RegRead(regpath(5) & regpath(10))
 co(7) = WshShell.RegRead(regpath(5) & regpath(11))
If co(2) = 1 And co(3) = 0 And co(4) = 1 And co(5) = 1 And co(6) = 0 And co(7) = 0 Then
 co(8) = "Default Setting"
Else
 co(8) = "Unknow Setting"
End If
strComputer = "."
Set objWMIService = GetObject("winmgmts:\\" & strComputer)
Set colSettings = objWMIService.ExecQuery _
    ("Select * from Win32_ComputerSystem")
For Each objComputer in colSettings
 co(9) = objComputer.Name
 co(10) = objComputer.Workgroup
Next
co(11) = WshShell.RegRead(regpath(3))
If co(11) = 1 Then
 co(12) = "Disabled"
Else
 co(12) = "Enabled"
End If
co(13) = WshShell.RegRead(regpath(4))
If co(13) = 0 Then
 co(14) = "Disabled"
Else
 co(14) = "Enabled"
End If
Set WinDefend = objWMIService.Get("Win32_Service.Name='WinDefend'")
Set MpsSvc = objWMIService.Get("Win32_Service.Name='MpsSvc'")
Dim checkosselect
Do
checkosselect = InputBox("1 = Check Windows 7" &Chr(10) & _
                         "2 = Check Windows Server 2008 R2" , _
                         "Select Feature (0=Exit)" , _
                         "Input A Number For Your Choice")
Loop While IsNumeric(checkosselect) = Flase
Select Case checkosselect
Case 0
Case 1
Set wscsvc = objWMIService.Get("Win32_Service.Name='wscsvc'")
MsgBox "ComputerName = " &co(9) &Chr(10) & _
       "ComputerWorkgroup = " &co(10) &Chr(10) & _
       "RegisteredOwner = " &co(0) &Chr(10) & _
       "RegisteredOrganization = " &co(1) &Chr(10) & _
       "Folder Options Setting = " &co(8) &Chr(10) & _
       "Autoplay = " &co(12) &Chr(10) & _
       "UAC = " &co(14) &Chr(10) & _
       "Security Center : " &wscsvc.State &" , " &wscsvc.StartMode &Chr(10) & _
       "Windows Defender : " &WinDefend.State &" , " &WinDefend.StartMode &Chr(10) & _
       "Windows Firewall : " &MpsSvc.State &" , " &MpsSvc.StartMode  , 0 , "Message"
Case 2
Set Themes = objWMIService.Get("Win32_Service.Name='Themes'")
Set AudioSrv = objWMIService.Get("Win32_Service.Name='AudioSrv'")
MsgBox "ComputerName = " &co(9) &Chr(10) & _
       "ComputerWorkgroup = " &co(10) &Chr(10) & _
       "RegisteredOwner = " &co(0) &Chr(10) & _
       "RegisteredOrganization = " &co(1) &Chr(10) & _
       "Folder Options Setting = " &co(8) &Chr(10) & _
       "Autoplay = " &co(12) &Chr(10) & _
       "UAC = " &co(14) &Chr(10) & _
       "Windows Defender : " &WinDefend.State &" , " &WinDefend.StartMode &Chr(10) & _
       "Windows Firewall : " &MpsSvc.State &" , " &MpsSvc.StartMode &Chr(10) & _
       "Themes : " &Themes.State &" , " &Themes.StartMode &Chr(10) & _
       "Windows Audio : " &AudioSrv.State &" , " &AudioSrv.StartMode , 0 , "Message"
Case else
MsgBox "Error Select & Exit" , 0 , "Message"
End select
Exit Sub
End Sub

Sub miscsetting
Dim response
response = MsgBox("IconsOnly Enable(Yes) or Disable(No)" , 4, "Message")
If response = 6 Then
 WshShell.RegWrite regpath(12) , 1 , "REG_DWORD"
Else
 WshShell.RegWrite regpath(12) , 0 , "REG_DWORD"
End If
Exit Sub
End Sub

Sub readme
MsgBox "Setting Feature:" &Chr(10) & _
       "RegisteredOwner -> Belldandy" &Chr(10) & _
       "RegisteredOrganization -> Syaorin" &Chr(10) & _
       "Folder Option -> Default Setting" &Chr(10) & _
       "AutoPlay -> Disabled" &Chr(10) & _
       "User Account Control -> Disabled" &Chr(10) & _
       "Security Center -> Disabled (Windows 7 Only)" &Chr(10) & _
       "Windows Defender -> Disabled" &Chr(10) & _
       "Windows Firewall -> Disabled" &Chr(10) & _
       "Themes -> Auto (Windows Server 2008 R2 Only)" &Chr(10) & _
       "Windows Audio -> Auto (Windows Server 2008 R2 Only)" &Chr(10) & _
       "" &Chr(10) & _
       "Folder Option(Default Setting):" &Chr(10) & _
       "Control Panel -> Folder Options -> View -> Advanced settings ->" &Chr(10) & _
       "Hidden files and folders -> Show hidden files, folders, and drives" &Chr(10) & _
       "Hide extensions for known file types -> Not selected" &Chr(10) & _
       "Hide protected operating system files (Recommended) -> Not selected" &Chr(10) & _
       "Launch folder windows in a separate process -> Selected" &Chr(10) & _
       "Show encrypted or compressed NTFS files in color -> Not selected" &Chr(10) & _
       "Use Sharing Wizard (Recommended) -> Not selected" , 0 , "Message"
Exit Sub
End Sub

2012年3月29日木曜日

VIM

[2012/05/06 Update]
Homepage:
http://www.vim.org/
Setting:
$VIM/_vimrc
/*
" source $VIMRUNTIME/vimrc_example.vim
" source $VIMRUNTIME/mswin.vim
source $VIM/setting.vim
*/

/etc/vim/vimrc /etc/vim/gvimrc //source /opt/setting.vim

//setting.vim
/*
set nocompatible
if has('win32') || has('win64')
 language english
 set fileformats=dos,unix
elseif has('unix')
 language en_US.UTF-8
 set fileformats=unix,dos
endif
if v:version >= 703
 autocmd InsertEnter * set nocursorcolumn nocursorline relativenumber colorcolumn=
 autocmd InsertLeave * set cursorcolumn cursorline number colorcolumn=40,80
 set colorcolumn=40,80
else
 autocmd InsertEnter * set nocursorcolumn nocursorline
 autocmd InsertLeave * set cursorcolumn cursorline
endif
if has('gui_running')
 autocmd GUIEnter * winpos 0 0
 highlight Normal guibg=black guifg=white
 highlight User1 guibg=white guifg=red
 highlight User2 guibg=white guifg=lightred
 highlight User3 guibg=white guifg=darkred
 set guioptions-=e
 set guioptions-=m
 set guioptions-=T
 set statusline=[%3*%t%*]%1*%m%r%h%w%y%*
 set statusline+=%=
 set statusline+=[%2*%{mode()}%*]
 set statusline+=[%1*%{&enc}%*]
 set statusline+=[%1*%{&fenc}%*(%1*%{&bomb}%*),%1*%{&ff}%*]
 set statusline+=[%2*%l%*,%2*%c%*(%3*%p%*%%/%3*%L%*)]
 if has('win32') || has('win64')
  autocmd InsertEnter * set noimdisable
  autocmd InsertLeave * set imdisable
  set guifont=MingLiU:h14
 elseif has('unix')
  set guifont=WenQuanYi\ Zen\ Hei\ Mono\ 14
 endif
else
 set columns=80 lines=25
 set statusline=[%t]%m%r%h%w%y
 set statusline+=%=
 set statusline+=[%{mode()}]
 set statusline+=[%{&enc}]
 set statusline+=[%{&fenc}(%{&bomb}),%{&ff}]
 set statusline+=[%l,%c(%p%%/%L)]
endif
set autoindent
set autoread
set backspace=indent,eol,start
set clipboard=unnamed
set cursorcolumn
set cursorline
set encoding=utf-8
set fileencoding=utf-8
set fileencodings=utf-8,ucs-bom,taiwan,prc,japan,korea
set foldmethod=indent
set hlsearch
set ignorecase
set incsearch
set laststatus=2
set list
set listchars=tab:>-,eol:<,trail:=
set number
set showcmd
set smartcase
set smartindent
set splitbelow
set splitright
set wrap
syntax enable
set nobackup
set noswapfile
set nowritebackup
*/
Usage:
 [

i I a A s S r R o O //[g]J << >>
v V v //o O [g]u [g]U ~ aw is as r* < >

h j k l
+ -
(e|y)
w W b B [g]e [g]E
f F t T ; ,
'' ``
(o|i) //:ju[mps]
'' '" '[ '] '(a~z|A~Z) //:marks
% () {}
0 $ ^ _
H M L
gg G (gg|G)  *%
(f|b|d|u)
z(t|z|b)
z(o|c|r|R|m|M|n|N|i|j|k)

["(a~z|A~Z|*)](x|X|d|D|dd|c|C|cc|y|Y|yy|(d|c|y)(h|j|k|l))
["(a~z|A~Z|*)][](p|P)
. q(a~z|A~Z) []@(a~z) @@
//:reg[isters]

u r

ggVG

(?|/)(\<|\>|^|$|.) //n N :noh[lsearch]
[g]* [g]#

:[range]s[ubstitute]/{pattern}/{string}/[flags]
//[range] = (1,$|%|.|+-|'*,'*|'<,'>) :
//[flags] = (c|g|i|I|n)
//"\" "+" &
:?^*?,/^*/s={pattern}={string}=[flags]
:g[lobal]/{pattern}/[cmd]

oo

:h[elp]
q:
:opt[ions]

:se[t] all

:q[uit] wq
:clo[se]
:on[ly]
:[range]r[ead] //!
:[range]w[rite]
:sav[eas]

:X :se[t] key=

:sp[lit] ws
:vs[plit]
:new wn
:vne[w]
//w[](w|h|j|k|l|t|b|H|J|K|L|+|-|_|=)

:Exp[lore]
:Tex[plore]
:Sex[plore]
:Vex[plore]

:diffthis
:diffoff
//]c [c :diffu[pdate] :diffg[et] :diffpu[t]

:tabs
:tabe[dit]
:tabc[lose]
:tabo[nly]
:tabn[ext] gt 
:tabp[revious] :tabN[ext] gT 
:tabr[ewind] :tabfir[st]
:tabl[ast]
:tabm[ove]

:e[dit] ++enc=(utf-8|ucs-bom|taiwan|prc|japan|korea)
:se[t] (fileencoding|fenc)=(utf-8|ucs-bom|taiwan|prc|japan|korea)
:se[t] (fileformat|ff)=(dos|unix)
:se[t] (guifont|gfn)=*
清空 register jump mark
Windows 7:
Set WshShell = WScript.CreateObject("WScript.Shell")
Set fso = CreateObject("Scripting.FileSystemObject")
Dim eespath
eespath = WshShell.ExpandEnvironmentStrings("%USERPROFILE%")& _
          "\_viminfo"
If (fso.FileExists(eespath)) Then
 fso.DeleteFile(eespath)
 MsgBox "Find _viminfo & Remove" , 0 , "Message"
Else
 MsgBox "Can't Find _viminfo & Exit" , 0 , "Message"
End If
Linux:
#!/bin/bash
if [ -f ~/.viminfo ] ; then
 rm ~/.viminfo
 echo "Find _viminfo & Remove"
else
 echo "Can't Find _viminfo & Exit"
fi
exit 0

2011年11月29日火曜日

vmware tools 安裝(升級)注意事項

安裝(升級) vmware tools 時
如果 kernel 有更新
編譯時會找不到對應的 header 路徑
造成無法編譯成功
這時要記得安裝對應的 header 即可
apt-get install linux-headers-`uname -r`

另外在虛擬機器安裝 vmware workstation 後
遇到執行後沒反應的情形
執行下列指令後即可
/usr/bin/vmware-config-tools.pl -m

2011年10月12日水曜日

Debian 編譯套件整理

使用 Debian Testing (Stable 有些新套件不支援)
bsnes:
apt-get install build-essential gcc-4.5 g++-4.5 libgtk2.0-dev libqt4-dev libsdl1.2-dev libpulse-dev libopenal-dev libao-dev libxv-dev

desmume:
apt-get install intltool libglade2-dev

wine:
apt-get install flex bison
apt-get install ia32-libs-dev libc6-dev-i386 lib32z1-dev //64bit Only

filezilla:
apt-get install libwxgtk2.8-dev libidn11-dev libgnutls-dev libtinyxml-dev libsqlite3-dev wx-common

truecrypt:
apt-get install nasm libfuse-dev

gimp:
apt-get install libbabl-0.0-0-dev libgegl-0.0-dev libtiff4-dev python2.6-dev python-gtk2-dev

vlc:
apt-get install liblua5.1-0-dev lua5.1 libmad0-dev libavcodec-dev libavformat-dev libswscale-dev libpostproc-dev liba52-0.7.4-dev libxcb-shm0-dev libxcb-xv0-dev libxcb-keysyms1-dev libxcb-randr0-dev libx11-xcb-dev libfribidi-dev libxpm-dev

firestarter:
apt-get install libgnome2-dev libgnomeui-dev

virtualbox:
apt-get install bin86 bcc iasl libxslt1-dev libcurl4-openssl-dev libxmu-dev
apt-get install linux-headers- //uname -r
apt-get install libcap-dev makeself
apt-get install libpam0g-dev g++-multilib texlive-latex-base texlive-latex-recommended texlive-latex-extra texlive-fonts-extra

2011年9月8日木曜日

RagAddress.ini 搜尋更新(2011-08-23aRagexe)

//2011-08-23aRagexe
//CharName=
//Search:esi, [ecx+12E8h]

sub_703680 proc near
push esi
lea esi, [ecx+12E8h]
push edi
mov ecx, 10h
mov edi, offset byte_87BEE0 //CharName=
rep movsd
mov ecx, off_7D64DC
mov esi, ecx
xor eax, eax
sub esi, offset byte_87BEE0 //CharName=
jmp short loc_7036B0
align 10h

loc_7036B0:
movzx edx, byte_87BEE0[esi+eax] //CharName=
xor byte_87BEE0[eax], dl
movzx edx, byte ptr [ecx+eax+1]
xor byte_87BEE1[eax], dl
movzx edx, byte ptr [ecx+eax+2]
xor byte_87BEE2[eax], dl
movzx edx, byte ptr [ecx+eax+3]
xor byte_87BEE3[eax], dl
add eax, 4
cmp eax, 40h
jb short loc_7036B0
pop edi
mov eax, offset byte_87BEE0
pop esi
retn
sub_703680 endp

align 10h

//Zeny=
//BaseExp=
//BaseExpNext=
//JobExp=
//JobExpNext=
//Search:mov ecx, [esp+58h+var_10]

loc_689B95:
mov [esp+6Ch+var_4], 0FFFFFFFFh
lea ecx, [esp+6Ch+var_2C]
call //此行有點問題 貼不上來
mov ecx, [esp+6Ch+var_C]
mov large fs:0, ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, [esp+58h+var_10]
xor ecx, esp
call sub_722AB8
add esp, 58h
retn 4
sub_6891C0 endp

off_689BC8 dd offset loc_68922F
dd offset loc_689253
dd offset loc_68926B
dd offset loc_689344
dd offset loc_68941D
dd offset loc_689459
dd offset loc_68946C
dd offset loc_68947F
dd offset loc_6894BA
dd offset loc_6896A2
dd offset loc_6896C3
dd offset loc_6896DB
dd offset loc_6896F3
dd offset loc_68970A
dd offset loc_689722
dd offset loc_68973A
dd offset loc_689751
dd offset loc_6898CE
dd offset loc_6899D0
dd offset loc_6899E8
dd offset loc_689A00
dd offset loc_689A17
dd offset loc_689A2F
dd offset loc_689A47
dd offset loc_689A5E
dd offset loc_689A76
dd offset loc_689A8E
dd offset loc_689AA5
dd offset loc_689ABD
dd offset loc_689AD5
dd offset loc_689AEC
dd offset loc_689B04
dd offset loc_689B19
dd offset loc_689327
dd offset loc_689B95
byte_689C54 db 0
db 2 dup(22h), 1
dd 5040302h, 8220706h, 0C0B0A09h, 220F0E0Dh
dd 22222222h, 22221110h, 3 dup(22222222h)
dd 14131222h, 18171615h, 1C1B1A19h, 201F1E1Dh
dd 22222222h, 498D21h
off_689C94 dd offset loc_689570
dd offset loc_6895AB
byte_689C9C db 0
align 10h
dword_689CA0 dd 0CC010101h, 3 dup(0CCCCCCCCh), 104EC81h
dd 0C0A10000h, 33007DCCh, 248489C4h, 100h
dd 24BC8B57h, 10Ch, 247B70Fh, 16F88348h
dd 0D5870Fh, 0B60F0000h, 689DE080h, 8524FF00h
dd 689DC8h, 18B9026Ah, 0E80087DDh, 55FFCh
dd 5D74C085h, 5304478Bh, 0FCAC1D8Bh, 8B560087h
dd 85F32BF0h, 854874C0h, 554474F6h, 0FCB82D8Bh
dd 0C88B0087h, 0C32BC58Bh, 50FEF799h, 0CB2B5155h
dd 244C8D51h, 6C886820h, 0FF510078h, 75637815h
dd 18C48300h, 6A006Ah, 0F51EF568h, 24548D00h
dd 16A521Ch, 819078B9h, 5EDEE800h, 5E5DFFE9h
dd 4478B5Bh, 87FCACA3h, 8B46EB00h, 0D89044Fh //BaseExp=87F***
dd 87FD68h, 0B9833BEBh, 11Ch, 0C7147400h //JobExp=87F***
dd 11C81h, 0
add byte ptr dword_87DD18[ecx], bh
call sub_6F1A70
mov edx, [edi+4]
mov dword_87FD54, edx //Zeny=
jmp short loc_689DA5

loc_689D92:
mov eax, [edi+4]
mov dword_87FCB8, eax //BaseExpNext=
jmp short loc_689DA5

loc_689D9C:
mov ecx, [edi+4]
mov dword_87FD64, ecx //JobExpNext=


//Weight=
//WeightMax=
//Search:; "Weight : %3d / %3d"

loc_494BB4:  ; "Weight : %3d / %3d"
push offset aWeight3d3d

loc_494BB9:  ; char *
push edx
call ebx ; sprintf
mov eax, dword_8797C0 //WeightMax=
add esp, 10h
xor edi, edi
cmp eax, 1
mov ecx, eax
jg short loc_494BD2
mov ecx, 1

loc_494BD2:
mov eax, dword_8797CC //Weight=
imul eax, 64h
cdq
idiv ecx
cmp eax, 32h
jl short loc_494BE7
mov edi, 0FFh

//BaseLv=
//JobLv=
//Search:; "Base Lv. %d"
//Search:; "Job Lv. %d"

loc_494A8B:
mov eax, dword_879710 //BaseLv=
push eax
push offset aBaseLv_D ; "Base Lv. %d"
lea ecx, [esp+2Ch]
push ecx  ; char *

loc_494ADB:
mov eax, dword_87971C //JobLv=
push eax
push offset aJobLv_D ; "Job Lv. %d"
lea ecx, [esp+2Ch]
push ecx  ; char *

//HPIndex=
//MaxHPTable=
//Search:
HPIndex & MaxHPTable 似乎是無解
使用 WinHex 和之前版本比較 似乎整個被拿掉了
不過 這 2 個並不影響 Exp 效率的計算
只是不能自動喝水了

2011年7月29日金曜日

Comodo Internet Security 防火牆設定

Xmanager:
http://www.netsarang.com/faq/xmanager/3160/title
根據這個 FAQ 必需開啟以下 PORT
TCP(IN) : 6000~6010 16001(GNOME)
UDP(OUT) : 177

首先把 Xmanager 的主程式加入信任程式
開啟 CIS 後 選 Firewall 的部份
按 Define a New Trusted Application 把主程式加入(Select -> Browse...)
然後在 Network Security Policy 裡 找到 Xmanager
按右鍵 選擇 Edit
這時 Network Access Rules 應該是 Use a Custom Policy
規則裡會有一個 Allow All Requests
按左下角的 Add... 來加入我們需要的規則
UDP(OUT) :
Action: -> Allow
Protocol: -> UDP
Direction: -> Out
Destination Port -> Type: -> A Single Port
Port: -> 177
TCP(IN) :
這邊因為要開啟的 PORT 比較多
所以 先到 Network Security Policy 裡的 Port Sets
按 ADD... -> A New Port Set... 名字我輸入 XDMCP
然後 XDMCP 按右鍵 選 Add...
A Single Port -> 16001
A port range -> 6000 - 6010
完成這些後
按照 UDP(OUT) 的方法加入規則
Action: -> Allow
Protocol: -> TCP
Direction: -> In
Source Port -> Type: -> A Set of Ports
Ports: -> XDMCP
這樣就設定完成

開啟 PORT 113 (巴哈姆特):
Network Security Policy 裡按 Add...(記得先取消選擇程式 不然只是在那個程式內加規則)
Application Path: Select -> Running Processes
選擇 Windows Operating System
然後加入兩個規則
Action: -> Allow
Protocol: -> TCP
Direction: -> Out
Destination Address -> Type: -> IPv4 Single Address
IP: -> 60.199.217.88
Source Port -> Type: -> A Single Port
Port: -> 113

Action: -> Allow
Protocol: -> TCP
Direction: -> In
Source Address -> Type: -> IPv4 Single Address
IP: -> 60.199.217.88
Destination Port -> Type: -> A Single Port
Port: -> 113
這樣子就設定完成

附註: 60.199.217.88 這個是巴哈姆特的 IP 如果將來有更改的話 也要隨之變更
參考資料: http://webbbs.gamer.com.tw/readPost.php?brd=protect_PC&p=1579&x=A15V6QCM

2011年6月16日木曜日

Debian 開機問題

版本 : debian-6.0.1a-i386-DVD-1.iso
安裝完後 更新成 testing
開機時 有時會出現這問題 重開機就會正常(次數不定)

2011年6月8日水曜日

RO 配點整理(官服調整版)

[2012/07/27 Update]
Arc Bishop
STR 1 ; AGI 82 ; VIT 95 ; INT 82 ; DEX 84 ; LUK 100
(JOB50加成值:STR+5、AGI+4、VIT+5、INT+8、DEX+6、LUK+0)
http://uniuni.dfz.jp/skill4/acb.html?20gXdNsXdAhFbqroqnqEHnjScAkBabkbdsrEoscHcY
http://uniuni.dfz.jp/skill4/acb.html?20gXdNsXdAhEbdlbqnkeHnjN1kBabkbdsrEoscHcY (Baby)


Sorcerer
STR 1 ; AGI 84 ; VIT 95 ; INT 120 ; DEX 83 ; LUK 1
(JOB50加成值:STR+3、AGI+3、VIT+5、INT+10、DEX+7、LUK+3)
http://uniuni.dfz.jp/skill4/soe.html?10qoAnfkeKcoebaFrEkElarAjNabdnafrAbslfhqaAdn1cHcY


Warlock
STR 1 ; AGI 82 ; VIT 96 ; INT 120 ; DEX 84 ; LUK 1
(JOB50加成值:STR+1、AGI+5、VIT+4、INT+11、DEX+6、LUK+1)
http://uniuni.dfz.jp/skill4/wlk.html?10qneAoXfkdDcBHneKgKcAapdAeAbsbsaOefqocHcY


Wanderer
STR 1 ; AGI 82 ; VIT 95 ; INT 82 ; DEX 84 ; LUK 100
(JOB50加成值:STR+2、AGI+8、VIT+5、INT+8、DEX+6、LUK+0)
http://uniuni.dfz.jp/skill4/wan.html?10FXJkrAJkGO2b2nbxrA2orA6kwY


Soul Linker
STR 90 ; AGI 83 ; VIT 44 ; INT 1 ; DEX 38 ; LUK 1
(JOB50加成值:STR+0、AGI+0、VIT+6、INT+12、DEX+12、LUK+0)
http://uniuni.dfz.jp/skill4/slk.html?10GA3fhyhqndndnasdA1bQ4k


Genetic
STR 99 ; AGI 1 ; VIT 1 ; INT 99 ; DEX 1 ; LUK 1
(JOB50加成值:STR+1、AGI+5、VIT+4、INT+11、DEX+6、LUK+1)
http://uniuni.dfz.jp/skill4/gnt.html?10JbGKAfuSrArFqBdsGA91In


Glt. Cross
STR 110 ; AGI 110 ; VIT 95 ; INT 1 ; DEX 73 ; LUK 1
(JOB50加成值:STR+6、AGI+7、VIT+5、INT+4、DEX+7、LUK+0)
http://uniuni.dfz.jp/skill4/glx.html?10GXjkIbHNsNboGS1cBqA2fakwY

2011年5月17日火曜日

AHK(RO 自動 Encore & Frost Misty & Jack Frost ; 可背景執行 目前只適合單視窗)

[2011/05/18 Update]
Encore:
Pause //暫停
IfWinExist,Ragnarok //檢查 RO 視窗是否存在
{
Loop //迴圈
{
 Loop,4 //迴圈 4 次
 {
 IfWinActive,Ragnarok //如果選擇的視窗是 RO
 {
  Send {F4} //送出按鍵(可以變更)
 }
 IfWinNotActive,Ragnarok //如果選擇的視窗不是 RO(背景執行用)
 {
  ControlSend,,{F4},Ragnarok //背景送出按鍵給 RO(可以變更)
 }
 Sleep, 250 //停止 0.25 秒
 }
 Sleep, 180000 //停止 180 秒
 Sleep, 5000 //停止 5秒
}
}
^Home::Pause //設定 Ctrl+Home 暫停 or 關閉暫停
^End::Reload //設定 Ctrl+End 重置(重置後 預設是暫停 要按 Ctrl+Home 開始)
             //使用暫停並不會使 Sleep 的計時重置 故加入此鍵
             //沒有先使用詩舞技能就使用 Encore 的話 會沒反應 此時也必需重置
Frost Misty & Jack Frost:
Pause
IfWinExist,Ragnarok
{
Loop
{
 Loop,2 //送 2 次是怕 LAG(約 1~3 次 JF 會 1次 FM)
 {
 IfWinActive,Ragnarok
 {
  Send {F7} //Frost Misty
 }
 IfWinNotActive,Ragnarok
 {
  ControlSend,,{F7},Ragnarok //建議使用 F1~F9(背景執行時 比較不會有問題)
 }
 Sleep, 250
 }
 Loop,2 //送 2 次是怕 LAG(約 1~3 次 JF 會 1次 FM)
 {
 IfWinActive,Ragnarok
 {
  Send {F9} //Jack Frost
 }
 IfWinNotActive,Ragnarok
 {
  ControlSend,,{F9},Ragnarok //建議使用 F1~F9(背景執行時 比較不會有問題)
 }
 Sleep, 250
 }
}
}
^Home::Pause
^End::Reload
官網:http://www.autohotkey.com/
複制上面的程式碼
然後用 AutoHotKey 編譯即可使用

2011年5月14日土曜日

Flash Player 10.3 (Debian)

10.3 版似乎沒有提供 deb 安裝檔
下載 (.tar.gz) 版本
解壓縮後 把 libflashplayer.so 複制到 /usr/lib/mozilla/plugins 即可(使用 Firefox 4)

裡面有附設定程式 安裝測試後
個人覺得似乎不需要安裝(需要的話 可以參考內附的說明檔安裝)

要注意的是 有安裝其它版的話
在 Firefox 的設定裡要將它關閉
不然似乎會使用舊版的播放

2011年5月10日火曜日

Debian 圖形遠端連線

vim /etc/gdm3/daemon.conf // 在 xdmcp 下加入 Enable=true 即可
/*
[xdmcp]
Enable=true
*/

目前是使用這套 XWinLogon Windows X Server (Windows)
官網 : http://www.calcmaster.net/visual-c++/xwinlogon/
不過 畫面上的效能還不是很理想
做一些簡單的設定是沒問題
所以還是使用 ssh 比較多

2011年5月9日月曜日

IDA Pro 簡易教學

使用軟體 : IDA Pro 5.0 Freeware Version
官網 : http://www.hex-rays.com/
主程式
開啟檔案(選 Portable 其它使用預設值就好)
載入程式中 需要其它的 DLL(可以略過 按 Cancel)
這邊按 Yes(這邊我不知道怎麼解釋比較好 照預設選 Yes 就好)
等待分析完成後
File -> Product file -> Create ASM File... ALT+F10
這個是分析還沒完成就選輸出的情形 請按 No 等待分析完成
(這邊要等約 10~15 分)
分析完成
正在輸出

使用這個軟體
所得到的 ASM 檔
能用來搜尋 RagAddress.ini 所需要的位址

2011年5月7日土曜日

RagAddress.ini 教學(使用 IDA PRO)

[2011/10/30 Update]
//2011-10-19aRagexe
//CharName=
//Search:esi, [ecx+12E8h]

sub_703680 proc near
push esi
lea esi, [ecx+12E8h]
push edi
mov ecx, 10h
mov edi, offset byte_87BEE0 //CharName=
rep movsd
mov ecx, off_7D64DC
mov esi, ecx
xor eax, eax
sub esi, offset byte_87BEE0 //CharName=
jmp short loc_7036B0
align 10h

loc_7036B0:
movzx edx, byte_87BEE0[esi+eax] //CharName=
xor byte_87BEE0[eax], dl
movzx edx, byte ptr [ecx+eax+1]
xor byte_87BEE1[eax], dl
movzx edx, byte ptr [ecx+eax+2]
xor byte_87BEE2[eax], dl
movzx edx, byte ptr [ecx+eax+3]
xor byte_87BEE3[eax], dl
add eax, 4
cmp eax, 40h
jb short loc_7036B0
pop edi
mov eax, offset byte_87BEE0
pop esi
retn
sub_703680 endp

align 10h

//Zeny=
//BaseExp=
//BaseExpNext=
//JobExp=
//JobExpNext=
//Search:mov ecx, [esp+58h+var_10]

loc_691EB9:
mov [esp+6Ch+var_4], 0FFFFFFFFh
lea ecx, [esp+6Ch+var_2C]
call ds: //此行過長省略
mov ecx, [esp+6Ch+var_C]
mov large fs:0, ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, [esp+58h+var_10]
xor ecx, esp
call sub_72D078
add esp, 58h
retn 4
sub_6914E0 endp

off_691EEC dd offset loc_69154F
dd offset loc_691573
dd offset loc_69158B
dd offset loc_691668
dd offset loc_691741
dd offset loc_69177D
dd offset loc_691790
dd offset loc_6917A3
dd offset loc_6917DE
dd offset loc_6919C6
dd offset loc_6919E7
dd offset loc_6919FF
dd offset loc_691A17
dd offset loc_691A2E
dd offset loc_691A46
dd offset loc_691A5E
dd offset loc_691A75
dd offset loc_691BF2
dd offset loc_691CF4
dd offset loc_691D0C
dd offset loc_691D24
dd offset loc_691D3B
dd offset loc_691D53
dd offset loc_691D6B
dd offset loc_691D82
dd offset loc_691D9A
dd offset loc_691DB2
dd offset loc_691DC9
dd offset loc_691DE1
dd offset loc_691DF9
dd offset loc_691E10
dd offset loc_691E28
dd offset loc_691E3D
dd offset loc_69164B
dd offset loc_691EB9
byte_691F78 db 0
db 2 dup(22h), 1
dd 5040302h, 8220706h, 0C0B0A09h, 220F0E0Dh
dd 22222222h, 22221110h, 3 dup(22222222h)
dd 14131222h, 18171615h, 1C1B1A19h, 201F1E1Dh
dd 22222222h, 498D21h
off_691FB8 dd offset loc_691894
dd offset loc_6918CF
byte_691FC0 db 0
align 4
dd 0CC010101h, 2 dup(0CCCCCCCCh)



sub_691FD0 proc near

var_104= byte ptr -104h
var_4= dword ptr -4
arg_0= dword ptr  4

sub esp, 104h
mov eax, dword_7EA140
xor eax, esp
mov [esp+104h+var_4], eax
push edi
mov edi, [esp+108h+arg_0]
movzx eax, word ptr [edi+2]
dec eax
cmp eax, 16h
ja loc_6920CF
movzx eax, ds:byte_692100[eax]
jmp ds:off_6920E8[eax*4]

loc_692008:
push 2
mov ecx, offset dword_88B1C0
call sub_6EA150
test eax, eax
jz short loc_692075
mov eax, [edi+4]
push ebx
mov ebx, dword_88D0F4
push esi
mov esi, eax
sub esi, ebx
test eax, eax
jz short loc_692073
test esi, esi
jz short loc_692073
push ebp
mov ebp, dword_88D100
mov ecx, eax
mov eax, ebp
sub eax, ebx
cdq
idiv esi
push eax
push ebp
push ecx
sub ecx, ebx
push ecx
lea ecx, [esp+124h+var_104]
push offset aDDDMoreD ; "%d : %d/%d More : %d"
push ecx  ; char *
call ds:sprintf
add esp, 18h
push 0
push 0
push 0F51EF5h
lea edx, [esp+120h+var_104]
push edx
push 1
mov ecx, offset unk_8264F8
call sub_5213D0
pop ebp

loc_692073:
pop esi
pop ebx

loc_692075:
mov eax, [edi+4]
mov dword_88D0F4, eax //BaseExp=
jmp short loc_6920C5

loc_69207F:
mov ecx, [edi+4]
mov dword_88D1B0, ecx //JobExp=
jmp short loc_6920C5

loc_69208A:
cmp dword ptr [ecx+11Ch], 0
jz short loc_6920A7
mov dword ptr [ecx+11Ch], 0
mov ecx, offset dword_88B1C0
call sub_6FC280

loc_6920A7:
mov edx, [edi+4]
mov dword_88D19C, edx //Zeny=
jmp short loc_6920C5

loc_6920B2:
mov eax, [edi+4]
mov dword_88D100, eax //BaseExpNext=
jmp short loc_6920C5

loc_6920BC:
mov ecx, [edi+4]
mov dword_88D1AC, ecx //JobExpNext=

//Weight=
//WeightMax=
//Search:; "Weight : %3d / %3d"

loc_494BB4:  ; "Weight : %3d / %3d"
push offset aWeight3d3d

loc_494BB9:  ; char *
push edx
call ebx ; sprintf
mov eax, dword_8797C0 //WeightMax=
add esp, 10h
xor edi, edi
cmp eax, 1
mov ecx, eax
jg short loc_494BD2
mov ecx, 1

loc_494BD2:
mov eax, dword_8797CC //Weight=
imul eax, 64h
cdq
idiv ecx
cmp eax, 32h
jl short loc_494BE7
mov edi, 0FFh

//BaseLv=
//JobLv=
//Search:; "Base Lv. %d"
//Search:; "Job Lv. %d"

loc_494A8B:
mov eax, dword_879710 //BaseLv=
push eax
push offset aBaseLv_D ; "Base Lv. %d"
lea ecx, [esp+2Ch]
push ecx  ; char *

loc_494ADB:
mov eax, dword_87971C //JobLv=
push eax
push offset aJobLv_D ; "Job Lv. %d"
lea ecx, [esp+2Ch]
push ecx  ; char *

//HPIndex=
//MaxHPTable=
//Search: