Jump to content

suy

Members
  • Posts

    250
  • Joined

  • Last visited

About suy

Profile Information

  • Location
    Barcelona

Recent Profile Visitors

1,785 profile views

suy's Achievements

  1. I've considered this as well. I wish I could write nested "if" clauses (and "else" clauses) on BAF code, of course. So I thought of a custom language that would look like a BAF superset, but with those extras (and it would be similar to SSL in pros/cons and philosophy). I just don't see how to do this properly, given that it would look so very differently once transpiled, that debugging the generated code would be difficult given the lack of support for any BAF debugging, source maps, etc. Also, writing a compiler is not in my comfort zone or interests. But definitely interested in looking up what others can come up with. So far, after trying the C preprocessor and Mustache, and now this Lua templates, I think I've found my sweet spot. I will try to make an additional post in the future, once I've ironed out some details, because I think this can be a sweet spot for other people too, if I can provide good examples and ease of use. There are other language and template choices, though, but I think any could do well enough.
  2. Thanks. You and CamDawg mentioned it, but I was aware of it (I somewhat mentioned on the post), and it is semi-desired. You can treat them as a special item that can be recovered... sometimes. Then you can go a bit crazy in making it powerful, knowing that it's not going to be abused much, due to the risk. Like the charges of the Staff of Striking. Only seven is way less than what I initially considered (the staff has 25 charges), but seven made sense as per the lore of Selune. I guess it could be bumped to a higher number and handwave the lore aspect. It also seemed a good excuse to show this trick that Tweaks has to make the recoverable ammunition, give that the stream is intended to be helpful to new modders.
  3. No, I did the very opposite. I used a library that, as I explained, doesn't invent a new language at all, but uses the "host" language. The etlua library is 285 lines of a single Moonscript file that compiles to 400 lines of pure Lua. Liquid seems to be 3700 in the 'lib' directory. The comparison is not to Liquid, but to ERB (which seems to be 486 lines in the 'lib' directory). In the other post I mentioned John Resig's microtemplate, and Lodash/Underscore, which are also well known, and it's the same approach. Any of those implementations would work just fine. I like ERB and Ruby, and I like those JS libraries as well, and they would work fine. Lua is a bit better in that is much smaller, and it's somewhat known to other modders, as it's used in EEex, and the UI.
  4. Well, this aged poorly, @suy from the past. I've actually written WeiDU since then. Anyway, I want to add a followup to this thread, because I've done another step in this direction. Or to the parallel of this direction, because I dropped Mustache, and I've gone with a library in Lua that implements templates like the approach I mentioned in this thread: embedding the real programming language in the template. It looks like this for a simple example: <% for n = 1, 6 do -%> IF StateCheck(Player<%- n -%>, STATE_INVISIBLE) CheckStatGT(Player<%- n -%>, 1, BACKSTABDAMAGEMULTIPLIER) THEN RESPONSE #100 ApplySpellRES("S_FSTAB",Player<%- n -%>) Continue() END <% end -%> That is a trivial enough example that just repeats that block 6 times for the 6 players. Not a big deal to do by hand because is so simple (and not worth using a template for this), but in the case of my party AI script is, among other things, 2 attack blocks per Neareast/SecondNearest/etc which are very repetitive, and each block is significantly larger than this, so it was hellish to maintain when trying to do changes. When I was experimenting I definitely needed to have a small program generate the BAF code, or I would have turned mad. Stripping whitespace and comments, the templates are about 225 lines, and the resulting output is 425 lines. Almost twice the size for the current version. But the savings can be much bigger than this. I'm processing the template on my computer, and adding the output to the Git repository, so the user doesn't run any Lua code. But if I were to add Lua to the mod, the footprint would be still very small. And exists a version of Lua that is a single executable that works on either Linux/Windows/Mac. I will try this eventually, I think. If anyone is interested in this, I can elaborate a lot further, with simple examples for non-programmers, if I was too technical. But the code required for this is all now available in Gitlab: https://gitlab.com/moebiusproject/all-the-things-revised/-/tree/27fdf386dfb61ac4c8d6184426c083d9b6da633a/all-the-things-revised/templates Another example of how it looks (same-ish as the example from some years ago): <% fight = fight or 0 check = check or '' %> IF Global("suy#fight","LOCALS",<%-fight-%>) Global("suy#mode","LOCALS",1) ActionListEmpty() !GlobalTimerNotExpired("suy#hide","LOCALS") <%- check %> <%- render("ClassesWithStealth.etlua") -%> <%- render("ModalStatesDisabled.etlua") -%> THEN RESPONSE #100 SetGlobalTimer("suy#hide","LOCALS",ONE_ROUND) Hide() END The 4 lines at the top look a bit... weird, perhaps, but they could be removed, and instead you'd have: // instead of this (assumes "fight" has a value) Global("suy#fight","LOCALS",<%-fight-%>) // ...you would write this (if "fight" has a value, that, otherwise 0) Global("suy#fight","LOCALS",<%-fight or 0-%>) And the above template would be used like this in another template: <%- render("AttemptToHide.etlua", { fight=1, check=' !See([EVILCUTOFF])', }) -%> I think this can accomplish more or less the same than Stratagems Scripting Language, but this is a much simpler implementation, at the cost of a less integrated feeling in how the script looks. It's clearly a syntax embedded into another, instead of an evolved syntax. With a bit of extra work I think I can iron out a bit the lack of syntax sugar, but is never going to be the same (sometimes for worse, but sometimes for better IMHO).
  5. Item Name Lunar Shards Item Type Throwing Daggers Item Description Legend tells of a humble shepherd whose life was transformed by praying to Selûne bathed by the full moon. After the prayer, a ball of fire fell from the skies, striking the barn, and killing most of his livestock. The man refused to believe that the Moonmaiden would cause such misfortune, so he looked in the debris to see a sign from the goddess. A meteorite was found to be the cause of the impact, and on it scraps of a metal that he believed to be silver, which he related instantly to Selûne. He brought the metal to the temple, where the monks could bless it. Impressed by the shepherd's unwavering faith, they took him in, and taught him the ways of the servants of Selûne. Over time, the new recruit was able to raise enough wealth for the monastery to commission a holy weapon made from the blessed metal. A blacksmith, combining the meteorite's celestial metal with pure silver, forged seven flawless daggers, each representing one of the seven stars in Selûne’s holy symbol. STATISTICS: Combat abilities: – Can harm all lycanthropes. – Can be recovered from the target after being used. THAC0: +1 Damage: 1d4 (missile), +2 vs evil creatures Speed Factor: 2 Proficiency Type: Dagger Type: One-handed Requires: 3 Strength Weight: 0 Art direction I think something silver/white/glowing colored should be enough, to the extent in which is possible. Other notes I was thinking that a Selune-themed weapon for Rasaad in BG would be useful and fitting (for BG2 is less necessary). He's often seen as a very underwhelming character, and he could benefit by having some good ranged weapon that either only him can use, or that he can use specially well. Daggers and darts are decent enough for him, as he'll have more attacks, and he has Fighter THAC0 progression with a bit of a faster level curve. It's not gonna win any contest, but he can suck less at lower levels. I've leaned to daggers instead of darts because it could benefit from Strength, and it's a bit more fitting to a Monk than darts. Either the weapon can be used only by good aligned characters, or only by Sun Soul monks. If the latter, the weapon could be buffed a bit in power. I also think it's a bit flavorful that the weapons are made of silver (plus the mystery metal), and that hence could harm all lycanthropes. To not overpower it, instead of making it a throwing dagger that returns to the hand, it could work like the component in Tweaks Anthology that makes throwing daggers recoverable. Then Rasaad could have a stack of 7 daggers (fitting the theme of the item story), but he would not lose them all in one use. He would have to wait to beat the bad guy to recover them and use them in the next fight. That also adds a bit of tactical choice in how/when to use them (IIRC, you can lose the items if you attack someone, and that someone gets killed while the dagger is still "on the way" to the enemy).
  6. Congratulations on the release! I just saw you made it public on Github, and came to the forums to see the screenshots. A few assorted questions: I opened with the default JRE that I had installed on Linux for NearInfinity, and it failed. I just had installed the package "default-jre" which pulls "openjdk-11-jre". I'm not familiar with Java versions. Do you have some more details on the version? I found there are a ton on packages on Linux with different versions. I went to 21 because is the last one that my distro has so far. After installing that, it runs. But I'm curious to know the details so I can just have as few Java installations as possible. What do you mean by the project being academic? It printed some JavaFX warning, so in my immense ignorance of the Java ecosystem, I assume it's not likely to be integrated in NearInfinity, right? I think NI uses some other GUI tech. Will it have some specific OSS license? I tried it, and it seems to work on Linux fine and fast, but I'm just quite ignorant on the topic of area making/editing, so I can't tell much, as I don't know what I could do with it for a test that isn't already obviously tested.
  7. I would love to see a recording of this. They don't have any video on Steam, and the videos I'm seeing on YouTube are of modern games, reaching even 120 FPS, which can't be shown in YouTube, as it's 60 FPS max. I would like to see a video where the game is old, and the FPS is very low (one could even try making the FPS very low on the IE, like half), then applying the upscaling/frame generation and see how it looks.
  8. See? This is the strongest winning argument for trolling all the BG3 discussions. They respected so little the originals that they don't even counted them well...
  9. Did you try it to see when it triggers, if before or after? I think I did the experiment with the backstab effect, and it was only applying after, so no chance of altering the damage. I imagine it will be the same with the critical hit.
  10. You can create a file in Windows without extension. You can check for its existence without extension. That's the purpose of a marker file. Also, that's how you "help without lambasting". This is how you don't: calling people lazy for no good reason.
  11. Like this one? https://github.com/AngelGryph/MadeInHeaven_EncountersAndQuests/pull/8 And please, again, to be clear: if Angel wanted to remove DESIGNATED, he'll have his reasons, and I 100% empathize with that. I've only released one mod, and I delayed the release months because I got analysis paralysis on which component numbers to choose. I can't make use of LABELs either. I very much considered releasing the mod without any kind of compatibility because I don't care for that myself, and I'm the most important user of my mod and my time.
  12. Re-read the thread. setup-mih_eq.tp2 doesn't use DESIGNATED right now, so component numbers can change.
  13. Now you are being just plain wrong. I have no way to prevent any kind of communication on the subject. I'm not a G3 moderator, admin, or whatever is the name of the role (see, I don't even know that!). I just mentioned on Discord that if something is taking time to get moderated it might not be a conspiracy, just that people have real life issues to deal with. Also, I fail to see how I'm being manipulative for trying to fact check what you said. I gave 3 clear bullet points in how IMHO *some* your criticisms were not fair. You have not commented about any of them. I also have not said all your criticisms were wrong. My opinions are my own. I don't have to agree with you or with Morpheus or anyone else on everything. Which file should check for? How reliable would be if you want to catch enough cases? And yes, that would actually check if the mod is installed instead of just being extracted, but why would that be an advantage? Is it worth it? It's an honest question, I don't know. I don't put mods in the game if it's not to install them. Anyway, I'll try to just not say more on the thread, as I think I don't have more to contribute. Cheers.
  14. I can't see the future, but given the past experiences I think it's fair to expect that all the dust will settle, and your work will still shine brightly. Also, let me say that I've seen quite cool stuff happen when modders have been collaborating. From jastey and Lauriel with the SoD mods, you and Morpheus562 with Crucible or now you and Lava, CamDawg and DavidW with the IWDspells, a bunch of people with the fixpacks and the many tweak mods, etc., etc. etc. Definitely everyone should work on their own terms, but I just want to use the opportunity to say "thanks" to everyone that is making cool stuff, and remind that there is a lot of silent people who don't often spend the time to post on forums but appreciate this ecosystem, flawed as it might be. Cheers.
  15. There are things which are reasonable to criticize and comment, but if you do so, do it right, for the sake of being constructive and hopefully solving problems instead of risking making them worse. You are not forced to anything. You can change the mod yourself to prevent the installation incompatibility. You were able to pinpoint the lines, so just comment them out or remove them. Mods by definition read and write in your hard drive. Don't run anything that you don't trust or don't like. But saying that a mod "dares to check your hard drive" is not a fair statement to me. Checking the whole tp2 file seems it was motivated to not having to check for N components, specially if the mod has not reached 1.0 and is still not giving stability of component numbers or labels. Again, to be clear, I'm not saying that there is nothing to criticize, or that I agree with everything that happened, etc. I'm just hoping, for now, to reach an "agree to disagree" between parties that lowers hostilities.
×
×
  • Create New...