This is a Script for Windows PowerShell. This Script scan your Maps and zip it to .bz2 and upload it in the fastdownload.

07.02.2012
# Scripted by rainbow-six3
#
####### Set Config #####
#
# 7zip Path ONLY 32BIT Version! $7zip = 'C:\Program Files (x86)\7-Zip\'
$7zippath = ''
#
# Fastdownload Path $fdl= 'C:\inetpub\wwwroot\css\'
$fdlpath= ''
#
# CSS Map Path 'C:\Program Files (x86)\CSS\css\cstrike\'
$cspath = ''
#
#######Dont change it#######
####### Log File Path ...\cstrike\MapConverterLog.txt
$logpath = $cspath + 'MapConverterLog.txt'
####### Set Path #####
$mappath = $cspath + 'maps\'
$maplistpath = $cspath + 'maplist.txt'
$mapcyclepath = $cspath + 'mapcycle.txt'
#
####### Get Mapname ######
$mapname = dir $mappath *.bsp -name
#
#
####### Echo ##########
('#################### Counter Strike Map Converter #####################')
('------------------- Found this Maps:----------------')
echo $mapname
('##################')+(' Please Wait... ')+('##################')
('##################################')+(Get-Date –f "yyyy-MM-dd HH:mm:ss")+('##################################')|out-file -Append $logpath;
#
#
$list = 0..($mapname.count-1)
####### Opem 7zip Path ####
cd $7zippath
####### Zip Maps ####
$i = 0
while ($i -ile ($mapname.count-1)){
$split = $mapname[($i)].split(".");
$list[($i)] = ($split[0]);
$split[0] = $split[0] + ".bsp.bz2";
$goal = $fdlpath + $split[0];
$source = $mappath + $mapname[($i)];
if([IO.File]::Exists($goal) -ne $true)
{
.\7z a -tbzip2 -mmt=2 -mx9 $goal -aos $source|out-file -Append $logpath;
}
else
{
echo $source " --> OK"|out-file -Append $logpath;
}
('--------------------------------------------------------------------')|out-file -Append $logpath;
$i++
}
####### Write Maplist.txt and Mapcycle #######
echo $list |out-file $maplistpath;
echo $list |out-file $mapcyclepath;
#
####### Question #########
Write-Host "Finished. Show the Log file. Press any key to exit ..."
$x = $host.UI.RawUI.ReadKey("NoEcho,IncludeKeyDown")
#
#

Proper food is an important part of leading a good lifestyle. But can drugs help us? Many families know that drugs are made to help us, but they can detriment us if taken incorrectly. There are medications intended only for women. Below are some basic reasons about „Over the Counter Anxiety Medicine„. Is it possible to prevent side effects of Viagra? What health care providers talk about „Best over the counter weight loss pills„? Matters, like „Over the Counter Diet Pills„, are united a lot of types of heartiness problems. Usually, having nuisance getting an hard-on can be embarrassing. This physic is for you only. Never give your medicaments to other people even if them symptoms to be the same as yours.

Schreibe einen Kommentar