Ubuntu Blog – Latest informations

Just another WordPress.com site

A little script i did

– Urban Terror ForumsJump to content

Urban Terror Forums Player, Mapper & Dev community     news docs passport forums | video    Login | Register  RSS Feed HomeUrT Forums

RSS Feed Top pageRSS Feed Forum Guidelinesnote Active Contentnote Mark Board As ReadRSS Feed RSS feedsForums Search

find Advanced SearchSearchForums Users

Forums Staff –>staff Forums Staffmembers Passport Memberstoday posters Today PostersShare This Page

external_facebook external_twitter email external_sharethis Morecommunities

ar br cl co fr de it jp mx pl pt ro ru es tr uy veInfo & Contact

page_white_go Downloadshelp F.A.Q.book Manualemail Contact usHelp UrT

coins_add Donate Forums> URBAN TERROR TECHNICAL SUPPORT> Server Setup and SupportPage 1 of 1You cannot start a new topicYou cannot reply to this topicRate Topic:-----map list generator (inspired by vindimy)#1User is offline   johnbunny Iconnewbie playerPassport:johnbunnyJoined:12-May 10Posts:7Posted 10 October 2010 – 10:52 AM

Hi all!
This is a little script i use to make maplists for local servers, widely inspired by another one posted here:

http://forums.urbant…reate-map-list/

I use this one because i often host offline lan games with friends in my garage, so i cannot access internet and use the php page proposed by vindimy.
I added instructions at the end of the cfg file and listing variables to make it easy to remember the maps in the active list!
This is linux bash so it works only for linux!

I find it very handy, let me know what u think!

#!/bin/bash# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # ####Urban Terror map list generator#### # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # ## Inspired by: vindimy (old) [http://oa.thedimi.net/tools/maplist-generator.php]## Made by: John_Bunny## Freely distributable under GPL license## This script generates map lists to use on local servers.# usage: $./generlist.sh output.cfg ut4_map1 ut4_map2 ut4_map3## The output.cfg file contains the map list and a couple of# variables to print map list as bigtext or echoif [ $# -lt 3 ]; then#not enough argumentsecho “Needed at least 3 aguments!”echo “Usage: ./generlist.sh output.cfg ut4_map1 ut4_map2 …”else#charge array of mapnamesargs=(“$@”)filename=${args[0]}number=1succ=2#create fileecho “//List file generated by generlist.sh by John_Bunny” > $filenameecho “//inspired by: vindimy (old) [http://oa.thedimi.net/tools/maplist-generator.php]” >> $filenameecho “” >> $filename#generate list variablespublic=”set publist \”bigtext “private=”set privlist \”ut_echo “counter=0for (( i=1;i> $filenameecho $private >> $filenameecho “” >> $filename#generate cycling variablesfor (( i=1;i> $filenamelet number=$number+1let succ=$succ+1done#generate loopecho “set M$number \”vstr M1\”” >> $filename#make game start with map1echo “wait” >> $filenameecho “vstr M1” >> $filenameecho “” >> $filename#usage helpecho “// type \”exec $filename\” in console to start with first map” >> $filenameecho “// type \”vstr publist\” in console to print bigtext list” >> $filenameecho “// type \”vstr privlist\” in console to print local list (nice reminder)” >> $filenameecho “// type \”vstr nextmap\” in console to switch to the next map” >> $filenameecho “// you can also bind keys for this actions by adding lines to autoexec.cfg like:” >> $filenameecho “// bind F10 \”vstr nextmap\”” >> $filename#confirmation outputecho “$filename created!”fi
Back to top of the page up there ^Reply Icon MultiQuoteReply Icon Reply –> #2User is offline   Zamy Iconnewbie playerPassport:zamyCountry:Joined:01-March 10Posts:28Posted Yesterday, 06:59 PM

It will be more useful if it can generate a list of the maps in a plain text (as mapcycle.txt), not only a cfg to switch locally a map :smile:
This post has been edited by Zamy: Yesterday, 07:03 PM

Back to top of the page up there ^Reply Icon MultiQuoteReply Icon Reply –>#3User is offline   johnbunny Iconnewbie playerPassport:johnbunnyJoined:12-May 10Posts:7Posted Yesterday, 07:28 PM

Are you kidding me?
To generate a mapcycle file you just have to write down your fav maps on the text file, you can do it in seconds. What’s the point in having a script for this??

It would be something like:

#!/bin/bash# mapcycle.txt generator (too simple to code!)if [ $# -lt 3 ]; then #not enough arguments echo “Needed at least 3 aguments!” echo “Usage: ./generlist.sh maplist.txt ut4_map1 ut4_map2 …”else #charge array of mapnames args=(“$@”) filename=${args[0]} #generate cycling variables for (( i=1;i> $filename done echo “$filename created!”fi

However i don’t find it useful at all.

View PostZamy, on 11 October 2010 – 06:59 PM, said:

It will be more useful if it can generate a list of the maps in a plain text (as mapcycle.txt), not only a cfg to switch locally a map :smile:

Back to top of the page up there ^Reply Icon MultiQuoteReply Icon Reply –>#4User is offline   Zamy Iconnewbie playerPassport:zamyCountry:Joined:01-March 10Posts:28Posted Today, 01:37 AM

In a server with 30~40 extra map, i find it useful 😀

But i didn’t say that you made a bad work 😉
Back to top of the page up there ^Reply Icon MultiQuoteReply Icon Reply –>Search Topic Forum HomeURBAN TERROR DISCUSSION  |– News and Announcements  |– General Urban Terror Discussion  |– Bug Reports and SuggestionsURBAN TERROR TECHNICAL SUPPORT  |– General Support Area  |– Server Setup and Support  |– Windows Support  |– Linux Support  |– Macintosh SupportMAP / FUNSTUFF DISCUSSION  |– Map / Funstuff Releases  |– Map / Funstuff Design Support  |– Mapping Competition  |– Jump Map Releases / BetasSITE SUPPORT AND TESTING  |– Passport Specific Issues  |– Account Merge Requests  |– Site Support  |– Temporary Testing AreaMISCELLANEOUS  |– Urban Terror Movies  |– Urban Terror Clans  |– Urban Terror Leagues and Events  |– Off Topic  |– Urban Terror 4.0 Discussion (CLOSED)← Previous TopicServer Setup and SupportNext Topic →Page 1 of 1You cannot start a new topicYou cannot reply to this topic1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous usersBack To TopForum HomeMark Board As Read Community Forum Software by IP.Board
Licensed to: 0870760 B.C. Ltd

–>

Online:bullet_pinkQA team  Chrillo bullet_grayregistered  Driller | Kolossus | Orbit | Unclefragger 321 members and 3 420 visitors in the last 24 hours – 1 735 581 unique visites since 2009 – maximum 9 541 visitors Sun, 14 Mar 10 generated by FS-CMS v2.21 – public connection Urban Terror | UrT Forum | UrT Manual | FrozenSand About Urban Terror | Contact us | Terms of service | Privacy | Credits

Copyright © 2010 FrozenSand – All Rights Reserved – Urban Terror™ is a Trademark of FrozenSand / 0870760 B.C. Ltd

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

Information

This entry was posted on October 14, 2010 by and tagged , .
%d bloggers like this: