Mod Question Repository... Questions come in, answers go out
Moderator: Moderators
- CarRepairer
- Cursed Zero-K Developer
- Posts: 3359
- Joined: 07 Nov 2007, 21:48
Re: Mod Question Repository... Questions come in, answers go out
Question regarding endgame stats damage dealt:
1) Does it calculate all damage done or only that done to enemies?
2) Does it include paralyzer damage?
3) Does it calculate the damage done by the weapon or is there a cap on the unit's max HP? For example when you dgun a flea does it count as 20 damage or 99999? (This has to be taken into account in lua's unitdamaged as it results in the 99999.)
The reason I'm asking is I want to write an accurate description for why awards in CA/PW don't always match the endgame stats chart.
1) Does it calculate all damage done or only that done to enemies?
2) Does it include paralyzer damage?
3) Does it calculate the damage done by the weapon or is there a cap on the unit's max HP? For example when you dgun a flea does it count as 20 damage or 99999? (This has to be taken into account in lua's unitdamaged as it results in the 99999.)
The reason I'm asking is I want to write an accurate description for why awards in CA/PW don't always match the endgame stats chart.
- Evil4Zerggin
- Posts: 557
- Joined: 16 May 2007, 06:34
Re: Mod Question Repository... Questions come in, answers go out
Code: Select all
void CUnit::DoDamage(const DamageArray& damages, CUnit *attacker,const float3& impulse, int weaponId)
[...]
if (paralyzeTime == 0) { // real damage
if (damage > 0.0f) {
// Dont log overkill damage (so dguns/nukes etc dont inflate values)
const float statsdamage = std::max(0.0f, std::min(maxHealth - health, damage));
if (attacker) {
gs->Team(attacker->team)->currentStats.damageDealt += statsdamage;
}
gs->Team(team)->currentStats.damageReceived += statsdamage;
health -= damage;
}
- CarRepairer
- Cursed Zero-K Developer
- Posts: 3359
- Joined: 07 Nov 2007, 21:48
-
- Posts: 1176
- Joined: 23 Aug 2007, 19:46
Re: Mod Question Repository... Questions come in, answers go out
Is it possible to define an icon for "unknown" enemy radar dots? And if not is it the "default" radar icon that gets used for this so I'd have to make the default icon the "unknown symbol" and assign specific icons in the units' FBIs?
EDIT:
Ah ok - the default icon is the one which gets used for unknown radar dots. Still it would be more comfortable if there is an entry just for this as otherwise I'd have to edit lots of FBIs...
EDIT:
Ah ok - the default icon is the one which gets used for unknown radar dots. Still it would be more comfortable if there is an entry just for this as otherwise I'd have to edit lots of FBIs...

- Pressure Line
- Posts: 2283
- Joined: 21 May 2007, 02:09
Re: Mod Question Repository... Questions come in, answers go out
lazy prick[Krogoth86] wrote:Is it possible to define an icon for "unknown" enemy radar dots? And if not is it the "default" radar icon that gets used for this so I'd have to make the default icon the "unknown symbol" and assign specific icons in the units' FBIs?
EDIT:
Ah ok - the default icon is the one which gets used for unknown radar dots. Still it would be more comfortable if there is an entry just for this as otherwise I'd have to edit lots of FBIs...

and arent there mass-editing tools for FBI anyway?
Re: Mod Question Repository... Questions come in, answers go out
Does anybody know a way to force a mod to use fixed start positions? I have a mini-game I've been wanting to do, and time to do it today, since this is un-planned time... but I was thinking that I needed to do this, to make it work. Any ideas?
Re: Mod Question Repository... Questions come in, answers go out
No but I suppose if you want to force fixed the mod is limited to a fixed set of maps too? In that case you could just use Lua to move everyone to the fixed starting position (maybe even base it on proximity if you want people to pick which of the fixed positions they'd like). Pong uses fixed starting rectangles that are enforced with Lua (and also used for determining who's on which team)
Re: Mod Question Repository... Questions come in, answers go out
Yeah, for beta 1, I was thinking that would be best, for the particular gameplay I wanted to achieve.No but I suppose if you want to force fixed the mod is limited to a fixed set of maps too?
That's ideally, though. It's not quite as limited in scope as Pong. It probably doesn't matter, I think players behaviors will become logical, when they understand the rules.
Re: Mod Question Repository... Questions come in, answers go out
Question regarding starting a new game from scratch, was there a default mod base created at some point?
-
- Posts: 1176
- Joined: 23 Aug 2007, 19:46
Re: Mod Question Repository... Questions come in, answers go out
AFAIK Argh once created sort of an "empty modfile" - I also think I saw that once in one of the early PURE versions included in the file. You might want to ask him about it...
Re: Mod Question Repository... Questions come in, answers go out
I have one.Sheekel wrote:Question regarding starting a new game from scratch, was there a default mod base created at some point?
Meant to be the absolute minimum for spring to run without any error messages, though it's not 100% uptodate for 77b5
- Attachments
-
- MDK_Phase1.sdd.rar
- (2.55 KiB) Downloaded 166 times
Re: Mod Question Repository... Questions come in, answers go out
N.B., it would *run* with certain files not being there, without exiting, but you would get errors in chat.
edit: also note that all the files are in lua format where possible, may as well avoid FBI/TDF if you are starting from nothing.
edit: also note that all the files are in lua format where possible, may as well avoid FBI/TDF if you are starting from nothing.

Re: Mod Question Repository... Questions come in, answers go out
if i use luadefs I presume i can change values on the fly?
ingame unit customization is of vital importance to the success of my game
ingame unit customization is of vital importance to the success of my game
Re: Mod Question Repository... Questions come in, answers go out
Many thanks for that "empty" mod folder! I found it very useful :). And I agree that it's good to have everything in lua if your starting afresh anyway. I was thinking of putting together an "skeleton" like this just for my own use, but you saved me that effort, so I really am grateful :D!
Re: Mod Question Repository... Questions come in, answers go out
No, luadefs make no difference to the result. You can modify your unitdefs in unitdefs_post.lua (works on fbis too AFAIK) but after that they're read-only. Customization can be done in other ways.Sheekel wrote:if i use luadefs I presume i can change values on the fly?
ingame unit customization is of vital importance to the success of my game
- bobthedinosaur
- Blood & Steel Developer
- Posts: 2702
- Joined: 25 Aug 2004, 13:31
Re: Mod Question Repository... Questions come in, answers go out
is there a way to call a cob explosion to destroy a piece but doesnt have an annoying flash attached to it?
- Evil4Zerggin
- Posts: 557
- Joined: 16 May 2007, 06:34
Re: Mod Question Repository... Questions come in, answers go out
What exactly do you mean by "destroy"? If you want it to just disappear, you can use hide [piece];. Otherwise you're out of luck as far as COB goes (unless you make the default heatcloud invisible).
- bobthedinosaur
- Blood & Steel Developer
- Posts: 2702
- Joined: 25 Aug 2004, 13:31
Re: Mod Question Repository... Questions come in, answers go out
well i wanted to kill a piece primarily for stopping the weapon but i guess i could just jam it instead
- Evil4Zerggin
- Posts: 557
- Joined: 16 May 2007, 06:34
Re: Mod Question Repository... Questions come in, answers go out
Hiding/exploding a piece won't stop a weapon. In fact exploding a piece won't even hide it.