Page MenuHomeWildfire Games

wraitii (Lancelot)
Animal

Projects

User Details

User Since
Dec 21 2016, 1:38 PM (139 w, 1 d)

Recent Activity

Today

wraitii added a comment to D1670: Singleton g_Game and g_SoundManager.
In D1670#92067, @elexis wrote:

It doesnt change semantics, does it? Only syntax.

Mh, yes.

Fri, Aug 23, 11:12 AM
wraitii requested changes to D1670: Singleton g_Game and g_SoundManager.

I don't believe this change is worth committing as it stands, as Vlad said this only changes semantics (arguably making them worse since the new code is longer).
It's ever so slightly annoying for svn-blame to change so many lines, and to me the cost vs win calculation is negative here.

Fri, Aug 23, 9:49 AM
wraitii requested changes to D2064: Move "PlayersToDamage" from calling functions to to "CauseSplashDamage" and replace it with FF..

This needs a new rebase.

Fri, Aug 23, 9:40 AM
wraitii accepted D2115: Improve support of classes of bonuses..

Thanks for the split, much easier to be confident that we aren't introducing weird bugs now :)

Fri, Aug 23, 9:25 AM
wraitii requested changes to D2138: Tooltips for D2092/rP22754..

Thanks for taking a jab at this :)

Fri, Aug 23, 9:23 AM
wraitii added a comment to D2138: Tooltips for D2092/rP22754..
In D2138#92011, @elexis wrote:

This patch fixes the tooltips after D2092/rP22754.

Fixes the tooltips? Did that commit break them?

Fri, Aug 23, 7:45 AM

Yesterday

wraitii abandoned D2081: Add status effects support to splash, melee and death damage..

Done in D2092. Thanks for the patch which gave me the idea for that one :)

Thu, Aug 22, 8:13 PM
wraitii added a comment to D368: Gameplay Scripting: Entity and Actor coding for Secondary Attacks.

@bb: I've committed rP22754, making "Damage" and "Capture" not based on the attack names, allowing you to drop that from this diff.
I think you'll find my final decision OK with regards to how templates get written.
If not, feel free to discuss this by PM or on a forum thread or through the audit feature or something.

Thu, Aug 22, 8:10 PM
wraitii committed rP22754: Generalise Attack effects. All attacks, including death damage and splash, can….
Generalise Attack effects. All attacks, including death damage and splash, can…
Thu, Aug 22, 8:00 PM
wraitii closed D2092: Generalise Attack effects - any attack can do damage, capture, inflict status effects, including splash. Also damage bonuses..
Thu, Aug 22, 8:00 PM
wraitii committed rP22753: Make Promotion.js use the common Transform helper, add resource gatherer and….
Make Promotion.js use the common Transform helper, add resource gatherer and…
Thu, Aug 22, 7:26 PM
wraitii closed D2026: Make Promotion.js use the common Transform helper.
Thu, Aug 22, 7:26 PM
wraitii added inline comments to D2026: Make Promotion.js use the common Transform helper.
Thu, Aug 22, 7:20 PM
wraitii updated the diff for D2092: Generalise Attack effects - any attack can do damage, capture, inflict status effects, including splash. Also damage bonuses..

Also address Stan's comments.

Thu, Aug 22, 7:17 PM
wraitii added inline comments to D2092: Generalise Attack effects - any attack can do damage, capture, inflict status effects, including splash. Also damage bonuses..
Thu, Aug 22, 7:17 PM
wraitii updated the diff for D2092: Generalise Attack effects - any attack can do damage, capture, inflict status effects, including splash. Also damage bonuses..

Allow calling an arbitrary method per damage type. This means we can give and remove status effects neatly, or have attacks that actually heal, or anything really.

Thu, Aug 22, 7:08 PM
wraitii added a comment to D2211: Clean CGame constructor arguments.

I would prefer using enum-flags to make these parameters more readable then.

Thu, Aug 22, 3:54 PM
wraitii added a comment to D2207: Adds a function to pick entities with obstructions on screen.

On the whole, I think this is a minor feature that's useful for performance reasons, and we shouldn't worry too much about future-proofing these kind of things, which are easy to change, and generally used in specific use-cases (see also the shore-dock code thingy).

Thu, Aug 22, 8:40 AM
wraitii accepted D2195: Cleanup Camera and CGameView.

