/usr/share/doc/crossfire-doc/playbook-html/treas1-extract is in crossfire-doc 1.70.0-1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 | # stats-extract - parse the archetypes-file and output the
# player's stats in a structured format.
/^Object/ {
randomitems = "";
name = obj = $2;
type = 0;
}
/^type/ { type = $2 }
/^randomitems/ { randomitems = $2 }
/^name/ { name = substr($0, 6) }
/^end/ {
if (type == 1) { # Players
printf("%s,%s\n", decapitalize(name), randomitems);
}
}
END {
close("items");
}
function decapitalize(str) {
return tolower (substr(str, 1, 1)) substr(str, 2);
}
|