Skip to content

Commit 9f0a276

Browse files
committed
Changes for 1.30
1 parent 20df820 commit 9f0a276

File tree

5 files changed

+84
-145
lines changed

5 files changed

+84
-145
lines changed

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
Package/
2+
Release/
3+
Temp/

Source/Docs/mod_page.txt

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,13 @@ cheat_set_regen enable:true state:stamina amount:10
4040

4141
[b][size=6]Change Log[/size][/b]
4242

43+
[b]1.30[/b]
44+
[list]
45+
[*]Moved to github.
46+
[*]Changed install.sh to generic release.sh without any absolute paths.
47+
[*]See github 1.30 milestone for merged pull requests.
48+
[/list]
49+
4350
[b]1.29[/b]
4451
[list]
4552
[*]Merged latest defaultProfile.xml.

Source/Scripts/Startup/main.lua

Lines changed: 1 addition & 135 deletions
Original file line numberDiff line numberDiff line change
@@ -1,142 +1,8 @@
1-
--[[
2-
TODO
3-
=====================================================================
4-
-- localize items, perks, skills, buffs
5-
-- spawn enemies/entities
6-
-- dummy quest to grant rep
7-
-- alter Charisma, Noise, Visibility, Speed
8-
-- complete a quest
9-
-- gravity
10-
-- removes fog of war, but also unlocks all on the map? Camp sites, graveyards, caves etc?
11-
-- player speed
12-
-- horse speed
13-
-- max skills, stats
14-
15-
Change Log
16-
=====================================================================
17-
1.29
18-
-- Merged latest defaultProfile.xml.
19-
-- Fixed documentation error on command cheat_set_horse.
20-
-- Released additional version of mod without any key bindings.
21-
22-
1.27/1.28
23-
-- Merged 1.4.1 action map.
24-
25-
1.26
26-
-- The cheat_spawn command now had radius option and can spawn guards.
27-
28-
1.25
29-
-- Removed version section from mod.manifest since it works like shit.
30-
31-
1.24
32-
-- Added cheat_spawn and cheat_spawn_npc.
33-
-- Added required health argument to cheat_damage_all_items.
34-
35-
1.23
36-
-- Fixed startup logging so missing autocheat.txt isn't logged as an error.
37-
-- Added cheat_target_entity command bound to F4.
38-
-- Added cheat_kill_target comand to kill an entity targeted with F4 or the cheat_target_entity command.
39-
-- Added cheat_damage_all_items.
40-
41-
1.22
42-
-- Added support for GOG versions.
43-
44-
1.21
45-
-- Fixed packaging issues causing wrong file to get uploaded to nexus.
46-
47-
1.20
48-
-- Switched mod to use new 1.3 mod structure
49-
-- Mod should now be unzipped into steamapps\common\KingdomComeDeliverance\Mods
50-
-- See https://wiki.nexusmods.com/index.php/Modding_guide_for_KCD
51-
52-
1.19
53-
-- Fixed a bug with autocheat.txt not loading.
54-
55-
1.18
56-
-- Added cheat_exec_file and cheat_exec_delay.
57-
58-
Create Data\exec.txt will following 6 lines:
59-
cheat_exec_delay ms:5000
60-
cheat_eval cheat:logWarn("1")
61-
cheat_exec_delay ms:5000
62-
cheat_eval cheat:logWarn("2")
63-
cheat_exec_delay ms:5000
64-
cheat_eval cheat:logWarn("3")
65-
66-
Run command cheat_exec_file file:Data\exec.txt
67-
68-
1.17
69-
-- Added cheat_set_weather.
70-
71-
1.16
72-
-- Added cheat_kill_npc to kill matching NPCs within a specified radius of the player.
73-
74-
1.15
75-
-- Added cheat_stash to open player's stash.
76-
-- Added max parameter to cheat_teleport_npc_to_loc to limit total number of NPCs teleported.
77-
-- Added max parameter to cheat_teleport_npc_to_player to limit total number of NPCs teleported.
78-
-- Changed cheat_find_npc, cheat_teleport_npc_to_loc, and cheat_teleport_npc_to_player to work with any actor like hare, pig, deer, etc.
79-
-- Added cheat_add_buff_invisible and cheat_remove_buff_invisible
80-
81-
1.14
82-
-- Added cheat_find_npc to display an NPC's location assuming the NPC has been loaded into the game world.
83-
-- Added cheat_teleport_npc_to_loc to teleport one or more NPCs to a specific x,y,z location.
84-
-- Added cheat_teleport_npc_to_player to teleport one or more NPCs to the player's location.
85-
-- Added cheat_teleport_horse to teleport the player's horse to the player's location.
86-
87-
1.13
88-
-- Excluded Always Drunk perk from cheat_add_all_perks
89-
-- Added cheat_loc to get player's location on map
90-
-- Fixed cheat_teleport so it actually works
91-
92-
1.12
93-
-- Added required "exclude" argument to cheat_add_all_perks to control excluding negative, test, and obsolete perks.
94-
-- Added cheat_teleport
95-
-- Added cheat_phys_hover (F1 key)
96-
-- Added cheat_phys_push (F2 key)
97-
-- Added cheat_phys_sprint (F3 key)
98-
99-
1.11
100-
-- Added actionmap with F5 quicksave keybind
101-
102-
1.10
103-
-- Added cheat_remove_all_stolen_items
104-
-- Added cheat_own_all_stolen_items
105-
-- Added cheat_repair_all_items
106-
107-
1.9
108-
-- Added cheat_reveal_map
109-
-- Fixed cheat_set_bow_reticle
110-
-- Added cheat_get_time, cheat_set_time_speed, cheat_set_time_paused
111-
112-
1.8
113-
-- Automatically run cheats when after you load a level. Create file Data\autocheat.txt and put 1 console command per line in the file.
114-
-- cheat_remove_all_buffs - Attempts to remove every buff in the buff database from the player's character.
115-
-- cheat_add_buff_heal - Now restores health, stamina, hunger, and exhuast in addition to bleeding and injuries.
116-
-- cheat_add_buff_immortal - Now calls cheat_add_buff_heal before adding immortal buffs.
117-
-- cheat_remove_all_perks - Attempts to remove every perk in the perk database from the player's character.
118-
-- cheat_add_all_items - Adds all items in the item database to the player inventory which is about 5300 punds of items. Don't worry somehow you can still walk.
119-
-- cheat_add_stat_xp -- Adds XP to the a player's stat like str.
120-
--]]
121-
122-
123-
124-
-- player.actorStats.flatSpeed
125-
-- player type=table, class=Player, methods=yes metamethods=yes
126-
-- player.player type=table methods=no metamethods=yes
127-
-- player.human type=table methods=no metamethods=yes
128-
-- player.actor type=table methods=no metamethods=yes
129-
-- player.soul tyle=table methods=no metamethods=yes
130-
131-
-- XGenAIModule.SendMessageToEntity(player.this.id, 'haste:instruction:tree', "xmlFileName('final/haste/common.xml'), treeName('makePlayerInvisible')")
132-
-- <SendMessageToNPC target="__player" type="instruction:request" values="includeXml(&apos;player.xml&apos;), includeTree(&apos;dropCarriedBody&apos;)" timeType="GameTime" timeoutType="OnProcessed" timeout="-1" answer="" />
133-
134-
1351
System.LogAlways("@@@@@@@@@ cheat mod main.lua called @@@@@@@@")
1362