@wraitii any thoughts about updated patch? Is it acceptable?

Thu, Aug 22, 8:22 AM

Wed, Aug 21

wraitii added a comment to D2195: Cleanup Camera and CGameView.

Because you have wasted several hours of my lifetime, telling me that my patch is bad because it changes code without you understanding the point of it

I think I've perfectly understood your patch and I still think it's bad (or rather, not worth committing). I have to guess at this point that you believe this to be so unthinkable that you must assume I've misunderstood your patch to reconcile that with reality somehow?
You still haven't acknowledged this remark:

Wed, Aug 21, 11:40 PM
wraitii added inline comments to D2209: Unify 19 copies of IGUIObject::PlaySound and stop copying the according CStrW.
Wed, Aug 21, 11:22 PM
wraitii added a comment to D1989: Allow accessing prop points in the simulation..
In D1989#91742, @elexis wrote:

That sounds like it might be problematic, because the simulation is supposed to be independent of the graphics data.
So not sure if this is right then.
Are there other precedences where the simulation state is dependent on actors?

I think projectiles start at the first ammo point, which is defined in the actors, not in templates. That seems to make sense to me - so that's a strong precedent that prop-points are part of the simulation.

Wed, Aug 21, 1:28 PM

Tue, Aug 20

wraitii added a comment to D2205: Use CGUI& instead of CGUI*.

I give you
void foo(T* foo)
void foo(T& foo)
Now you tell me, for which of the two functions do you wonder whether you receive a null argument?

Well, only the first, but you actually get no guarantee that foo exists with either. That's all I'm saying.
Indeed, you weren't arguing for that, indeed what you argued was that:

This patch now changes the pointer to a reference, so that it is absolutely clear to everyone that we do not need to check whether the CGUI page exists or not.

And as I've said, this feels like the smallest gain. I don't think it's worth changing so many lines and introducing a member reference (which has the highest likelihood of dangling, among references), over.

Tue, Aug 20, 10:44 PM
wraitii added a comment to D2205: Use CGUI& instead of CGUI*.

Yes, that property is true for the pointer as well, which is the reason why I wrote the patch to change the syntax to better reflect the semantics.

Tue, Aug 20, 10:04 PM
wraitii added a comment to D2195: Cleanup Camera and CGameView.
In D2195#91641, @elexis wrote:

@elexis In my opinion yes to mostly all your So this should *. I think it's more clear. But currently I don't see a strong reason to modify the code only for reference <> pointer transformation.

So for T* it's obvious that it can be modified and for T& it is not obvious that it can be modified?

Tue, Aug 20, 9:46 PM
wraitii added a comment to D2205: Use CGUI& instead of CGUI*.

Thanks for the strawman, how often more do you want to tell me again that some other pointer or reference can crash that is not the code that we talk about?
How often will you tell me more that some other code that is not the code we speak about can crash?

Tue, Aug 20, 9:36 PM
wraitii added a comment to D2195: Cleanup Camera and CGameView.

@elexis In my opinion yes to mostly all your So this should *. I think it's more clear. But currently I don't see a strong reason to modify the code only for reference <> pointer transformation.

Tue, Aug 20, 9:16 PM
wraitii added a comment to D2205: Use CGUI& instead of CGUI*.

Sorry, but you don't get it.
Either you decide for a paradigm where CGUI is always allocated by design, and thus chose a reference,[...]
or you decide for a design where CGUI is optional and thus chose a pointer.

No actually I don't have to pick a "paradigm" here. Both the reference and the pointer code are completely valid and functional. Why you want to add 54 nullability checks is your problem, you're changing perfectlyy working code

Tue, Aug 20, 9:13 PM
wraitii added inline comments to D2205: Use CGUI& instead of CGUI*.
Tue, Aug 20, 8:03 PM
wraitii added a comment to D2205: Use CGUI& instead of CGUI*.

It's tricky to keep calm if people say that your patch is wrong without having read the affected code or brought fourth a single argument specific to the patch.

Tue, Aug 20, 7:58 PM
wraitii added a comment to D2205: Use CGUI& instead of CGUI*.

I'd agree with vlad that non-const references are probably trickier than non-const pointers. Const references are preferable to pointers however.

Tue, Aug 20, 7:41 PM
wraitii added a reviewer for D2197: Add support for recording replay metadata when in nonvisual mode: wraitii.

