Daggerfall Mechanics thread: Volunteers welcome
-
- Posts: 195
- Joined: Thu Apr 02, 2015 9:03 am
Re: Daggerfall Mechanics thread: Volunteers welcome
No problem man. It never hurts to re-check twice.
- Midknightprince
- Posts: 1324
- Joined: Fri Aug 11, 2017 6:51 am
- Location: San Antonio TX
- Contact:
Re: Daggerfall Mechanics thread: Volunteers welcome
I hope this is the right place to put this..
I was testing the magic, in DFU, the magic looks like it stacks, like 1 levitate spell for maybe 2 rounds will go to 4 if you cast it twice.
Same with AOE spells, like if you hit yourself with a DOT by accident.
I really dont rem how it is in classic, so you guys are gonna have to tell me
I'm just letting you know how its playing.
I was testing the magic, in DFU, the magic looks like it stacks, like 1 levitate spell for maybe 2 rounds will go to 4 if you cast it twice.
Same with AOE spells, like if you hit yourself with a DOT by accident.
I really dont rem how it is in classic, so you guys are gonna have to tell me
I'm just letting you know how its playing.
Check out my YouTube Channel!
- Jay_H
- Posts: 4070
- Joined: Tue Aug 25, 2015 1:54 am
- Contact:
Re: Daggerfall Mechanics thread: Volunteers welcome
My earlier testing indicated durations are supposed to stack when cast multiple times, so that's working as intended. Good question.
- Interkarma
- Posts: 7243
- Joined: Sun Mar 22, 2015 1:51 am
Re: Daggerfall Mechanics thread: Volunteers welcome
Yep, that's exactly how classic works. Most spells with a Duration component will just stack duration. The effect scripting system is pretty flexible so this can be changed easily at any time if I get it wrong.
Internally, the effect system has a special type of class called IncumbentEffect. For any effect that wants to follow this behaviour, the script only needs to inherit from IncumbentEffect and implement two things: a) what happens when becoming incumbent, and b) what happens when a duplicate effect is applied.
Have a look at the Levitate.cs script to see how this is done. When a second copy of the effect is applied to entity, it will call AddState(). In this case, it just stacks duration. Could do literally anything here instead. Effects are crazy flexible.
Internally, the effect system has a special type of class called IncumbentEffect. For any effect that wants to follow this behaviour, the script only needs to inherit from IncumbentEffect and implement two things: a) what happens when becoming incumbent, and b) what happens when a duplicate effect is applied.
Have a look at the Levitate.cs script to see how this is done. When a second copy of the effect is applied to entity, it will call AddState(). In this case, it just stacks duration. Could do literally anything here instead. Effects are crazy flexible.
- Jay_H
- Posts: 4070
- Joined: Tue Aug 25, 2015 1:54 am
- Contact:
Re: Daggerfall Mechanics thread: Volunteers welcome
So when we want (next year) to add in custom spell effects, what'll that look like system-wise? Adding a new .cs file to the rig that the game could detect? Or is it too early to tell?
- Interkarma
- Posts: 7243
- Joined: Sun Mar 22, 2015 1:51 am
Re: Daggerfall Mechanics thread: Volunteers welcome
That's pretty much it. My plan right now is that you will script effects in C# and package them up as a .dfmod. The mod will need to register them into the EntityEffectBroker (using a hook that hasn't been exposed yet). The scripts themselves just need to inherit from EntityEffect, IncumbentEffect, DiseaseEffect, etc. and override some virtual functions to run their payload. Effect scripts can be very simple (e.g. HealHealth) or rather elaborate (e.g. base DiseaseEffect).
The core scripts that are part of the base game will benefit from tightest integration with core systems. But effect script mods can still touch anything in game the usual mod system can touch - which means effect scripts can do loads of cool stuff from the very mundane to the absolutely fantastical. It just depends how much time and effort the developer wants to put into them. And because they're a mod, you can bundle textures, models, shaders, sound effects - pretty much anything you want - to deliver that effect to the player.
There are a few bits that technically aren't part of effect system. For example, you can't add new element types or target types to spellmaker. This is just part of the basic game design. But in terms of what an effect can do there are few limits. I'm looking forward to seeing what people do with it in future.
- Biboran
- Posts: 277
- Joined: Thu Jun 25, 2015 8:26 pm
Re: Daggerfall Mechanics thread: Volunteers welcome
I don't know if is this right place toask, but I readed a little bit about daggerfall crime and punishment system
http://www.tesguides.com/tes2/misc/legaltip.htm
Looks like vanilla daggerfall had two major problems with it - that guards continue to attack player while court UI shown so you will get worse condition ammunition after relise from prison and second - that guards hunt after you for last type of crime you did, i.e.:
Also there are two types of crime that unachivable in vanilla game
http://www.tesguides.com/tes2/misc/legaltip.htm
Looks like vanilla daggerfall had two major problems with it - that guards continue to attack player while court UI shown so you will get worse condition ammunition after relise from prison and second - that guards hunt after you for last type of crime you did, i.e.:
It be possible to fix or change in unity? Like you will be impisoned for most horrible type of crime you did, not the last one and that guards will not attack you while you in courtIf there’s no way to get away from the guards, pick their pockets before the surrender message pops up. The game records the last crime you committed as the crime you are charged with. Thus, you can kill everyone in town and all but one of the guards, pick that guard’s pocket and you’ll be charged with one count of pickpocketing instead of premeditated mayhem
Also there are two types of crime that unachivable in vanilla game
Crimes which exist in the game, but you can’t be charged with (caution! it may be possible to be charged with these crimes, but I haven’t managed to key the right sequence of events):
High Treason: one of the crimes on the wish list for many players looking forward to TES3 (tentatively titled “Morrowind”). Essentially you endanger or kill the head honcho. Can’t do it in the game, but don’t think the idea hasn’t crossed the mind of many a player.
Assault: Smacking someone (has to be a guard since townspeople only have 1 hit point), but not actually managing to kill them. I’ve never managed to be charged with assault since if I’m going to hit someone, I’m going to hit them hard enough to kill them.
-
- Posts: 379
- Joined: Fri Oct 07, 2016 10:41 am
Re: Daggerfall Mechanics thread: Volunteers welcome
I did the guard work so far. Yes, it could be fixed, but I was focusing on getting the original game's behavior recreated. I've never noticed guards in the original game hitting the player while in court.It be possible to fix or change in unity? Like you will be impisoned for most horrible type of crime you did, not the last one and that guards will not attack you while you in court
Not only two. These are crime types in the game files that I'm not aware it is possible to get:Also there are two types of crime that unachivable in vanilla game
Trespassing
Assault
Tax Evasion
Smuggling
Piracy
High Treason
Treason
- Interkarma
- Posts: 7243
- Joined: Sun Mar 22, 2015 1:51 am
Re: Daggerfall Mechanics thread: Volunteers welcome
Hey ifkopifko!ifkopifko wrote: ↑Thu May 10, 2018 8:22 am EDIT: For the sake of completeness, I'll attach the latest excel file for spells, with correct a, b, and offsetGold values. Remember that "factor" is not needed anymore, so in future when adding new spells, remember that in MakeEffectCosts you only need to define (a, b, offsetGold).
I'm building out a few more effects now and found the "Water Breathing 50" values in Spell Effects Edited 23 don't produce the same costs as classic. If you get a chance, is this something you'd be willing to take another look at?
So far everything else is matching fine (including Water Walking). I'll let you know if I find any other effect costs not matching classic.
You're probably also interested in knowing that Allofich/R.D. has re-implemented cost formulas from classic. I'm looking at using a fallback to classic cost calculations when the integrated effect costs are undefined. This obviously can't be used for modded effects later, but it another way of grabbing the cost value for classic effects. It's also interesting to see how this was coded in classic.
-
- Posts: 195
- Joined: Thu Apr 02, 2015 9:03 am
Re: Daggerfall Mechanics thread: Volunteers welcome
Hi there!
Firstly, I am very excited to see your progress. (With this I mean all the contributors/developers.)
About the “Water Breathing 50”, I do not see what you mean, the match seems perfect to me in the excel file.
One thing to note though, in the whole excel file, there is a mismatch of raw values of magicka costs (those read from classic). Some are for “the effect cost”, which can go below 5 spellpoints, some are obviously for the “finished spell” (including all added effects), that cost never goes below 5 spellpoints. If I recall correctly, this has not been addressed in the formulas at the time I have messed with your code. My bad, I did not realise it at the time.
I can see it is handled in the “Allofich’s classic formula”: https://github.com/Interkarma/daggerfal ... r.cs#L1585
If there is some other disagreement for this spell effect between classic and the excel formulas, please let me know, I am not aware of any.
Thanks for the info of re-implementation of classic formulas… that seems like a clean way to match the classic. I will surely take a detailed look at it when time allows (supposing that I will be able to wrap my head around it). Now you can choose which way is better to use.
Firstly, I am very excited to see your progress. (With this I mean all the contributors/developers.)
About the “Water Breathing 50”, I do not see what you mean, the match seems perfect to me in the excel file.
One thing to note though, in the whole excel file, there is a mismatch of raw values of magicka costs (those read from classic). Some are for “the effect cost”, which can go below 5 spellpoints, some are obviously for the “finished spell” (including all added effects), that cost never goes below 5 spellpoints. If I recall correctly, this has not been addressed in the formulas at the time I have messed with your code. My bad, I did not realise it at the time.
I can see it is handled in the “Allofich’s classic formula”: https://github.com/Interkarma/daggerfal ... r.cs#L1585
If there is some other disagreement for this spell effect between classic and the excel formulas, please let me know, I am not aware of any.
Thanks for the info of re-implementation of classic formulas… that seems like a clean way to match the classic. I will surely take a detailed look at it when time allows (supposing that I will be able to wrap my head around it). Now you can choose which way is better to use.