1373
cheat={}
1384
cheat.versionMajor = 1
139-
cheat.versionMinor = 29
5+
cheat.versionMinor = 30
1406
cheat.isInsideIde = NPC_NAI_x == nil
1417
cheat.devHome = "/home/mikeno/FAST/Projects/Cheat"
1428
cheat.commands = {}

install.sh

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/bin/bash -xe
22
MOD_NAME="Cheat"
3-
MOD_DIR="/home/mikeno/FAST/Projects/${MOD_NAME}"
3+
MOD_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
44
MOD_DESC="https://www.nexusmods.com/kingdomcomedeliverance/mods/106"
55
MOD_AUTHOR="spraguep"
66
MOD_CLASS=""
@@ -12,7 +12,6 @@ function packageRelease() {
1212
REL_DIR="${MOD_DIR}/Release"
1313
PKG_DIR="${MOD_DIR}/Package"
1414
TMP_DIR="${MOD_DIR}/Temp"
15-
INSTALL_DIR="/home/mikeno/FAST/Games/SteamLibrary/steamapps/common/KingdomComeDeliverance/Mods"
1615

1716
VERSION_MAJOR=$(grep "cheat.versionMajor =" "${SRC_DIR}/Scripts/Startup/main.lua" | sed 's/[^0-9]*//g')
1817
VERSION_MINOR=$(grep "cheat.versionMinor =" "${SRC_DIR}/Scripts/Startup/main.lua" | sed 's/[^0-9]*//g')
@@ -63,14 +62,6 @@ EOF
6362
mkdir -p "${REL_DIR}"
6463
cd "${PKG_DIR}"
6564
7za a -tzip "${REL_DIR}/${MOD_NAME}${MOD_CLASS}-${VERSION}.zip" ./*
66-
67-
# Install new release package
68-
if [[ -d "${INSTALL_DIR}/${MOD_NAME}" ]]; then
69-
rm -rf "${INSTALL_DIR}/${MOD_NAME}"
70-
fi
71-
mkdir -p "${INSTALL_DIR}"
72-
cd "${INSTALL_DIR}"
73-
7za x "${REL_DIR}/${MOD_NAME}${MOD_CLASS}-${VERSION}.zip"
7465
}
7566

7667
# normal release

release.sh

Lines changed: 72 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,72 @@
1+
#!/bin/bash -xe
2+
MOD_NAME="Cheat"
3+
MOD_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
4+
MOD_DESC="https://www.nexusmods.com/kingdomcomedeliverance/mods/106"
5+
MOD_AUTHOR="spraguep"
6+
MOD_CLASS=""
7+
8+
function packageRelease() {
9+
local NOKEYS="${1}"
10+
11+
SRC_DIR="${MOD_DIR}/Source"
12+
REL_DIR="${MOD_DIR}/Release"
13+
PKG_DIR="${MOD_DIR}/Package"
14+
TMP_DIR="${MOD_DIR}/Temp"
15+
16+
VERSION_MAJOR=$(grep "cheat.versionMajor =" "${SRC_DIR}/Scripts/Startup/main.lua" | sed 's/[^0-9]*//g')
17+
VERSION_MINOR=$(grep "cheat.versionMinor =" "${SRC_DIR}/Scripts/Startup/main.lua" | sed 's/[^0-9]*//g')
18+
VERSION="${VERSION_MAJOR}.${VERSION_MINOR}"
19+
20+
# Delete package folder if it already exists
21+
if [[ -d "${PKG_DIR}" ]]; then
22+
rm -rf "${PKG_DIR}"
23+
fi
24+
25+
# Setup package folder structure
26+
mkdir -p "${PKG_DIR}/${MOD_NAME}/Data"
27+
28+
# Create manifest file
29+
cat <<EOF > "${PKG_DIR}/${MOD_NAME}/mod.manifest"
30+
<?xml version="1.0" encoding="utf-8"?>
31+
<kcd_mod>
32+
<info>
33+
<name>${MOD_NAME}</name>
34+
<description>${MOD_DESC}</description>
35+
<author>${MOD_AUTHOR}</author>
36+
<version>${VERSION}</version>
37+
<created_on>$(date)</created_on>
38+
</info>
39+
</kcd_mod>
40+
EOF
41+
42+
# clone source dir
43+
mkdir -p "${TMP_DIR}"
44+
cp -r "${SRC_DIR}" "${TMP_DIR}"
45+
46+
# delete default profile?
47+
if [[ "${NOKEYS}" == "TRUE" ]]; then
48+
rm -rf "${TMP_DIR}/Source/Libs/Config/defaultProfile.xml"
49+
MOD_CLASS="-NOKEYS"
50+
fi
51+
52+
# Create new data pak file
53+
cd "${TMP_DIR}/Source"
54+
7za a -mx=0 -tzip "${PKG_DIR}/${MOD_NAME}/Data/data.pak" ./*
55+
56+
# Remove old release package
57+
if [[ -f "${REL_DIR}/${MOD_NAME}${MOD_CLASS}-${VERSION}.zip" ]]; then
58+
rm "${REL_DIR}/${MOD_NAME}${MOD_CLASS}-${VERSION}.zip"
59+
fi
60+
61+
# Create new release package
62+
mkdir -p "${REL_DIR}"
63+
cd "${PKG_DIR}"
64+
7za a -tzip "${REL_DIR}/${MOD_NAME}${MOD_CLASS}-${VERSION}.zip" ./*
65+
66+
}
67+
68+
# normal release
69+
packageRelease "FALSE"
70+
71+
# release without key bindings
72+
packageRelease "TRUE"

0 commit comments

Comments
 (0)