I have a vague memory of @vladislavbelov doing something similar, I'll try and find out.

Tue, Aug 20, 11:57 AM
wraitii added a reviewer for D2199: Add RPC interface for Reinforcement Learning: wraitii.
Tue, Aug 20, 11:57 AM
wraitii added a reviewer for D2200: fix a wrong class (CitizenSoldier): wraitii.
Tue, Aug 20, 11:57 AM
wraitii added a comment to D2199: Add RPC interface for Reinforcement Learning.

Hey, thanks for contributing this on Phabricator :)

Tue, Aug 20, 10:13 AM
wraitii accepted D2198: Fixes bug with disabled fog on water.
Tue, Aug 20, 10:02 AM
wraitii added a comment to D2196: Fixes values of clip planes in PostProcManager.

Looks alright, but calling it a 'refactoring' is a bit misleading imo, I'd avoid it in the commit message :)

Tue, Aug 20, 10:02 AM

Mon, Aug 19

wraitii updated the diff for D2092: Generalise Attack effects - any attack can do damage, capture, inflict status effects, including splash. Also damage bonuses..

Fixed remark above.

Mon, Aug 19, 8:47 AM

Sun, Aug 18

wraitii added a comment to D2188: Allow Promotion to add arbitrary modifiers when a unit reaches the next rank instead of changing entities.
In D2188#91103, @Stan wrote:

What's the difference between this and a status effect ?

Sun, Aug 18, 7:34 PM
wraitii added inline comments to D274: Handle modifications of technologies and auras in a system component.
Sun, Aug 18, 7:06 PM
wraitii created D2188: Allow Promotion to add arbitrary modifiers when a unit reaches the next rank instead of changing entities.
Sun, Aug 18, 6:46 PM
wraitii updated the diff for D2026: Make Promotion.js use the common Transform helper.

Add Promotion and ResourceGatherer to Transform.js, and rewrite the Promote test to be about promotion, not about Transform.js.

Sun, Aug 18, 4:47 PM
wraitii updated the diff for D1767: Rewrite Profiler2's GUI using D3 / CanvasJS.

Do it in CanvasJS and D3 instead, Highcharts was too slow.

Sun, Aug 18, 12:42 PM
wraitii abandoned D1859: Send a message when players change entities - D274 prereq.

Merged back in D274

Sun, Aug 18, 9:42 AM
wraitii updated the diff for D274: Handle modifications of technologies and auras in a system component.

Optimised after some profiling. I'm now rather confident that this is generally as fast as SVN, and much faster for global auras.

Sun, Aug 18, 9:42 AM

Fri, Aug 16

wraitii committed rP22674: Fix rP14372 and rP22666 miniupnpc leak and crash on thread exit..
Fix rP14372 and rP22666 miniupnpc leak and crash on thread exit.
Fri, Aug 16, 7:39 PM
wraitii closed D2181: Fix rP14372 and rP22666 miniupnpc leak and crash on thread exit.
Fri, Aug 16, 7:39 PM
wraitii added inline comments to D2181: Fix rP14372 and rP22666 miniupnpc leak and crash on thread exit.
Fri, Aug 16, 5:12 PM
wraitii updated the diff for D2181: Fix rP14372 and rP22666 miniupnpc leak and crash on thread exit.

so, I think it's better to just detach() and let it live. It'll either clean up on its own or get cleaned up by the OS when exiting, and that's likely fine.

Fri, Aug 16, 1:10 PM
wraitii added inline comments to D1921: pthread -> std::thread (5/7) - Replace sdl semaphore with condition variable.
Fri, Aug 16, 12:08 PM
wraitii updated the diff for D2181: Fix rP14372 and rP22666 miniupnpc leak and crash on thread exit.

Cleanly exit to avoid hanging in upnp Discovery.

Fri, Aug 16, 12:07 PM
wraitii updated the diff for D1921: pthread -> std::thread (5/7) - Replace sdl semaphore with condition variable.

Fix test issue, fix remarks.

Fri, Aug 16, 10:03 AM
wraitii added a comment to D1684: Pass callback function to PushGuiPage and unify PopGuiPage/PopGuiPageCB.

So what's the "new" stack model that this patch introduces exactly?
Is the current GUI Model that we can only have one "axis", so pushing 5 times from the same pages results in:

  • Main -> Page1 -> Page2 -> Page3

Instead of the (more expected):

