Loading...
  OR  Zero-K Name:    Password:   

ZK modders' dream

3 posts, 229 views
Post comment
Filter:    Player:  
sort
Should I make a mod "ZK modders'(my) dream"?

The aim of the mod is to get rid of the endless annoying replacing files,

let "a script contains tables" -> "a script that read files to gen tables",

makes zk more extensible, mb even multiple extension (aka combine mods.)

example:

LuaRules/Configs/drone_defs.lua is a script containing information about how units make drones.

If you want your new units to make drones, you need to override it (copy the file, put your addition in it, and replace the origin one).

ZK modders' dream will override it with the ability to read units make drones information from unitdefs, then you just need to add something in your UnitDefs.

(Actually I think they should be put in zk-stable, but zk updates is sloooow)
+1 / -0
Current tech:

(utils : Spring.Utilities.wacky_utils, utils_op : Spring.Utilities.to_make_op_things)

unitdefs_post.lua:
run codes in gamedata/tweak_unit_defs,
utils_op .load_modoptions(): load optional things at lua_mods and mods.
utils_op .RunUnitDefsTweakFns(): run optional code for unitdefs.

weapondefs_post.lua:
run codes in gamedata/tweak_weapon_defs,
utils_op.RunOrderedList(utils_op.weapon_defs_tweak_fns): run optional code for weapondefs.

gamedata/modularcomms:
put chassisdefs, moduledefs into files

movedefs.lua:
utils_op.MoveDef_TryGen: automatically generate movedef for unknow movedef found in Unitdefs.


LuaRules/Configs/tactical_ai_defs.lua: load tactical_ai_defs from ud.customParams

LuaRules/Configs/drone_defs.lua: load carrierDefs from ud.customParams

LuaRules/Configs/oneclick_weapon_defs.lua: load oneClickWepDefs from ud.customParams

LuaRules/Utilities/unitDefReplacements.lua: use ud.customParams.custom_tooltip_simple as units tip, allow UnitRulesParam in it

LuaUI/Widgets/gui_chili_cheats.lua: put uds that ud.customParams.is_debug_unit into tab debug

ud.customParams.def_scale: a easy way to scale unitdefs

TODO:

unit_attributes_generic.lua: load attribute handler from files.

LuaRules/Utilities/unitDefReplacements.lua: allow code.

Fell free to add things
+2 / -0
Problem.

I made Zk Modders Dream v0.0.0.3 and _Silly Wars dev.sdd.
Zk Modders Dream v0.0.0.3/modinfo.lua:
return {
	name='ZK Modders Dream',
	description='later',
	version='v0.0.0.3',
	shortname='ZKMD',
	mutator='1',
	game='Zero-K',
	shortGame='ZK',
	modtype=1,
	depend = {
		[[rapid://zk:stable]],
	},
}

_Silly Wars dev.sdd/modinfo.lua:
return {
	name='_Silly Wars dev',
	description='https://github.com/XNTEABDSC/Silly-Wars/wiki',
	version='v0.8.1.1',
	shortname='ZKSW',
	mutator='1',
	game='Zero-K',
	shortGame='ZK',
	modtype=1,
	depend = {
		-- [[rapid://zk:stable]],
		[[ZK Modders Dream v0.0.0.3]],
	},
}



When I ran game at local, Game stucked at "Waiting for server to start", infolog_full.txt said it only AddArchive "Chobby v1.13.4.1" "Spring content v1" "Spring Bitmaps" "Spring Cursors" then some DLL error had thrown, Zero-K.exe Information: 0 : Spring exited.

(ZK Modders Dream is playable)
(wait my test game can work)
(wait it works if I zip. It seems caused by some extra files)
+0 / -0