No Randomness Mod Released
Moderator: Forum Moderators
No Randomness Mod Released
I have seen a lot of people complaining on the forums that they want a mod without randomness. Seriously, every month a see a new topic of this kind, and I keep hearing about people editing the mainline movetypes in order to achieve it, spending hours imagining meaningless formulae for that. Regardless that it would absolutely ruin the idea of terrain defence. I am really, really fed up with this. Randomness is a feature of the game, and it should be kept, and I don't want to see any posts of this kind. Ever.
So I found a way to silence them all. Satisfy these endless demands. I made an add-on that adds a menu option that disables all combat randomness, setting all chances to hit to 100%. Writing the code took me just an hour. Terrain defences will decrease damage instead of decreasing the chance to hit (marksman and magical weapon specials counted in).
It will cause OoS if you have it enabled in multiplayer and others don't, but it should not cause OoS if disabled (should not cause trouble even if you disable it in the game, before the first attack). It may cause trouble with some very complicated add-ons, like Legend of the Invincibles.
It is available on both 1.10 and 1.11 add-on servers.
It contains no WML, so it is quite small, only 5 kilobytes, the main source of its size is the license.
If somebody finds a bug, tell me also the conditions when it occurs, please.
So I found a way to silence them all. Satisfy these endless demands. I made an add-on that adds a menu option that disables all combat randomness, setting all chances to hit to 100%. Writing the code took me just an hour. Terrain defences will decrease damage instead of decreasing the chance to hit (marksman and magical weapon specials counted in).
It will cause OoS if you have it enabled in multiplayer and others don't, but it should not cause OoS if disabled (should not cause trouble even if you disable it in the game, before the first attack). It may cause trouble with some very complicated add-ons, like Legend of the Invincibles.
It is available on both 1.10 and 1.11 add-on servers.
It contains no WML, so it is quite small, only 5 kilobytes, the main source of its size is the license.
If somebody finds a bug, tell me also the conditions when it occurs, please.
Re: No Randomness Mod Released
Didn't Mabuse already make something like this?
Formerly known as the creator of Era of Chaos and maintainer of The Aragwaithi and the Era of Myths.
Re: No Randomness Mod Released
He has made an era. This is not an era, this is something different (not quire sure how to define it). You just install it and turn it on and all fights in all campaigns and eras become deterministic. If Mabuse's era was filling its purpose, people would not come to the forums and ask mods or settings disabling randomness. Mabuse is also an expert on descriptions, it is never anything more informative than a reformulation of the add-on's title.
Re: No Randomness Mod Released
It could easily be converted into a MP modification on 1.11. For the singleplayer aspect... Well I don't think it's big enough to announce it as something to "Satisfy these endless demands.", especially since a version (although it's packed in an era, the coding does the same thing) already exists.He has made an era. This is not an era, this is something different (not quire sure how to define it).
I think that's mostly because people don't know about the era. (just 2340 downloads)If Mabuse's era was filling its purpose, people would not come to the forums and ask mods or settings disabling randomness.
Well maybe this is true for the add-on, but it doesn't mean the add-on itself it bad.Mabuse is also an expert on descriptions, it is never anything more informative than a reformulation of the add-on's title.
Formerly known as the creator of Era of Chaos and maintainer of The Aragwaithi and the Era of Myths.
Re: No Randomness Mod Released
Inserting it into singleplayer, where eras and modifications don't apply (also, MP modifications aren't for the mostly played 1.10, and such a conversion still requires coding abilities most players don't have) is not so trivial. There is no way to do it without lua or modifying core files. The code from that era is very unlikely to be useful for something in singleplayer.It could easily be converted into a MP modification on 1.11. For the singleplayer aspect... Well I don't think it's big enough to announce it as something to "Satisfy these endless demands.", especially since a version (although it's packed in an era, the coding does the same thing) already exists.
Dunno, I didn't now about it neither, and from the description, you can't tell a thing, it can just set all chances to hit to 100% and change the resistances somehow. You can't learn a unit's defence without lua. I am assuming that people wanted the no luck mod for singleplayer, otherwise those who seek it would be using it and glad with it.I think that's mostly because people don't know about the era.
Regarding AI's post in this topic, I think that I am right with this.
Yes, but lame description will not attract anybody.Well maybe this is true for the add-on, but it doesn't mean the add-on itself it bad.
Re: No Randomness Mod Released
very interesting, but I started to get many errors after the first round of fighting (around turn 4/5):
Dugi, can this be modified so that elusive foot can still dodge a % of attacks? Like around 33%? Also, could this be expanded to do a range of the maximum damage, say if the damage was 10-3 you could do 6-10 damage randomly, or if damage is 4 you could do 0-4 randomly, etc. yet still be hitting 100% of the time. To me that'd be perfect. Marksman would have a tighter range, like within +/- 2 instead of 4, And I think magic could still have misses, maybe boost it to 80%-85% hit though. Is this possible within your code?
I thought I saw some discrepancies in thedamage %, but reloading is not showing it, will keep an eye on it though. This is pretty interesting in a lot of ways.
Dugi, can this be modified so that elusive foot can still dodge a % of attacks? Like around 33%? Also, could this be expanded to do a range of the maximum damage, say if the damage was 10-3 you could do 6-10 damage randomly, or if damage is 4 you could do 0-4 randomly, etc. yet still be hitting 100% of the time. To me that'd be perfect. Marksman would have a tighter range, like within +/- 2 instead of 4, And I think magic could still have misses, maybe boost it to 80%-85% hit though. Is this possible within your code?
Re: No Randomness Mod Released
Can you please track the conditions when it happens and when it doesn't happen? It worked for me, but I haven't tested it deeply enough, it seems. I need a reliable way to replicate this error in order to track its cause.very interesting, but I started to get many errors after the first round of fighting (around turn 4/5):
People usually ask for no randomness mods, not for mods with less randomness. If you think that somebody will like something like the thing you suggested, you can do it, it isn't very hard (just the little problem that it's lua) and I might help you.Dugi, can this be modified so that elusive foot can still dodge a % of attacks?
-
- Posts: 15
- Joined: May 28th, 2013, 7:30 pm
Re: No Randomness Mod Released
Thank you for your efforts to make this mod.Dugi wrote:If somebody finds a bug, tell me also the conditions when it occurs, please.
I tested it on the Hamlet MP Map and got a host of errors after every attack. I posted the stderr.txt file on the other thread; I could give you a save game also, but I doubt you'd need it. The error is easily repeatable.
I will try out the add-on in the single-player campaigns and report back.
Thank You,
-DJ
Re: No Randomness Mod Released
It might be worth special mention that it's the in-game, right-mouse menu for anyone who can't find it at first.Dugi wrote:I made an add-on that adds a menu option that disables all combat randomness, setting all chances to hit to 100%.
It's a "Menu Omnimod", it gets its own category, forever.Dugi wrote:This is not an era, this is something different (not quite sure how to define it).
Re: No Randomness Mod Released
Would it help to run wesnoth from the terminal and post the errors from there?Can you please track the conditions when it happens and when it doesn't happen? It worked for me, but I haven't tested it deeply enough, it seems. I need a reliable way to replicate this error in order to track its cause.
just continued from a save with no errors in that scenario btw.
yeah, I checked out the code, I don't get it But, I'm starting to get what this is doing, it was a bit weird at first. I may play through a mainline campaign just to see how it goes. Anyhow, you're the man Dugijust the little problem that it's lua)
Re: No Randomness Mod Released
It is mentioned in the add-on's description.DranKof wrote:It might be worth special mention that it's the in-game, right-mouse menu for anyone who can't find it at first.
Haha, maybe it should be given a name... But I have never seen anything like it before...DranKof wrote:It's a "Menu Omnimod", it gets its own category, forever.
No. The screenshots contain the same information. And I have learned that these problems are a consequence of something I failed to replicate. Sometimes it happens that the attack remains modified, and it remains with lower damage and 100% chance to hit. If this happens, any following attacks with the unit will cause that error. But when I was testing it, it didn't happen even once that a unit's damage remained lowered. I have even added a special mechanism to detect this problem, but it always said 'everything went correctly'.Crow_T wrote:Would it help to run wesnoth from the terminal and post the errors from there?
I thought it was caused by some weird WML, but the MP scenario Hamlets (where D. J. Hollister encountered it) is absolutely simple, it contains just side definitions.
Can you please check if the damages remain correct, find the conditions when it goes incorrect and/or get a save file where the decrease of damage can be replicated?
Can you please try to enter a networked multiplayer game and try if it will cause OoS even when disabled or not? It should not, but it is useful to know for sure.
Re: No Randomness Mod Released
Can you please check if the damages remain correct, find the conditions when it goes incorrect and/or get a save file where the decrease of damage can be replicated?
I can get it to error with this save- move the leader to the keep, bring the archers near the forest/keep. recruit an archer in the west keep tile, end turn. Next turn attack one horse with 3 archers with 9-3 ranged, attack from the keep last. I've attached 2 pics to show the positions. Generally from here it goes haywire, I later had fights where everyone did no damage (0-3 damage)
- Attachments
-
- SotBE-End_of_Peace-Auto-Save4.gz
- (23.48 KiB) Downloaded 629 times
-
- move units here on turn 4
- step_one.jpg (69.33 KiB) Viewed 12836 times
-
- attack with this guy third
- step_two.jpg (59.87 KiB) Viewed 12836 times
Re: No Randomness Mod Released
well, you can learn a units defence without lua.Dugi wrote:Dunno, I didn't now about it neither, and from the description, you can't tell a thing, it can just set all chances to hit to 100% and change the resistances somehow. You can't learn a unit's defence without lua. I am assuming that people wanted the no luck mod for singleplayer, otherwise those who seek it would be using it and glad with it.
no-luck era filters for the defense-value of the opponent
noluck era changes in no way the resistances of the units, terrain-defence is simply used a a multiplier to the damage.
"no-luck-era" mod also takes some of non-mainline-eras "hit-chance changing" weapon-specials into account (era of magic, era of chaos .. ), but of course this has to be updated with every new era that is released.
the code can be very well used in single-player games, i dont see a reason why it should not work there.
(there may be need for slight adaptions, depending on how units are implemented into the game/campaign, by now only units that exist at game-start, recruits, advances and "sighted" units are affected by the code)
The best bet is your own, good Taste.
Re: No Randomness Mod Released
Thanks. I hope it will happen also on my machine.Crow_T wrote:I can get it to error with this save- move the leader to the keep, bring the archers near the forest/keep. recruit an archer in the west keep tile, end turn. Next turn attack one horse with 3 archers with 9-3 ranged, attack from the keep last. I've attached 2 pics to show the positions. Generally from here it goes haywire, I later had fights where everyone did no damage (0-3 damage)
EDIT: Learned two things:
1. My previous assumption that the error is a consequence of something is wrong, it just sometimes miscalculates.
2. The error is never replicable, it appears spontaneously (however, it causes the units that were affected by this bug to continue causing this problem).
EDIT #2: Found the cause. The wesnoth engine behaved a bit differently than I thought sometimes.
EDIT #3: Fixed it. Version 1.1 is out. I also improved its compatibility with some core WML macros.
Exactly the same here.Mabuse wrote:noluck era changes in no way the resistances of the units, terrain-defence is simply used a a multiplier to the damage.
Well, there was a way to do it, but not quite elegant, you can't just use a command to learn a unit's defence.Mabuse wrote:no-luck era filters for the defense-value of the opponent
Yes, but you would have to attach the code into all scenarios (well, or a macro replacing it, but still edit them), and that is not what most regular wesnoth users can do. With the lua trick I used, you just install it and have it available everywhere.Mabuse wrote:the code can be very well used in single-player games, i dont see a reason why it should not work there.
Re: No Randomness Mod Released
I just continued from the turn 4 save, finished that scenario and the next with no errors, nice work This is pretty fun, well except vs thunderguards and fencers I am going to play through SotBE in this mode, I'll keep you updated on any weirdness.