Main -> Page 1
     -> Page 2
     -> Page 3

?

Fri, Aug 16, 9:23 AM
wraitii created D2181: Fix rP14372 and rP22666 miniupnpc leak and crash on thread exit.
Fri, Aug 16, 9:18 AM

Thu, Aug 15

wraitii updated the diff for D1921: pthread -> std::thread (5/7) - Replace sdl semaphore with condition variable.

Add <condition_variable> header.

Thu, Aug 15, 7:33 PM
wraitii updated the diff for D1921: pthread -> std::thread (5/7) - Replace sdl semaphore with condition variable.

Fix debug. RC.

Thu, Aug 15, 7:28 PM
wraitii updated the diff for D274: Handle modifications of technologies and auras in a system component.

Clean up some of the weirdness.

Thu, Aug 15, 7:16 PM
wraitii abandoned D1858: Add a MultiKeyMap helper and tests (+ allow tests in /helpers) - D274 prereq.

Merged back into D274

Thu, Aug 15, 7:16 PM
wraitii added a comment to D2180: Fix rP22668 Wind computation - move back to signed integers.

m_MapSize ought to be signed but that sounded like it'd change many more lines.

Thu, Aug 15, 7:08 PM
wraitii committed rP22670: Fix rP22668 Wind computation - switch to signed integers..
Fix rP22668 Wind computation - switch to signed integers.
Thu, Aug 15, 7:03 PM
wraitii closed D2180: Fix rP22668 Wind computation - move back to signed integers.
Thu, Aug 15, 7:03 PM
wraitii updated the summary of D2180: Fix rP22668 Wind computation - move back to signed integers.
Thu, Aug 15, 6:50 PM
wraitii created D2180: Fix rP22668 Wind computation - move back to signed integers.
Thu, Aug 15, 6:50 PM
wraitii committed rP22668: Wind speed computation rework..
Wind speed computation rework.
Thu, Aug 15, 1:56 PM
wraitii closed D1721: Wind speed computation speed-up.
Thu, Aug 15, 1:56 PM
wraitii added a comment to D1721: Wind speed computation speed-up.

Ran some profiling, and I'm not actually sure this speeds things up. But it's still better behaviour as there are some artefacts with the existing code on e.g. Polynesia near the edges, and it's more readable imo so I'll commit anyways.

Thu, Aug 15, 1:53 PM
wraitii abandoned D1483: Use Homebrew to fetch OSX libraries instead of compiling them all.

Abandoning since won't get committed.

Thu, Aug 15, 12:36 PM
wraitii updated the diff for D1721: Wind speed computation speed-up.

emplace_back instead of push_back to avoid the braces, and init the move inline.

Thu, Aug 15, 12:34 PM
wraitii added inline comments to D1859: Send a message when players change entities - D274 prereq.
Thu, Aug 15, 12:33 PM
wraitii added inline comments to D1721: Wind speed computation speed-up.
Thu, Aug 15, 12:24 PM
wraitii updated the diff for D1859: Send a message when players change entities - D274 prereq.

Make ordering consistent:

  • PlayerChanged is sent
  • Entities are changed owner from invalid to player
  • player ent is destroyed
Thu, Aug 15, 12:13 PM
wraitii updated the diff for D1921: pthread -> std::thread (5/7) - Replace sdl semaphore with condition variable.

Working version, worked around the fact thats SDL semaphores keep a count of how many times they were asked to wake up.

Thu, Aug 15, 12:01 PM
wraitii committed rP22666: pthread -> std::thread (4/7) - Replace pthread in remaining files.
pthread -> std::thread (4/7) - Replace pthread in remaining files
Thu, Aug 15, 11:07 AM
wraitii closed D1920: pthread -> std::thread (4/?) - Replace pthread in remaining files.
Thu, Aug 15, 11:07 AM
wraitii updated the diff for D1721: Wind speed computation speed-up.

Clean up formatting.

Thu, Aug 15, 10:54 AM
wraitii updated the diff for D1859: Send a message when players change entities - D274 prereq.

Cleaned up.

Thu, Aug 15, 10:01 AM
wraitii updated the diff for D1920: pthread -> std::thread (4/?) - Replace pthread in remaining files.

Add include, RC

Thu, Aug 15, 9:45 AM
wraitii awarded D2176: Give an option to allow multiple controls groups share same entities. a Love token.
Thu, Aug 15, 9:37 AM
wraitii added a comment to D2176: Give an option to allow multiple controls groups share same entities..

