Skip to content

Commit

Permalink
Merge pull request #42 from CleverRaven/master
Browse files Browse the repository at this point in the history
reweight gemstones in item_groups.json (CleverRaven#36734)
  • Loading branch information
fengjixuchui authored Jan 7, 2020
2 parents c767c3b + bd22b04 commit e2f8b54
Show file tree
Hide file tree
Showing 44 changed files with 1,118 additions and 877 deletions.
4 changes: 4 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ option(TILES "Build graphical tileset version." "OFF")
option(CURSES "Build curses version." "ON")
option(SOUND "Support for in-game sounds & music." "OFF")
option(BACKTRACE "Support for printing stack backtraces on crash" "ON")
option(LIBBACKTRACE "Print backtrace with libbacktrace." "OFF")
option(USE_HOME_DIR "Use user's home directory for save files." "ON")
option(LOCALIZE "Support for language localizations. Also enable UTF support." "ON")
option(LANGUAGES "Compile localization files for specified languages." "")
Expand Down Expand Up @@ -323,6 +324,9 @@ ENDIF(SOUND)

IF(BACKTRACE)
ADD_DEFINITIONS(-DBACKTRACE)
IF(LIBBACKTRACE)
ADD_DEFINITIONS(-DLIBBACKTRACE)
ENDIF(LIBBACKTRACE)
ENDIF(BACKTRACE)

# Ok. Now create build and install recipes
Expand Down
32 changes: 32 additions & 0 deletions LICENSE.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,35 @@ CATCH unit-test framework (tests/catch/catch.hpp) is licensed under the Boost So
PLF List and PLF Colony (src/list.h, src/colony.h) are licensed under the zLib license (https://www.zlib.net/zlib_license.html).

getpost (tools/json_tools/format/getpost.h) is licensed under the MIT license, see file for text of license.

libbacktrace is licensed under a BSD license (https://github.com/ianlancetaylor/libbacktrace/blob/master/LICENSE). The full license text is as follows:

# Copyright (C) 2012-2016 Free Software Foundation, Inc.

# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
# met:

# (1) Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.

# (2) Redistributions in binary form must reproduce the above copyright
# notice, this list of conditions and the following disclaimer in
# the documentation and/or other materials provided with the
# distribution.

# (3) The name of the author may not be used to
# endorse or promote products derived from this software without
# specific prior written permission.

# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
# DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT,
# INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
# STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
# IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
# POSSIBILITY OF SUCH DAMAGE.
20 changes: 18 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,8 @@
# make LOCALIZE=0
# Disable backtrace support, not available on all platforms
# make BACKTRACE=0
# Use libbacktrace. Only has effect if BACKTRACE=1. (currently only for MinGW builds)
# make LIBBACKTRACE=1
# Compile localization files for specified languages
# make localization LANGUAGES="<lang_id_1>[ lang_id_2][ ...]"
# (for example: make LANGUAGES="zh_CN zh_TW" for Chinese)
Expand Down Expand Up @@ -171,6 +173,14 @@ ifndef BACKTRACE
BACKTRACE = 1
endif
endif
ifdef BACKTRACE
# Also enable libbacktrace on cross-compilation to Windows
ifndef LIBBACKTRACE
ifneq (,$(findstring mingw32,$(CROSS)))
LIBBACKTRACE = 1
endif
endif
endif

ifeq ($(RUNTESTS), 1)
TESTS = tests
Expand All @@ -185,7 +195,7 @@ W32ODIR = $(BUILD_PREFIX)objwin
W32ODIRTILES = $(W32ODIR)/tiles

ifdef AUTO_BUILD_PREFIX
BUILD_PREFIX = $(if $(RELEASE),release-)$(if $(DEBUG_SYMBOLS),symbol-)$(if $(TILES),tiles-)$(if $(SOUND),sound-)$(if $(LOCALIZE),local-)$(if $(BACKTRACE),back-)$(if $(SANITIZE),sanitize-)$(if $(MAPSIZE),map-$(MAPSIZE)-)$(if $(USE_XDG_DIR),xdg-)$(if $(USE_HOME_DIR),home-)$(if $(DYNAMIC_LINKING),dynamic-)$(if $(MSYS2),msys2-)
BUILD_PREFIX = $(if $(RELEASE),release-)$(if $(DEBUG_SYMBOLS),symbol-)$(if $(TILES),tiles-)$(if $(SOUND),sound-)$(if $(LOCALIZE),local-)$(if $(BACKTRACE),back-$(if $(LIBBACKTRACE),libbacktrace-))$(if $(SANITIZE),sanitize-)$(if $(MAPSIZE),map-$(MAPSIZE)-)$(if $(USE_XDG_DIR),xdg-)$(if $(USE_HOME_DIR),home-)$(if $(DYNAMIC_LINKING),dynamic-)$(if $(MSYS2),msys2-)
export BUILD_PREFIX
endif

Expand Down Expand Up @@ -340,7 +350,7 @@ endif
CXXFLAGS += $(WARNINGS) $(DEBUG) $(DEBUGSYMS) $(PROFILE) $(OTHERS) -MMD -MP
TOOL_CXXFLAGS = -DCATA_IN_TOOL

BINDIST_EXTRAS += README.md data doc
BINDIST_EXTRAS += README.md data doc LICENSE.txt
BINDIST = $(BUILD_PREFIX)cataclysmdda-$(VERSION).tar.gz
W32BINDIST = $(BUILD_PREFIX)cataclysmdda-$(VERSION).zip
BINDIST_CMD = tar --transform=s@^$(BINDIST_DIR)@cataclysmdda-$(VERSION)@ -czvf $(BINDIST) $(BINDIST_DIR)
Expand Down Expand Up @@ -666,11 +676,17 @@ ifeq ($(TARGETSYSTEM),WINDOWS)
LDFLAGS += -lgdi32 -lwinmm -limm32 -lole32 -loleaut32 -lversion
ifeq ($(BACKTRACE),1)
LDFLAGS += -ldbghelp
ifeq ($(LIBBACKTRACE),1)
LDFLAGS += -lbacktrace
endif
endif
endif

ifeq ($(BACKTRACE),1)
DEFINES += -DBACKTRACE
ifeq ($(LIBBACKTRACE),1)
DEFINES += -DLIBBACKTRACE
endif
endif

ifeq ($(LOCALIZE),1)
Expand Down
1 change: 1 addition & 0 deletions build-scripts/libbacktrace-i686-w64-mingw32-sha256
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
52811183c904305ddfa28d4b2236cc14da5293cd4d038d02b57d53dc18701502 *libbacktrace-i686-w64-mingw32.tar.gz
7 changes: 7 additions & 0 deletions build-scripts/requirements.sh
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,13 @@ if [ -n "${MXE_TARGET}" ]; then
# Need to overwrite CXX to make the Makefile $CROSS logic work right.
export CXX="$COMPILER"
export CCACHE=1

curl -L -o libbacktrace-i686-w64-mingw32.tar.gz https://github.com/Qrox/libbacktrace/releases/download/2020-01-03/libbacktrace-i686-w64-mingw32.tar.gz
if ! shasum -a 256 -c ./build-scripts/libbacktrace-i686-w64-mingw32-sha256; then
echo "Checksum failed for libbacktrace-i686-w64-mingw32.tar.gz"
exit 1
fi
sudo tar -xzf libbacktrace-i686-w64-mingw32.tar.gz --exclude=LICENSE -C ${MXE_DIR}/../${PLATFORM}
fi

if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then
Expand Down
40 changes: 40 additions & 0 deletions data/json/itemgroups/food.json
Original file line number Diff line number Diff line change
Expand Up @@ -851,5 +851,45 @@
[ "eggnog_spiked", 5 ],
[ "drink_martini", 10 ]
]
},
{
"id": "barbecue",
"type": "item_group",
"items": [
[ "beer", 15 ],
[ "meat", 65 ],
[ "glazed_tenderloin", 55 ],
[ "fish", 10 ],
[ "fish_smoked", 5 ],
[ "meat_smoked", 60 ],
[ "sausage", 35 ],
[ "bratwurst_sausage", 30 ],
[ "hotdogs_frozen", 65 ],
[ "hotdogs_cooked", 65 ],
[ "chilidogs", 30 ],
[ "currywurst", 15 ],
[ "lettuce", 45 ],
[ "tomato", 45 ],
[ "onion", 30 ],
[ "chili_pepper", 30 ],
[ "corn", 20 ],
[ "irradiated_lettuce", 20 ],
[ "irradiated_tomato", 20 ],
[ "irradiated_onion", 5 ],
[ "irradiated_corn", 10 ],
[ "bacon", 20 ],
[ "potato_baked", 15 ],
[ "bread", 40 ],
[ "ketchup", 80 ],
[ "mustard", 75 ],
{ "item": "pickle", "prob": 20, "charges": 6, "container-item": "jar_glass_sealed" },
[ "pickle", 20 ],
[ "cheeseburger", 30 ],
[ "hamburger", 70 ],
[ "cheese", 45 ],
[ "ceramic_plate", 30 ],
[ "knife_steak", 45 ],
[ "tongs", 60 ]
]
}
]
6 changes: 3 additions & 3 deletions data/json/itemgroups/item_groups.json
Original file line number Diff line number Diff line change
Expand Up @@ -491,7 +491,7 @@
{
"type": "item_group",
"id": "fridge",
"//": "This is a terrible item group and should be phased out. See SUS_fridge for a more modern take on things.",
"//": "This is a terrible item group and should be phased out. See SUS_fridge in SUS - > domestic.json for a more modern take on things.",
"items": [
[ "water_clean", 90 ],
[ "water_mineral", 10 ],
Expand Down Expand Up @@ -3102,7 +3102,7 @@
"type": "item_group",
"items": [
[ "citrine", 50 ],
[ "diamond", 50 ],
[ "diamond", 100 ],
[ "emerald", 50 ],
[ "peridot", 50 ],
[ "amethyst", 50 ],
Expand All @@ -3111,7 +3111,7 @@
[ "blue_topaz", 50 ],
[ "tourmaline", 50 ],
[ "alexandrite", 50 ],
[ "pearl", 50 ],
[ "pearl", 100 ],
[ "opal", 50 ],
[ "ruby", 50 ],
[ "garnet", 50 ]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,8 @@
"name": "corpse",
"description": "A dead body of a young woman.",
"looks_like": "corpse",
"volume": "40000 ml",
"weight": "52000 g",
"volume": "40 L",
"weight": "52 kg",
"material": "hflesh"
},
{
Expand All @@ -65,6 +65,8 @@
"name": "corpse",
"description": "A dead body of a little boy.",
"looks_like": "corpse",
"volume": "30 L",
"weight": "30 kg",
"material": "hflesh"
},
{
Expand All @@ -74,6 +76,8 @@
"name": "corpse",
"description": "A dead body of a little girl.",
"looks_like": "corpse",
"volume": "30 L",
"weight": "30 kg",
"material": "hflesh"
},
{
Expand All @@ -83,8 +87,8 @@
"name": "corpse",
"description": "The dead body of a small child. Their corpse bears a calm facial expression, as if they died instantly.",
"looks_like": "corpse",
"volume": "30000 ml",
"weight": "40750 g",
"volume": "30 L",
"weight": "30 kg",
"material": "hflesh"
},
{
Expand All @@ -94,8 +98,8 @@
"name": "corpse",
"description": "The dead body of a child, riddled by bullets to the extent that you can no longer tell their gender.",
"looks_like": "corpse",
"volume": "30000 ml",
"weight": "40750 g",
"volume": "30 L",
"weight": "30 kg",
"material": "hflesh"
},
{
Expand All @@ -106,8 +110,8 @@
"description": "A dead body of an old woman. Both of her earlobes are torn, several fingers on her hands have been chopped off, and several teeth have been knocked out.",
"//": "Implied that someone hacked off her body parts for jewelry.",
"looks_like": "corpse",
"volume": "40000 ml",
"weight": "52000 g",
"volume": "40 L",
"weight": "52 kg",
"material": "hflesh"
},
{
Expand Down Expand Up @@ -153,8 +157,8 @@
"name": "corpse",
"description": "The dead body of a person. Their forehead bears a large bullet entrance wound. An even larger exit wound is present on the back of their head.",
"looks_like": "corpse",
"volume": "40000 ml",
"weight": "52000 g",
"volume": "40 L",
"weight": "52 kg",
"material": "hflesh"
},
{
Expand All @@ -164,8 +168,8 @@
"name": "corpse",
"description": "The upper half of a dead body, as if torn apart with enormous force. Some organs are hanging out.",
"looks_like": "corpse",
"volume": "30000 ml",
"weight": "40000 g",
"volume": "30 L",
"weight": "40 kg",
"material": "hflesh"
},
{
Expand All @@ -175,8 +179,8 @@
"name": "corpse",
"description": "A half-decapitated dead body. It is unclear what could have caused such a wound.",
"looks_like": "corpse",
"volume": "57000 ml",
"weight": "78000 g",
"volume": "57 L",
"weight": "78 kg",
"material": "hflesh"
}
]
Loading

0 comments on commit e2f8b54

Please sign in to comment.