moved unit html site generate to zetaglest.github.io
I added these in this commit, on the web site repo:
04a619efa3
@@ -1 +0,0 @@
|
|||||||
/html/
|
|
@@ -1,118 +0,0 @@
|
|||||||
#!/bin/sh
|
|
||||||
#
|
|
||||||
# Use this script to make autodocumentation for docs in data's repository
|
|
||||||
# ----------------------------------------------------------------------------
|
|
||||||
# 2015 Written by filux <heross(@@)o2.pl>
|
|
||||||
# Copyright (c) 2015-2016 under GNU GPL v3.0+
|
|
||||||
LANG=C
|
|
||||||
|
|
||||||
if [ "$1" = "" ]; then
|
|
||||||
techtree="megapack"
|
|
||||||
else
|
|
||||||
techtree="$1"
|
|
||||||
fi
|
|
||||||
if [ "$2" = "" ]; then
|
|
||||||
rel_path_docs_icons="../../techs"
|
|
||||||
else
|
|
||||||
rel_path_docs_icons="$2"
|
|
||||||
fi
|
|
||||||
if [ "$3" = "" ]; then
|
|
||||||
rel_path_tech_test="../../../../data/glest_game/techs"
|
|
||||||
else
|
|
||||||
rel_path_tech_test="$3"
|
|
||||||
fi
|
|
||||||
if [ "$4" = "" ]; then
|
|
||||||
remote_logo="https://megaglest.org/uploads/megaglest2011/logo/logo.png"
|
|
||||||
else
|
|
||||||
remote_logo="$4"
|
|
||||||
fi
|
|
||||||
if [ "$5" = "" ]; then
|
|
||||||
remote_footer_logo="https://megaglest.org/uploads/megaglest2011/logo/gpl_osi.png"
|
|
||||||
else
|
|
||||||
remote_footer_logo="$5"
|
|
||||||
fi
|
|
||||||
SCRIPTDIR="$(dirname "$(readlink -f "$0")")"
|
|
||||||
cd "$SCRIPTDIR"
|
|
||||||
rm -rf html; sleep 0.1s
|
|
||||||
mkdir -p html/images
|
|
||||||
sed "s|^generate_g3d_images = .*|generate_g3d_images = 0|" "$techtree.ini" > "$techtree-temp.ini"
|
|
||||||
if [ "$(which curl 2>/dev/null)" != "" ]; then
|
|
||||||
if [ "$(grep -c "$remote_logo" "$techtree-temp.ini")" -gt "0" ]; then
|
|
||||||
curl -L -s "$remote_logo" -o "html/images/logo.png"
|
|
||||||
if [ "$?" -eq "0" ]; then sed -i "s|$remote_logo|images/logo.png|" "$techtree-temp.ini"; sleep 0.1s; fi
|
|
||||||
fi
|
|
||||||
if [ "$(grep -c "$remote_footer_logo" "$techtree-temp.ini")" -gt "0" ]; then
|
|
||||||
curl -L -s "$remote_footer_logo" -o "html/images/footer_logo.png"
|
|
||||||
if [ "$?" -eq "0" ]; then sed -i "s|$remote_footer_logo|images/footer_logo.png|" "$techtree-temp.ini"; sleep 0.1s; fi
|
|
||||||
fi
|
|
||||||
else
|
|
||||||
echo "Downloading tool 'curl' DOES NOT EXIST on this system, please install it."
|
|
||||||
fi
|
|
||||||
./convert_faction_xml2html.pl "$techtree-temp.ini"
|
|
||||||
|
|
||||||
cd html
|
|
||||||
icons_list1="$(grep -o "images/[^/ ]*/[^/ ]*/[^. ]*.bmp" *.html)"
|
|
||||||
icons_list2="$(grep -o "images/[^/ ]*/[^/ ]*/[^. ]*.jpg" *.html)"
|
|
||||||
icons_list3="$(grep -o "images/[^/ ]*/[^/ ]*/[^. ]*.png" *.html)"
|
|
||||||
icons_list="$(echo -e "$icons_list1 $icons_list2 $icons_list3" | xargs)"
|
|
||||||
echo ">>> replacing icon for (unit='|', upgrade='\', resource='/') ..."
|
|
||||||
for icon_file in $icons_list; do
|
|
||||||
filename="$(echo "$icon_file" | awk -F ':' '{print $1}')"
|
|
||||||
icon="$(echo "$icon_file" | awk -F ':' '{print $2}')"
|
|
||||||
|
|
||||||
faction="$(echo "$icon" | awk -F '/' '{print $2}')"
|
|
||||||
uu_name="$(echo "$icon" | awk -F '/' '{print $3}')"
|
|
||||||
bmp_file="$(echo "$icon" | awk -F '/' '{print $4}')"
|
|
||||||
find_file="$(find $rel_path_tech_test/$techtree/factions/$faction -type f -name "$bmp_file")"
|
|
||||||
|
|
||||||
echo "$find_file" | grep -q "factions/$faction/upgrades"
|
|
||||||
if [ "$?" -eq "0" ]; then :
|
|
||||||
sed -i "s|images/$faction/$uu_name/$bmp_file|$rel_path_docs_icons/$techtree/factions/$faction/upgrades/$uu_name/images/$bmp_file|" "$filename"
|
|
||||||
echo -n "\\"
|
|
||||||
else
|
|
||||||
echo "$find_file" | grep -q "factions/$faction/units"
|
|
||||||
if [ "$?" -eq "0" ]; then :
|
|
||||||
sed -i "s|images/$faction/$uu_name/$bmp_file|$rel_path_docs_icons/$techtree/factions/$faction/units/$uu_name/images/$bmp_file|" "$filename"
|
|
||||||
echo -n "|"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
sleep 0.01s
|
|
||||||
done
|
|
||||||
icons_list1="$(grep -o "images/resources/[^. ]*.bmp" *.html)"
|
|
||||||
icons_list2="$(grep -o "images/resources/[^. ]*.jpg" *.html)"
|
|
||||||
icons_list3="$(grep -o "images/resources/[^. ]*.png" *.html)"
|
|
||||||
icons_list="$(echo -e "$icons_list1 $icons_list2 $icons_list3" | xargs)"
|
|
||||||
for icon_file in $icons_list; do
|
|
||||||
filename="$(echo "$icon_file" | awk -F ':' '{print $1}')"
|
|
||||||
icon="$(echo "$icon_file" | awk -F ':' '{print $2}')"
|
|
||||||
|
|
||||||
bmp_file="$(echo "$icon" | awk -F '/' '{print $3}')"
|
|
||||||
res_name="$(echo "$bmp_file" | awk -F '.' '{print $1}')"
|
|
||||||
sed -i "s|images/resources/$bmp_file|$rel_path_docs_icons/$techtree/resources/$res_name/images/$bmp_file|" "$filename"
|
|
||||||
echo -n "/"
|
|
||||||
sleep 0.01s
|
|
||||||
done
|
|
||||||
echo
|
|
||||||
|
|
||||||
echo ">>> removing not required files ..."
|
|
||||||
rm -rf css js
|
|
||||||
find ./images/*/* -type d | xargs rm -rf
|
|
||||||
rm -rf images/datatables images/resources
|
|
||||||
find ./images/* -type f -name "*.canon" | xargs rm -f
|
|
||||||
find ./images/* -type f -name "*.cmapx" | xargs rm -f
|
|
||||||
find ./images/* -type f -name "*.text" | xargs rm -f
|
|
||||||
|
|
||||||
rm -f all.html
|
|
||||||
all_html_list="$(grep '"all.html"' *.html | awk -F ':' '{print $1}' | xargs)"
|
|
||||||
for filename in $all_html_list; do
|
|
||||||
sed -i '/All Units of all Factions/d' "$filename"
|
|
||||||
done
|
|
||||||
|
|
||||||
if [ "$(which optipng)" != "" ]; then
|
|
||||||
echo ">>> optimizing .png files ..."
|
|
||||||
find ./images -type f -name '*.png' -exec optipng '{}' \;
|
|
||||||
else
|
|
||||||
echo "Warning: 'optipng' not found"
|
|
||||||
fi
|
|
||||||
cd "$SCRIPTDIR"
|
|
||||||
rm -f "$techtree-temp.ini"
|
|
@@ -1 +0,0 @@
|
|||||||
/jquery*.min.js
|
|
@@ -1,19 +0,0 @@
|
|||||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN"
|
|
||||||
"http://www.w3.org/TR/html4/frameset.dtd">
|
|
||||||
<html>
|
|
||||||
<head>
|
|
||||||
<meta name="generator" content="HTML Tidy for Linux (vers 6 November 2007), see www.w3.org">
|
|
||||||
<title>Compare Glest Units</title>
|
|
||||||
<link type="TEXT/CSS" rel="STYLESHEET" href="style.css">
|
|
||||||
<link rel="shortcut icon" type="image/x-icon" href="favicon.ico">
|
|
||||||
<meta http-equiv="content-type" content="text/html; charset=utf-8">
|
|
||||||
</head>
|
|
||||||
<frameset rows="80,*">
|
|
||||||
<frame src="compare_help.html" frameborder="1">
|
|
||||||
<frameset cols="50%,50%" rows= "*">
|
|
||||||
<frame src="index.html#factions" frameborder= "1">
|
|
||||||
<frame src="index.html#factions" frameborder= "1">
|
|
||||||
</frameset>
|
|
||||||
</frameset>
|
|
||||||
</html>
|
|
||||||
|
|
@@ -1,16 +0,0 @@
|
|||||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
|
|
||||||
"http://www.w3.org/TR/html4/loose.dtd">
|
|
||||||
<HTML>
|
|
||||||
<HEAD>
|
|
||||||
<TITLE>Compare Glest Units</TITLE>
|
|
||||||
<LINK TYPE="TEXT/CSS" REL="STYLESHEET" HREF="style.css">
|
|
||||||
<link rel="shortcut icon" type="image/x-icon" href="favicon.ico">
|
|
||||||
<META HTTP-EQUIV="content-type" CONTENT="text/html; charset=utf-8">
|
|
||||||
</HEAD>
|
|
||||||
|
|
||||||
<BODY>
|
|
||||||
|
|
||||||
<H3 ALIGN=CENTER>Choose units in the left and right frames to compare.</H3>
|
|
||||||
<DIV ALIGN=CENTER><A HREF="index.html" TARGET="_top">Home</A></DIV>
|
|
||||||
</BODY>
|
|
||||||
</HTML>
|
|
Before Width: | Height: | Size: 592 B |
Before Width: | Height: | Size: 788 B |
Before Width: | Height: | Size: 617 B |
Before Width: | Height: | Size: 833 B |
Before Width: | Height: | Size: 254 B |
Before Width: | Height: | Size: 245 B |
Before Width: | Height: | Size: 282 B |
Before Width: | Height: | Size: 252 B |
Before Width: | Height: | Size: 244 B |
Before Width: | Height: | Size: 318 B |
@@ -1,305 +0,0 @@
|
|||||||
body {
|
|
||||||
margin: 0 auto;
|
|
||||||
width: 1016px;
|
|
||||||
|
|
||||||
background-color: #000000;
|
|
||||||
font-size: 0.8em;
|
|
||||||
color: #fff6c0;
|
|
||||||
font-family: "Lucida Sans Unicode","Lucida Grande","Lucida Sans", sans-serif;
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Structure
|
|
||||||
*/
|
|
||||||
|
|
||||||
/* Header */
|
|
||||||
#header {
|
|
||||||
width: 1016px;
|
|
||||||
height: 175px;
|
|
||||||
margin: 0 auto;
|
|
||||||
/* background: url("header/header.jpg") no-repeat; */
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Horizontal menu */
|
|
||||||
#menu {
|
|
||||||
background-image: url("menu.jpg");
|
|
||||||
background-repeat: no-repeat;
|
|
||||||
height: 65px;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Side menus */
|
|
||||||
#menu #first { float: left }
|
|
||||||
#menu #second { float: right }
|
|
||||||
|
|
||||||
/* Main content */
|
|
||||||
#content {
|
|
||||||
width: 1024px;
|
|
||||||
margin: 0 auto;
|
|
||||||
background: url("wood_panel.jpg") repeat;
|
|
||||||
}
|
|
||||||
img {
|
|
||||||
padding-right: 3px;
|
|
||||||
padding-bottom: 1px;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Article (core text of the page) */
|
|
||||||
#article {
|
|
||||||
font-size: 1.1em;
|
|
||||||
line-height: 1.5em;
|
|
||||||
padding: 2em;
|
|
||||||
text-align: justify;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* end of article has to be below side modules */
|
|
||||||
#end_article {
|
|
||||||
clear: both;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Side modules */
|
|
||||||
#aside_left {
|
|
||||||
float: left;
|
|
||||||
width: 420px;
|
|
||||||
margin-left: -168px;
|
|
||||||
}
|
|
||||||
#aside_left ul {
|
|
||||||
padding: 0 17px 0 168px;
|
|
||||||
margin: 0 2em 2em 2em;
|
|
||||||
}
|
|
||||||
|
|
||||||
#aside_right {
|
|
||||||
float: right;
|
|
||||||
width: 420px;
|
|
||||||
margin-right: -168px;
|
|
||||||
}
|
|
||||||
#aside_right ul {
|
|
||||||
padding: 0 140px 0 25px;
|
|
||||||
margin: 0 2em;
|
|
||||||
}
|
|
||||||
|
|
||||||
.aside .up_image {
|
|
||||||
width: 420px;
|
|
||||||
height: 278px;
|
|
||||||
}
|
|
||||||
.aside .down_image {
|
|
||||||
width: 420px;
|
|
||||||
height: 191px;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* fill .up_image and .down_image with content */
|
|
||||||
.aside .content {
|
|
||||||
margin-top: -210px;
|
|
||||||
margin-bottom: -80px;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Footer */
|
|
||||||
#footer {
|
|
||||||
width: 1016px;
|
|
||||||
height: 143px;
|
|
||||||
margin: 0 auto;
|
|
||||||
background-image: url("footer/footer.jpg");
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Text display: side, colors, etc.
|
|
||||||
*/
|
|
||||||
p { text-indent: 2em }
|
|
||||||
a { color: #ecc72d }
|
|
||||||
a:link { text-decoration: none }
|
|
||||||
a:hover { text-decoration: underline }
|
|
||||||
a img { border: 0; }
|
|
||||||
img.right {
|
|
||||||
float: right;
|
|
||||||
margin: 0 0 10px 10px;
|
|
||||||
}
|
|
||||||
img.left {
|
|
||||||
float: left;
|
|
||||||
margin: 0 10px 10px 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* news dates, scores: gold */
|
|
||||||
.info, .date, #content h3 { color: #ecc72d; }
|
|
||||||
#content h3 { font-weight: normal; text-indent: 3em }
|
|
||||||
|
|
||||||
/* Logo */
|
|
||||||
#header #logo {
|
|
||||||
width: 365px;
|
|
||||||
margin: 0 auto;
|
|
||||||
margin-top: 1em;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Download image */
|
|
||||||
h2#download {
|
|
||||||
margin: 0 auto;
|
|
||||||
margin-top: -2em;
|
|
||||||
text-align: center;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Module titles */
|
|
||||||
.aside h3 { display: block; }
|
|
||||||
|
|
||||||
.aside h3#news { margin-left: 240px; }
|
|
||||||
.aside h3#servers { margin-left: 50px; }
|
|
||||||
.aside h3.forums { margin-left: 230px; }
|
|
||||||
.aside h3#links { margin-left: 110px; }
|
|
||||||
|
|
||||||
/* Menu links */
|
|
||||||
#menu ul { margin: 0; padding: 0}
|
|
||||||
#menu li { display: inline; }
|
|
||||||
/* left horizontal menu should not "touch" the wood */
|
|
||||||
#menu #second li:first-child { margin-left: 10px; }
|
|
||||||
|
|
||||||
#menu a {
|
|
||||||
/* fixed available space: fixed size */
|
|
||||||
font-size: 14px;
|
|
||||||
color: #b5dbb5;
|
|
||||||
font-variant: small-caps;
|
|
||||||
margin: 0 8px;
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Modules
|
|
||||||
*/
|
|
||||||
#aside_left { background: url("modules/l_repeat.jpg") repeat-y }
|
|
||||||
#aside_left .up_image { background: url("modules/l_up.jpg") }
|
|
||||||
#aside_left .down_image { background: url("modules/l_down.jpg") }
|
|
||||||
|
|
||||||
#aside_right {background: url("modules/r_repeat.jpg") repeat-y}
|
|
||||||
#aside_right .up_image {background: url("modules/r_up.jpg")}
|
|
||||||
#aside_right .down_image {background: url("modules/r_down.jpg")}
|
|
||||||
|
|
||||||
.aside ul li {
|
|
||||||
list-style-image: url("modules/star.png");
|
|
||||||
clear: right;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* News module */
|
|
||||||
.date {
|
|
||||||
display: block;
|
|
||||||
float: right;
|
|
||||||
margin-top: 1em;
|
|
||||||
margin-bottom: 1.5em;
|
|
||||||
/* Font */
|
|
||||||
font-family: "DejaVu Serif Condensed", serif;
|
|
||||||
font-style: italic;
|
|
||||||
font-size: 0.9em;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Servers module */
|
|
||||||
.aside table {
|
|
||||||
width: 200px;
|
|
||||||
margin-left: 50px;
|
|
||||||
text-align:center;
|
|
||||||
}
|
|
||||||
|
|
||||||
.aside table td:first-child {
|
|
||||||
text-align: left;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/* Forums module */
|
|
||||||
.forums .date {
|
|
||||||
margin-top: 3px;
|
|
||||||
font-size: 1em;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Footer */
|
|
||||||
#footer ul {
|
|
||||||
margin: 0 auto;
|
|
||||||
padding-top: 90px;
|
|
||||||
width: 25em;
|
|
||||||
}
|
|
||||||
#footer li {
|
|
||||||
list-style-type: none;
|
|
||||||
display: inline;
|
|
||||||
margin: 0 1em;
|
|
||||||
}
|
|
||||||
/* links in the dark space, images above */
|
|
||||||
#footer img {
|
|
||||||
vertical-align: -20%;
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Additional background images
|
|
||||||
*/
|
|
||||||
#header_left {
|
|
||||||
float: left;
|
|
||||||
width: 140px;
|
|
||||||
height: 882px;
|
|
||||||
|
|
||||||
background-image: url("header/left.jpg");
|
|
||||||
background-repeat: no-repeat;
|
|
||||||
margin-left: -140px;
|
|
||||||
}
|
|
||||||
|
|
||||||
#header_right {
|
|
||||||
float: right;
|
|
||||||
height: 843px;
|
|
||||||
width: 143px;
|
|
||||||
|
|
||||||
background-image: url("header/right.jpg");
|
|
||||||
background-repeat: no-repeat;
|
|
||||||
margin-right: -143px;
|
|
||||||
}
|
|
||||||
|
|
||||||
#footer_left {
|
|
||||||
float: left;
|
|
||||||
height: 143px;
|
|
||||||
width: 101px;
|
|
||||||
margin-left: -101px;
|
|
||||||
background: url("footer/footer_left.jpg") no-repeat;
|
|
||||||
}
|
|
||||||
|
|
||||||
#footer_right {
|
|
||||||
float: right;
|
|
||||||
height: 143px;
|
|
||||||
width: 106px;
|
|
||||||
margin-right: -106px;
|
|
||||||
background: url("footer/footer_right.jpg") no-repeat;
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
|
||||||
* DataTables sorting
|
|
||||||
*/
|
|
||||||
|
|
||||||
.sorting_asc {
|
|
||||||
background-image: url('images/datatables/sort_asc.png');
|
|
||||||
background-repeat: no-repeat;
|
|
||||||
background-position: center right;
|
|
||||||
}
|
|
||||||
|
|
||||||
.sorting_desc {
|
|
||||||
background-image: url('images/datatables/sort_desc.png');
|
|
||||||
background-repeat: no-repeat;
|
|
||||||
background-position: center right;
|
|
||||||
}
|
|
||||||
|
|
||||||
.sorting {
|
|
||||||
background-image: url('images/datatables/sort_both.png');
|
|
||||||
background-repeat: no-repeat;
|
|
||||||
background-position: center right;
|
|
||||||
}
|
|
||||||
|
|
||||||
.sorting_asc_disabled {
|
|
||||||
background-image: url('images/datatables/sort_asc_disabled.png') ;
|
|
||||||
background-repeat: no-repeat;
|
|
||||||
background-position: center right;
|
|
||||||
}
|
|
||||||
|
|
||||||
.sorting_desc_disabled {
|
|
||||||
background-image: url('images/datatables/sort_desc_disabled.png') ;
|
|
||||||
background-repeat: no-repeat;
|
|
||||||
background-position: center right;
|
|
||||||
}
|
|
||||||
|
|
||||||
tr.odd {
|
|
||||||
background-color: #7E2217;
|
|
||||||
}
|
|
||||||
|
|
||||||
tr.even {
|
|
||||||
background-color: #7F462C;
|
|
||||||
}
|
|
||||||
|
|
@@ -1,51 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
#
|
|
||||||
# Use this script to install build dependencies on a number of Linux platforms
|
|
||||||
# ----------------------------------------------------------------------------
|
|
||||||
# Originally written by Mark Vejvoda <mark_vejvoda@hotmail.com>
|
|
||||||
# Rewritten by Tom Reynolds <tomreyn@megaglest.org>
|
|
||||||
# Copyright (c) 2012-2016 Mark Vejvoda, Tom Reynolds under GNU GPL v3.0
|
|
||||||
|
|
||||||
SCRIPTDIR="$(dirname $(readlink -f $0))"
|
|
||||||
|
|
||||||
# Load shared functions
|
|
||||||
. $SCRIPTDIR/../../../mk/linux/mg_shared.sh
|
|
||||||
|
|
||||||
echo 'Downloading Javascript libraries...'
|
|
||||||
wget http://code.jquery.com/jquery-1.12.0.js -O media/jquery-1.12.0.min.js
|
|
||||||
wget http://www.datatables.net/download/build/jquery.dataTables.min.js -O media/jquery.dataTables.min.js
|
|
||||||
|
|
||||||
echo 'Detecting system and installing dependencies...'
|
|
||||||
# Included from shared functions
|
|
||||||
detect_system
|
|
||||||
|
|
||||||
echo 'We have detected the following system:'
|
|
||||||
echo ' [ '"$distribution"' ] [ '"$release"' ] [ '"$codename"' ] [ '"$architecture"' ]'
|
|
||||||
|
|
||||||
case $distribution in
|
|
||||||
SuSE|SUSE?LINUX|Opensuse)
|
|
||||||
case $release in
|
|
||||||
*)
|
|
||||||
echo '(Open)SuSE...'
|
|
||||||
sudo zypper install graphviz-perl perl-GraphViz perl-Config-IniFiles perl-PerlMagick
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
;;
|
|
||||||
|
|
||||||
Debian|Ubuntu|LinuxMint)
|
|
||||||
case $release in
|
|
||||||
*)
|
|
||||||
echo 'Debian / Ubuntu...'
|
|
||||||
sudo apt-get install perl graphviz libgraphviz-perl libconfig-inifiles-perl perlmagick
|
|
||||||
#sudo apt-get install libimage-size-perl
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
;;
|
|
||||||
*)
|
|
||||||
echo 'ERROR: Unknown distribution. Stopping here.' >&2
|
|
||||||
exit 1
|
|
||||||
esac
|
|
||||||
|
|
||||||
echo ''
|
|
||||||
echo 'To create techtree HTML pages copy / edit megapack.ini and run the script:'
|
|
||||||
echo './convert_faction_xml2html.pl megapack.ini'
|
|
@@ -1,23 +0,0 @@
|
|||||||
#!/usr/bin/perl -w
|
|
||||||
|
|
||||||
# Copyright 2011 olaus
|
|
||||||
# license: GPLv3 or newer
|
|
||||||
# show xpath in file, google xpath for syntax
|
|
||||||
|
|
||||||
|
|
||||||
if ( !@ARGV ) {
|
|
||||||
die "\n\nusage $0 file xpath\n\n";
|
|
||||||
}
|
|
||||||
|
|
||||||
use strict;
|
|
||||||
use XML::XPath;
|
|
||||||
use XML::XPath::XMLParser;
|
|
||||||
|
|
||||||
my $xpath = XML::XPath->new( filename => shift @ARGV );
|
|
||||||
|
|
||||||
my $nodeset = $xpath->find( shift @ARGV );
|
|
||||||
|
|
||||||
foreach my $node ( $nodeset->get_nodelist ) {
|
|
||||||
print XML::XPath::XMLParser::as_string( $node ) . "\n";
|
|
||||||
}
|
|
||||||
|
|
@@ -1,254 +0,0 @@
|
|||||||
[all]
|
|
||||||
debug = 1;
|
|
||||||
|
|
||||||
# Are paths below based on relative paths to the folder this script is running in
|
|
||||||
relative_paths = 1
|
|
||||||
|
|
||||||
# Create 'screen shots' of models' G3D animations?
|
|
||||||
generate_g3d_images = 1
|
|
||||||
|
|
||||||
# export functions, see "perldoc GraphViz" (or search.cpan.org for GraphViz) for a list
|
|
||||||
#export_graph=as_svg;as_png
|
|
||||||
export_graph=as_svg;as_png;as_canon;as_text;as_cmapx
|
|
||||||
|
|
||||||
# combine png and cmapx to clickable map
|
|
||||||
build_clickable_map=1
|
|
||||||
|
|
||||||
version=Zetapack
|
|
||||||
|
|
||||||
# should links to units go the single pages for each unit (vs. the techtree-page if set to 0)
|
|
||||||
link_to_single_units=1
|
|
||||||
|
|
||||||
# stat raise by levels as factor, as specified in the code, thanks titi for digging it out
|
|
||||||
level_hp=1.5
|
|
||||||
level_ep=1.5
|
|
||||||
level_sight=1.2
|
|
||||||
level_armor=1.5
|
|
||||||
# megaglest-code
|
|
||||||
#maxHp+= ut->getMaxHp()*50/100;
|
|
||||||
#maxEp+= ut->getMaxEp()*50/100;
|
|
||||||
#sight+= ut->getSight()*20/100;
|
|
||||||
#armor+= ut->getArmor()*50/100;
|
|
||||||
|
|
||||||
|
|
||||||
[files]
|
|
||||||
g3dviewer_path=../../../mk/linux/zegaglest_g3dviewer
|
|
||||||
factions_path=../../../../zetaglest-data/techs/zetapack/factions
|
|
||||||
resources_path=../../../../zetaglest-data/techs/zetapack/resources
|
|
||||||
|
|
||||||
pack_file=../../../../zetaglest-data/techs/zetapack/zetapack.xml
|
|
||||||
|
|
||||||
out_path=html
|
|
||||||
|
|
||||||
glestkeys=../../../mk/shared/glestkeys.ini
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#summary=glest_autodocument_summary.html
|
|
||||||
summary=index.html
|
|
||||||
|
|
||||||
units_path=units
|
|
||||||
upgrades_path=upgrades
|
|
||||||
images_path=images
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
[style]
|
|
||||||
# set columns and their order for all and everything table:
|
|
||||||
# see available options with the command line: "grep \$col{ ./convert_faction_xml2html.pl"
|
|
||||||
columns_all_table= \
|
|
||||||
name, \
|
|
||||||
name_pretty, \
|
|
||||||
name_link, \
|
|
||||||
faction, \
|
|
||||||
faction_pretty, \
|
|
||||||
type, \
|
|
||||||
max_strength_vs_land, \
|
|
||||||
max_strength_vs_air, \
|
|
||||||
max_range, \
|
|
||||||
attack_strength_1, \
|
|
||||||
attack_var_1, \
|
|
||||||
attack_range_1, \
|
|
||||||
attack_type_1, \
|
|
||||||
used_on_hold_position_1, \
|
|
||||||
target_1, \
|
|
||||||
attack_speed_1, \
|
|
||||||
attack_start_time_1, \
|
|
||||||
attack_ep_cost_1, \
|
|
||||||
attack_strength_2, \
|
|
||||||
attack_var_2, \
|
|
||||||
attack_range_2, \
|
|
||||||
attack_type_2, \
|
|
||||||
used_on_hold_position_2, \
|
|
||||||
target_2, \
|
|
||||||
attack_speed_2, \
|
|
||||||
attack_start_time_2, \
|
|
||||||
attack_ep_cost_2, \
|
|
||||||
max_hp, \
|
|
||||||
regeneration, \
|
|
||||||
max_ep, \
|
|
||||||
regeneration_ep, \
|
|
||||||
armor, \
|
|
||||||
armor_type, \
|
|
||||||
sight, \
|
|
||||||
creation_1, \
|
|
||||||
creation_2, \
|
|
||||||
production_time, \
|
|
||||||
gold_1, \
|
|
||||||
wood_1, \
|
|
||||||
stone_1, \
|
|
||||||
food_1, \
|
|
||||||
energy_1, \
|
|
||||||
housing, \
|
|
||||||
gold_2, \
|
|
||||||
wood_2, \
|
|
||||||
stone_2, \
|
|
||||||
food_2, \
|
|
||||||
energy_2, \
|
|
||||||
housing, \
|
|
||||||
storage, \
|
|
||||||
move_speed_1, \
|
|
||||||
move_speed_2, \
|
|
||||||
move_speed_3, \
|
|
||||||
max_move_speed, \
|
|
||||||
max_level, \
|
|
||||||
available_upgrades, \
|
|
||||||
morphing_to_1, \
|
|
||||||
morphing_discount_1, \
|
|
||||||
morphing_speed_1, \
|
|
||||||
morphing_to_2, \
|
|
||||||
morphing_discount_2, \
|
|
||||||
morphing_speed_2, \
|
|
||||||
morphing_to_3, \
|
|
||||||
morphing_discount_3, \
|
|
||||||
morphing_speed_3, \
|
|
||||||
heal_skill_1, \
|
|
||||||
heal_units_1, \
|
|
||||||
heal_speed_1, \
|
|
||||||
heal_skill_2, \
|
|
||||||
heal_units_2, \
|
|
||||||
heal_speed_2, \
|
|
||||||
mine_resource_1, \
|
|
||||||
mine_speed_1, \
|
|
||||||
mine_max_load_1, \
|
|
||||||
mine_hits_per_unit_1, \
|
|
||||||
mine_resource_2, \
|
|
||||||
mine_speed_2, \
|
|
||||||
mine_max_load_2, \
|
|
||||||
mine_hits_per_unit_2, \
|
|
||||||
upgrade_affects
|
|
||||||
|
|
||||||
svg_fontcolor = 0.13472,0.809,0.925;
|
|
||||||
|
|
||||||
|
|
||||||
header=<<EOT
|
|
||||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
|
|
||||||
"http://www.w3.org/TR/html4/loose.dtd">
|
|
||||||
<head>
|
|
||||||
<title>VAR_TITLE</title>
|
|
||||||
<link type="text/css" rel="stylesheet" href="style.css">
|
|
||||||
<link rel="shortcut icon" type="image/x-icon" href="favicon.ico">
|
|
||||||
<meta http-equiv="content-type" content="text/html; charset=utf-8">
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no" />
|
|
||||||
|
|
||||||
<!-- stuff for table-sorting, see jquery.com and datatables.net for details
|
|
||||||
-->
|
|
||||||
<script type="text/javascript" language="javascript" src="js/jquery-1.12.0.min.js" ></script>
|
|
||||||
<script type="text/javascript" language="javascript" src="js/jquery.dataTables.min.js"></script>
|
|
||||||
<!--
|
|
||||||
<script type="text/javascript" language="javascript" src="js/TableTools.min.js"></script>
|
|
||||||
-->
|
|
||||||
<script type="text/javascript" charset="utf-8">
|
|
||||||
$(document).ready(function() {
|
|
||||||
|
|
||||||
$('#table_all').dataTable( {
|
|
||||||
'bAutoWidth': false,
|
|
||||||
"bPaginate": false,
|
|
||||||
"bSortClasses": false,
|
|
||||||
"sDom": '<"top"iflp>rt<"bottom"><"clear">',
|
|
||||||
<!--
|
|
||||||
"oTableTools": {
|
|
||||||
"sSwfPath": "js/copy_cvs_xls_pdf.swf"
|
|
||||||
},
|
|
||||||
-->
|
|
||||||
"aaSorting": [[ 1, "asc" ]]
|
|
||||||
});
|
|
||||||
});
|
|
||||||
</script>
|
|
||||||
</head>
|
|
||||||
|
|
||||||
<body>
|
|
||||||
|
|
||||||
<!-- start header -->
|
|
||||||
<div id="header">
|
|
||||||
|
|
||||||
<!-- Contain the right and left header images -->
|
|
||||||
<div id="header_left"></div>
|
|
||||||
<div id="header_right"></div>
|
|
||||||
<!-- FIXME: needs height and width specs -->
|
|
||||||
<div id="logo"><a href="/"><img src="/images/zetaglest_logo_360x181.png" alt="ZetaGlest logo" /></a></div>
|
|
||||||
</div>
|
|
||||||
<p><a href="https://zetaglest.dreamhosters.com/">Server List and Player Stats</a> |
|
|
||||||
<a href="https://github.com/ZetaGlest/zetaglest-source/blob/develop/README.md">README</a> |
|
|
||||||
<a href="https://github.com/ZetaGlest">on GitHub</a> |
|
|
||||||
<a href="https://discord.gg/WaAaXS7">on Discord</a> |
|
|
||||||
<a href="https://github.com/ZetaGlest/zetaglest-source/blob/develop/CONTRIBUTING.md">Contributing</a> |
|
|
||||||
<a href="https://github.com/ZetaGlest/zetaglest-data#submitting-mods-tech-trees-tilesets-maps-scenarios">Submitting mods, tech trees, tilesets, maps, scenarios</a>
|
|
||||||
<!-- end header -->
|
|
||||||
|
|
||||||
<!-- start content -->
|
|
||||||
<div id="content">
|
|
||||||
<div id="article">
|
|
||||||
|
|
||||||
|
|
||||||
<h1>VAR_TITLE</h1>
|
|
||||||
<p>
|
|
||||||
<h4><a href="VAR_SUMMARY">Home</a></h4><p>
|
|
||||||
EOT
|
|
||||||
|
|
||||||
|
|
||||||
footer=<<EOT
|
|
||||||
<!-- start footer -->
|
|
||||||
This page was generated by: VAR_CREATED_BY
|
|
||||||
<br>
|
|
||||||
|
|
||||||
<div id="footer">
|
|
||||||
<div id="footer_left"></div>
|
|
||||||
<div id="footer_right"></div>
|
|
||||||
<ul>
|
|
||||||
<!-- <li><a href="https://megaglest.org/privacy.html">Privacy</a></li> -->
|
|
||||||
<a href="https://github.com/ZetaGlest/zetaglest-source/blob/develop/COPYING"><img src="/images/ThemezHut-Released-under-GPL_135x90.png" alt="GNU GPL3 logo" /></a></li>
|
|
||||||
<li><a href="https://github.com/ZetaGlest/zetaglest-source/blob/develop/AUTHORS.md">Credits</a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
<!-- end footer -->
|
|
||||||
|
|
||||||
EOT
|
|
||||||
|
|
||||||
|
|
||||||
resource_order=gold:wood:stone:food:energy:housing
|
|
||||||
|
|
||||||
map_legend=<<EOT
|
|
||||||
<h4>Arrow Styles:</h4>
|
|
||||||
<ul>
|
|
||||||
<li>Bold: Unit creates building
|
|
||||||
<li>Solid: Building produces unit or upgrade
|
|
||||||
<li>Dashed: Units morphs/upgrades to other unit
|
|
||||||
<li>Dotted: Unit or Upgrade is a requirement
|
|
||||||
</ul>
|
|
||||||
EOT
|
|
||||||
|
|
||||||
# settings for glest_g3dviewer unit-pictures
|
|
||||||
unit_png_rotate_x_value=318
|
|
||||||
unit_png_rotate_y_value=6
|
|
||||||
|
|
||||||
unit_png_building_zoom=0.68
|
|
||||||
unit_png_unit_zoom=1.3
|
|
||||||
|
|
||||||
# resize screenshots of glest_g3dviewer
|
|
||||||
# orignal size is 640x432 so use that ratio
|
|
||||||
unit_png_width=320
|
|
||||||
unit_png_height=216
|
|
||||||
|
|