Feels like this should be the default to me to be honest

Thu, Aug 15, 9:37 AM

Mon, Aug 12

wraitii retitled D14: [RC] Thread the pathfinder computations from Thread the pathfinder computations to [RC] Thread the pathfinder computations.
Mon, Aug 12, 6:41 PM
wraitii added a comment to D14: [RC] Thread the pathfinder computations.

As an FYI: I confirm this is working on my machine, but don't expect all 4 cores to be 100% CPU, pathfinding is only a small part of it.

Mon, Aug 12, 6:40 PM
wraitii updated the diff for D1920: pthread -> std::thread (4/?) - Replace pthread in remaining files.

Bring back the early returns;

Mon, Aug 12, 3:35 PM
wraitii committed rP22653: Hierarchical Pathfinder - Add Global Regions / Optimise MakeGoalReachable.
Hierarchical Pathfinder - Add Global Regions / Optimise MakeGoalReachable
Mon, Aug 12, 3:19 PM
wraitii closed D1835: Hierarchical Pathfinder - Add Global Regions / Optimise MakeGoalReachable (D53 outtake).
Mon, Aug 12, 3:19 PM
wraitii updated the diff for D1858: Add a MultiKeyMap helper and tests (+ allow tests in /helpers) - D274 prereq.

Left a change in D274 incorrectly.

Mon, Aug 12, 3:14 PM
wraitii updated the diff for D1858: Add a MultiKeyMap helper and tests (+ allow tests in /helpers) - D274 prereq.

Un-nuke the commas.

Mon, Aug 12, 3:10 PM
wraitii committed rP22652: Fix build without precompiled headers in rP22649..
Fix build without precompiled headers in rP22649.
Mon, Aug 12, 2:56 PM
wraitii updated the diff for D274: Handle modifications of technologies and auras in a system component.

Ran some more profiling, this seems comparable with svn. I think it's a tad slower as there's slightly more indirection, but that ought to be irrelevant in cost. MultiKeyMap could be switched to C++ I guess for best performance.

Mon, Aug 12, 2:52 PM
wraitii updated the diff for D1858: Add a MultiKeyMap helper and tests (+ allow tests in /helpers) - D274 prereq.

Fix formatting

Mon, Aug 12, 2:51 PM
wraitii updated the diff for D1835: Hierarchical Pathfinder - Add Global Regions / Optimise MakeGoalReachable (D53 outtake).

Rebased for commit.

Mon, Aug 12, 11:57 AM
wraitii added a comment to D1739: Introduce a replacement container for EntityMap, std::map, std::unordered_map and boost::unordered_map.

Ran a few rejointests, all passing, which indicates that the serialisation keeps the deterministic non-linear order correctly, so this is good to go.

Mon, Aug 12, 11:50 AM
wraitii committed rP22649: pthread -> std::thread (3/7) - Replace pthread in other engine files.
pthread -> std::thread (3/7) - Replace pthread in other engine files
Mon, Aug 12, 10:16 AM
wraitii closed D1917: pthread -> std::thread (3/?) - Replace pthread in other engine files.
Mon, Aug 12, 10:16 AM
wraitii requested verification of rP22298: Health.js cleanup: add tests, add an "IsInjured" function, use this.hitpoints….
Mon, Aug 12, 10:07 AM
wraitii requested verification of rP22296: Add unit motion integration test map.

Not sure what was missing or too much, but it's fixed now.

Mon, Aug 12, 10:06 AM
wraitii requested verification of rP22586: Replace {gender} by {phenotype} and support this tag in VisualActor..

Both concerns fixed.

Mon, Aug 12, 10:06 AM
wraitii committed rP22648: Fix VisualActor OOS introduced in rp22586.
Fix VisualActor OOS introduced in rp22586
Mon, Aug 12, 10:05 AM
wraitii closed D2169: Fix VisualActor OOS.
Mon, Aug 12, 10:05 AM
wraitii committed rP22647: Fix checkrefs script following rP22586 (phenotypes), and fix the….
Fix checkrefs script following rP22586 (phenotypes), and fix the…
Mon, Aug 12, 10:03 AM
wraitii closed D2141: Fix checkrefs script following phenotype D1955/rP22586..
Mon, Aug 12, 10:03 AM