1 |
[quote]Do Lua scripts need to be compiled for the game to read them?[/quote]
|
1 |
[quote]Do Lua scripts need to be compiled for the game to read them?[/quote]
|
2 |
You don't need to compile Lua scripts, the engine interprets them.
|
2 |
You don't need to compile Lua scripts, the engine interprets them.
|
3 |
\n
|
3 |
\n
|
4 |
[quote]Where would I put the modified lua file after editing it? [/quote]
|
4 |
[quote]Where would I put the modified lua file after editing it? [/quote]
|
5 |
In
the
gadgets
folder.
Check
out
http://zero-k.
info/mediawiki/index.
php?title=Mod_Creation
for
info
on
what
goes
where.
|
5 |
In
the
gadgets
folder.
Check
out
http://zero-k.
info/mediawiki/index.
php?title=Mod_Creation
for
info
on
what
goes
where
and
how
to
set
up
a
local
development
copy.
|
6 |
\n
|
6 |
\n
|
7 |
[quote]Would <unit_cannot_damage_unit.lua> be the correct place to put my code to multiply damage?[/quote]
|
7 |
[quote]Would <unit_cannot_damage_unit.lua> be the correct place to put my code to multiply damage?[/quote]
|
8 |
That gadget is for relationships between two units (in particular Starlight and Glint) so it would probably be ideal to make a new gadget.
|
8 |
That gadget is for relationships between two units (in particular Starlight and Glint) so it would probably be ideal to make a new gadget.
|
9 |
\n
|
9 |
\n
|
10 |
Damage modification is specific though because it is part of unit definitions which can be post-processed, see the `gamedata/{weapon,unit}defs_post.lua`. In particular check their contents for `damagemult` - this is an old modoption that acted as a general multiplier for most damage sources (caveats: didn't affect environmental damage and wasn't configurable per-team), it was removed because `hpmult` does the same but if you're messing around in your local copy might as well try it out.
|
10 |
Damage modification is specific though because it is part of unit definitions which can be post-processed, see the `gamedata/{weapon,unit}defs_post.lua`. In particular check their contents for `damagemult` - this is an old modoption that acted as a general multiplier for most damage sources (caveats: didn't affect environmental damage and wasn't configurable per-team), it was removed because `hpmult` does the same but if you're messing around in your local copy might as well try it out.
|