Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 ... 13 14 [15] 16 17 ... 23

Author Topic: LCS 4.12.68  (Read 224329 times)

Teh Barple

  • Bay Watcher
    • View Profile
Re: LCS 4.12.31 Now With a Save Editor (And other flags... sort of)
« Reply #210 on: December 08, 2018, 05:12:28 pm »

You really shouldn't pass this off as "finished" or "in working order", or even a proper continuation of LCS. There are so many broken features that  Fox's old version should be stickied instead.
Logged

IsaacG

  • Bay Watcher
  • Mad Engineer
    • View Profile
    • JJoseph on Deviantart
Re: LCS 4.12.31 Now With a Save Editor (And other flags... sort of)
« Reply #211 on: December 08, 2018, 08:25:45 pm »

You really shouldn't pass this off as "finished" or "in working order", or even a proper continuation of LCS. There are so many broken features that  Fox's old version should be stickied instead.
If you could provide me with a list of these broken features, I'd appreciate it greatly.  The code is tens of thousands of lines long.

4.12.21 is the stable version.  Well, sort of.

I'm not very good at this, but boy is it fun.
« Last Edit: December 08, 2018, 09:30:41 pm by IsaacG »
Logged
LCS 4.12 Thread
https://discord.gg/HYbss8eswM
Quote
Many people, meeting Aziraphale for the first time, formed three impressions: that he was English, that he was intelligent, and that he was gayer than a tree full of monkeys on nitrous oxide.
Constitution of the Confederate States
Article I Sec. 9 4
No bill of attainder, ex post facto law, or law denying or impairing the right of property in negro slaves shall be passe

tykavanaugh

  • Bay Watcher
    • View Profile
Re: LCS 4.12.31 Now With a Save Editor (And other flags... sort of)
« Reply #212 on: December 17, 2018, 09:59:59 pm »

You really shouldn't pass this off as "finished" or "in working order", or even a proper continuation of LCS. There are so many broken features that  Fox's old version should be stickied instead.

Seriously dude? Is this the hill to die on?
Logged

stalin

  • Escaped Lunatic
    • View Profile
Re: LCS 4.12.31 Now With a Save Editor (And other flags... sort of)
« Reply #213 on: December 23, 2018, 05:34:38 am »

Main issue

I kept CTD when waiting on March 31, 2018 when playing on 4.12.21 [Fixed]. Issue was resolved when loading the save file in 4.12.27.

I now get crashes when leaving the prison during the car chase. The CTD is pretty variable here. Sometimes after several rounds of pressing 'D' or 'F', sometimes on the very first turn. Issue persists even when loading the save in 4.12.31.



On an unrelated note, updating to 4.12.27 reproduced one bug previously mentioned, as well as a second bug that I haven't seen mentioned here yet.
  • Ages show up as ?? (might be fixed between 4.12.27 and 4.12.31--haven't tested yet)
  • New recruits are automatically named by profession, rather than name, e.g. instead of "John Doe (Army Veteran)", the liberals are named "Army Veteran (John Doe)". This is also something that might have been fixed after 4.12.27, but I haven't had the chance to text it yet.



Not a bug at all, but just a pet peeve of mine: I really wish that things weren't framed as "Liberal vs. Conservative". The rest of the world outside of the US understands "liberal" in its classical definition, i.e. capitalist. But maybe this is just too entrenched in the game's culture at this point (to be fair, it's even in the name!). Other than that, I wish there were other win conditions besides what amounts to militant reformism, but I have no constructive suggestions for how something like that would be implemented anyway. Either way, this probably isn't the place to bring it up :P

Here is the save file where the game crashes during escape. I go to the prison, go to the top floor, rescue a liberal, then GTFO and this is where the crash occurs. File should be available for 30 days. Bump if you need me to re-up. Thanks for all your hard work (especially in making the save files compatible!)
« Last Edit: December 23, 2018, 05:40:42 am by stalin »
Logged

IsaacG

  • Bay Watcher
  • Mad Engineer
    • View Profile
    • JJoseph on Deviantart
Re: LCS 4.12.31 Now With a Save Editor (And other flags... sort of)
« Reply #214 on: December 23, 2018, 10:17:35 pm »

Main issue

I kept CTD when waiting on March 31, 2018 when playing on 4.12.21 [Fixed]. Issue was resolved when loading the save file in 4.12.27.

I now get crashes when leaving the prison during the car chase. The CTD is pretty variable here. Sometimes after several rounds of pressing 'D' or 'F', sometimes on the very first turn. Issue persists even when loading the save in 4.12.31.


Figured it out.  Crashes when someone in a car chase attempts to fire a weapon that is out of ammo and cannot reload.  Fixed in 4.12.32
On an unrelated note, updating to 4.12.27 reproduced one bug previously mentioned, as well as a second bug that I haven't seen mentioned here yet.
  • Ages show up as ?? (might be fixed between 4.12.27 and 4.12.31--haven't tested yet)
Fixed in 4.12.30
  • New recruits are automatically named by profession, rather than name, e.g. instead of "John Doe (Army Veteran)", the liberals are named "Army Veteran (John Doe)". This is also something that might have been fixed after 4.12.27, but I haven't had the chance to text it yet.
That... that is an odd one.  Fixed in 4.12.32
Evidently all creatures have two names, and when their real names were generated, it didn't overwrite the nickname, just the legal name, leaving "Army Veteran" or "Yoga Instructor" as their continued nickname.

Not a bug at all, but just a pet peeve of mine: I really wish that things weren't framed as "Liberal vs. Conservative". The rest of the world outside of the US understands "liberal" in its classical definition, i.e. capitalist. But maybe this is just too entrenched in the game's culture at this point (to be fair, it's even in the name!). Other than that, I wish there were other win conditions besides what amounts to militant reformism, but I have no constructive suggestions for how something like that would be implemented anyway. Either way, this probably isn't the place to bring it up :P
Valid concern.  Much of the code is intimately tied to the US, and the US prides itself on holding differences from the rest of the world for seemingly no reason.  (We've spent decades trying to start using the metric system, to no avail.)  I'm hoping to make these aspects easier to change, easier to mod.  No promises on timetable.
Here is the save file where the game crashes during escape. I go to the prison, go to the top floor, rescue a liberal, then GTFO and this is where the crash occurs. File should be available for 30 days. Bump if you need me to re-up. Thanks for all your hard work (especially in making the save files compatible!)
Thanks, that's a great help.  Chase sequences are a pain to debug because there's no way to save before them.
Logged
LCS 4.12 Thread
https://discord.gg/HYbss8eswM
Quote
Many people, meeting Aziraphale for the first time, formed three impressions: that he was English, that he was intelligent, and that he was gayer than a tree full of monkeys on nitrous oxide.
Constitution of the Confederate States
Article I Sec. 9 4
No bill of attainder, ex post facto law, or law denying or impairing the right of property in negro slaves shall be passe

Rawb

  • Bay Watcher
    • View Profile
Re: LCS 4.12.32 Now With a Save Editor (And other flags... sort of)
« Reply #215 on: January 13, 2019, 04:51:32 pm »

Just popping back in to say I appreciate all the work that's been done. What are the plans for the future of LCS, if you have any?
Logged

Reelya

  • Bay Watcher
    • View Profile
Re: LCS 4.12.31 Now With a Save Editor (And other flags... sort of)
« Reply #216 on: January 13, 2019, 05:08:46 pm »

Not a bug at all, but just a pet peeve of mine: I really wish that things weren't framed as "Liberal vs. Conservative". The rest of the world outside of the US understands "liberal" in its classical definition, i.e. capitalist. But maybe this is just too entrenched in the game's culture at this point (to be fair, it's even in the name!). Other than that, I wish there were other win conditions besides what amounts to militant reformism, but I have no constructive suggestions for how something like that would be implemented anyway. Either way, this probably isn't the place to bring it up :P

While it would be good to be able to mod the game to that extent, the original concept seems to be based on the election of GW Bush in 2000, plus, the LCS is modeled after the historic SLA - the Sybionese Liberation Army. When you kidnap "conservatives" and brainwash them to be good liberals who then go out and wreak havoc for the cause: that's based on the story of Patty Hearst. The game is very specific, because it's drawing from some very specific incidents in American history.

The theming of "Liberal vs Conservative" is actually inside the LCS member's heads. It's an expression of their ideology that they view everything in the world as Good = Liberal and Bad = Conservative, going so far as health bars are labeled as Liberal / good health and Conservative / poor health. So, you can take that labeling to be an expression of how an ideology views everything through their pet-theory lens, even when it makes no sense. Simiarly, the Radical Feminist fringe (radfems) tend to blame "patriarchy" for every single thing that could possibly go wrong: They stub their toe, "damn the patriarchy": see manspreading, mansplaining, manterrupting, man-<problemX>. "Manterrupting" is interesting, it's based on a study that shows men interrupt women more than women interrupt men while speaking. However, the same study showed that women interrupt each other even more often than the men do. So, it's more like: men emulate the conversation flow of women while talking to women, rather than "manterrupting".

Similarly, hardline Marxists blame Capitalism for everything that could go wrong. The point is, hardliners don't see the world as a patchwork of different factors (racism, sexism, classism etc all playing a small part, sometimes, but on a case by case basis) they tend to see one over-arching theory that ties it all together. For example, short men get less pay than tall men. Radfems say "ah that's the patriarchy at work. Help us defeat the patriarchy and that problem will go away!" The only tool they have is a hammer, so every problem looks like a nail.

In the LCS's case, all evil = Conservatism. LCS are ultra-hardline "liberals" who are so hardline they don't see their own hypocrisy in that they're going around murdering people with guns in the name of Liberalism, because they label everyone they don't like as those no-good inhuman "Conservatives".

So, it would be possible to code in different win-conditions and peaceful protest kind of stuff and break away from the Us/Them dichotomy that the game uses, but doing all those things would seriously water-down the original influences and themes.
« Last Edit: January 13, 2019, 06:14:16 pm by Reelya »
Logged

IsaacG

  • Bay Watcher
  • Mad Engineer
    • View Profile
    • JJoseph on Deviantart
Re: LCS 4.12.32 Now With a Save Editor (And other flags... sort of)
« Reply #217 on: January 14, 2019, 02:37:35 pm »

Just popping back in to say I appreciate all the work that's been done. What are the plans for the future of LCS, if you have any?
Glad to hear it  :D
The bulk of future plans are just making LCS easier to mod, moving more and more of the hard-coded values into modifiable data files.  My second biggest ambition is to remove the requirement of pdcurses altogether.  Done right, it would allow Terra Vitae and cheshirecat's graphical LCS to each be mods, rather than full independent projects and releases.  Long ways off, though.  Might not be possible.  Still, we're almost at the point where translation into another language can be done without recompiling anything.  1279/3990 lines have been transferred.

Similarly, hardline Marxists blame Capitalism for everything that could go wrong. The point is, hardliners don't see the world as a patchwork of different factors (racism, sexism, classism etc all playing a small part, sometimes, but on a case by case basis) they tend to see one over-arching theory that ties it all together. For example, short men get less pay than tall men. Radfems say "ah that's the patriarchy at work. Help us defeat the patriarchy and that problem will go away!" The only tool they have is a hammer, so every problem looks like a nail.

In the LCS's case, all evil = Conservatism. LCS are ultra-hardline "liberals" who are so hardline they don't see their own hypocrisy in that they're going around murdering people with guns in the name of Liberalism, because they label everyone they don't like as those no-good inhuman "Conservatives".

So, it would be possible to code in different win-conditions and peaceful protest kind of stuff and break away from the Us/Them dichotomy that the game uses, but doing all those things would seriously water-down the original influences and themes.
I've been working on a mod.
My Little Crime Squad: Befriending with Force (working title)
It's about what you'd expect.
Logged
LCS 4.12 Thread
https://discord.gg/HYbss8eswM
Quote
Many people, meeting Aziraphale for the first time, formed three impressions: that he was English, that he was intelligent, and that he was gayer than a tree full of monkeys on nitrous oxide.
Constitution of the Confederate States
Article I Sec. 9 4
No bill of attainder, ex post facto law, or law denying or impairing the right of property in negro slaves shall be passe

Rawb

  • Bay Watcher
    • View Profile
Re: LCS 4.12.32 Now With a Save Editor (And other flags... sort of)
« Reply #218 on: January 18, 2019, 01:59:08 pm »

Ah! Will this code transferral make bug-catching easier? Sounds like it could keep the game alive and growing if its more accessible.
I ask about bug-catching with an ulterior motive ;). I'm not sure if these are things you know about, but in my game of .32 I've encountered a few

  • Encounter warnings no longer work
  • The sell option at the pawn shop is not on the menu of possible actions, but can still be accessed by pressing "s"
  • Some people you encounter in neutral places (e.g the apartment buildings) cannot be talked to but instead have an option to "release oppressed". Doing so in front of others alerts conservatives but doesn't actually count as having caused a crime (as checked by inspecting a liberal's status after doing so.

Again, really appreciate your work!
« Last Edit: January 19, 2019, 06:56:57 am by Rawb »
Logged

IsaacG

  • Bay Watcher
  • Mad Engineer
    • View Profile
    • JJoseph on Deviantart
Re: LCS 4.12.32 Now With a Save Editor (And other flags... sort of)
« Reply #219 on: January 19, 2019, 03:47:34 am »

Ah! Will this code transferral make bug-catching easier? Sounds like it could keep the game alive and growing if its more accessible.
I ask about bug-catching with an ulterior motive ;). I'm not sure if these are things you know about, but in my game of .32 I've encountered a few
It should.  It should make it much, much easier to catch bugs.  Unfortunately, my inexperience with C++ pointers has led to an indeterminate number of new bugs in the process.
Generally speaking, while I may ignore cosmetic bugs or graphic glitches here and there, anything causing game crashes gets fixed within hours of my learning about it.  The only known outstanding bug that causes significant problems is the "sometimes executive branch switches party for no known reason" bug.  Unless I'm forgetting something.
  • Encounter warnings no longer work
  • The sell option at the pawn shop is not on the menu of possible actions, but can still be accessed by pressing "s"
  • Some people you encounter in neutral places (e.g the apartment buildings) cannot be talked to but instead have an option to "release oppressed". Doing so in front of others alerts conservatives but doesn't actually count as having caused a crime (as checked by inspecting a liberal's status after doing so.
1 - I'm not sure what you mean by this.  Alert Levels?  "Conservatives Suspicious" "Conservative Reinforcements Incoming" and the like?
2&3 - That should be a relatively easy fix for 4.12.33

Again, really appreciate your work!
Glad to be appreciated. :thumbup:
Logged
LCS 4.12 Thread
https://discord.gg/HYbss8eswM
Quote
Many people, meeting Aziraphale for the first time, formed three impressions: that he was English, that he was intelligent, and that he was gayer than a tree full of monkeys on nitrous oxide.
Constitution of the Confederate States
Article I Sec. 9 4
No bill of attainder, ex post facto law, or law denying or impairing the right of property in negro slaves shall be passe

Rawb

  • Bay Watcher
    • View Profile
Re: LCS 4.12.32 Now With a Save Editor (And other flags... sort of)
« Reply #220 on: January 19, 2019, 07:02:38 am »

1 - I'm not sure what you mean by this.  Alert Levels?  "Conservatives Suspicious" "Conservative Reinforcements Incoming" and the like?
2&3 - That should be a relatively easy fix for 4.12.33

For 1: when you're on site exploration, you can set an option called "Encounter Warnings" (through pressing N when at a site). Basically, the game has an extra "frame" before you encounter passers-by which tells you "Some people are passing by" or something to that effect. You have to press another key to actually see the people you are passing by. The great benefit of this is that you don't miss anyone by accident, say if you're trying to recruit people at a site. It also helps stop you committing crimes in front of people you don't want as witnesses. I used to love this setting as I'm a habitual key over-presser. Turning this option on now in-game doesn't actually do anything: the encounter warnings are no longer generated and you run into people as normal.

I've also found a couple more bugs, will update if I find anymore:

- Potential recruits, through dating and meetings, often turn up naked when you'd expect them to be clothed - this is however rather funny if you imagine LCS takes place in a nudist USA.
- At the IT cafe site, the CPUs never actually spawn with people using them. When you walk up to a computer and the game prompts "The Computer is occupied" no one is ever actually there.
- When liberals are sentenced, it sometimes doesn't tells you the result. It will say "The jury leaves to discuss..." but doesn't show the result. I find this is more common with innocent verdicts.
- When the Liberal Guardian publishes a news story about my valiant actions, the LCS is referred to as the CCS in the article text.
- The display for vehicles is broken for me. I cannot see more than one car on my vehicles screen.
- Got a feature in one my newspaper reports which tells me I've found a bug: https://imgur.com/a/G615ez9. This also shows what I mean in point 4 where my troops are called the CCS
« Last Edit: January 20, 2019, 05:42:24 pm by Rawb »
Logged

IsaacG

  • Bay Watcher
  • Mad Engineer
    • View Profile
    • JJoseph on Deviantart
Re: LCS 4.12.32 Now With a Save Editor (And other flags... sort of)
« Reply #221 on: January 20, 2019, 09:49:15 pm »

1 - I'm not sure what you mean by this.  Alert Levels?  "Conservatives Suspicious" "Conservative Reinforcements Incoming" and the like?
2&3 - That should be a relatively easy fix for 4.12.33

For 1: when you're on site exploration, you can set an option called "Encounter Warnings" (through pressing N when at a site). Basically, the game has an extra "frame" before you encounter passers-by which tells you "Some people are passing by" or something to that effect. You have to press another key to actually see the people you are passing by. The great benefit of this is that you don't miss anyone by accident, say if you're trying to recruit people at a site. It also helps stop you committing crimes in front of people you don't want as witnesses. I used to love this setting as I'm a habitual key over-presser. Turning this option on now in-game doesn't actually do anything: the encounter warnings are no longer generated and you run into people as normal.

I've also found a couple more bugs, will update if I find anymore:

- Potential recruits, through dating and meetings, often turn up naked when you'd expect them to be clothed - this is however rather funny if you imagine LCS takes place in a nudist USA.
- At the IT cafe site, the CPUs never actually spawn with people using them. When you walk up to a computer and the game prompts "The Computer is occupied" no one is ever actually there.
- When liberals are sentenced, it sometimes doesn't tells you the result. It will say "The jury leaves to discuss..." but doesn't show the result. I find this is more common with innocent verdicts.
- When the Liberal Guardian publishes a news story about my valiant actions, the LCS is referred to as the CCS in the article text.
- The display for vehicles is broken for me. I cannot see more than one car on my vehicles screen.
- Got a feature in one my newspaper reports which tells me I've found a bug: . This also shows what I mean in point 4 where my troops are called the CCS
This will be a great help.
« Last Edit: March 08, 2021, 05:22:04 am by IsaacG »
Logged
LCS 4.12 Thread
https://discord.gg/HYbss8eswM
Quote
Many people, meeting Aziraphale for the first time, formed three impressions: that he was English, that he was intelligent, and that he was gayer than a tree full of monkeys on nitrous oxide.
Constitution of the Confederate States
Article I Sec. 9 4
No bill of attainder, ex post facto law, or law denying or impairing the right of property in negro slaves shall be passe

Rawb

  • Bay Watcher
    • View Profile
Re: LCS 4.12.32 Now With a Save Editor (And other flags... sort of)
« Reply #222 on: January 21, 2019, 06:40:48 am »

I'm glad to hear! I'll keep posting more if I find them. I was concerned that I might be bombarding you with a list of problems to fix while you're already going through a lot to translate everything. If it does get tiresome, let me know and I'll just keep a private list of bugs for when you're more able to respond to them. :)
Logged

IsaacG

  • Bay Watcher
  • Mad Engineer
    • View Profile
    • JJoseph on Deviantart
Re: LCS 4.12.32 Now With a Save Editor (And other flags... sort of)
« Reply #223 on: January 29, 2019, 05:51:45 pm »

Went through and refactored a bunch of code.  Example:
Code: [Select]
const string CONST_activate_sleepers023 = " will steal equipment and send it to the Shelter.";
const string CONST_activate_sleepers022 = " will embezzle money for the LCS.";
const string CONST_activate_sleepers021 = " will snoop around for secrets and enemy plans.";
const string CONST_activate_sleepers020 = " will try to recruit additional sleeper agents.";
const string CONST_activate_sleepers019 = " will build support for Liberal causes.";
const string CONST_activate_sleepers018 = " will stay out of trouble.";
const string CONST_activate_sleepers017 = "3 - Steal Equipment";
const string CONST_activate_sleepers016 = "2 - Embezzle Funds";
const string CONST_activate_sleepers015 = "1 - Uncover Secrets";
const string CONST_activate_sleepers014 = "3 - [Need More Juice to Recruit]";
const string CONST_activate_sleepers013 = "3 - [Enlightened Can't Recruit]";
const string CONST_activate_sleepers012 = "3 - Expand Sleeper Network";
const string CONST_activate_sleepers011 = "2 - Advocate Liberalism";
const string CONST_activate_sleepers010 = "1 - Lay Low";
const string CONST_activate_sleepers009 = "Enter - Confirm Selection";
const string CONST_activate_sleepers008 = "C - Join the Active LCS";
const string CONST_activate_sleepers007 = "B - Espionage";
const string CONST_activate_sleepers006 = "A - Communication and Advocacy";
const string CONST_activate_sleepers005 = " focus on?";
const string CONST_activate_sleepers004 = "Taking Undercover Action:   What will ";

const string CONST_activate_sleepers031 = " T to sort people.";
const string CONST_activate_sleepers030 = "Press a Letter to Assign an Activity.";
const string CONST_activate_sleepers029 = "Effectiveness: ";
const string CONST_activate_sleepers028 = "ACTIVITY";
const string CONST_activate_sleepers027 = "SITE";
const string CONST_activate_sleepers026 = "JOB";
const string CONST_activate_sleepers025 = "CODE NAME";
const string CONST_activate_sleepers024 = "Activate Sleeper Agents";
is now
Code: [Select]
const string WILL_STEAL = " will steal equipment and send it to the Shelter.";
const string WILL_EMBEZZLE = " will embezzle money for the LCS.";
const string WILL_SNOOP = " will snoop around for secrets and enemy plans.";
const string WILL_TRY_TO_RECRUIT = " will try to recruit additional sleeper agents.";
const string WILL_BUILD_SUPPORT = " will build support for Liberal causes.";
const string WILL_STAY_OUT_OF_TROUBLE = " will stay out of trouble.";
const string THREE_STEAL = "3 - Steal Equipment";
const string TWO_EMBEZZLE = "2 - Embezzle Funds";
const string ONE_UNCOVER_SECRETS = "1 - Uncover Secrets";
const string THREE_NEED_MORE_JUICE_TO_RECRUIT = "3 - [Need More Juice to Recruit]";
const string THREE_ENLIGHTENED_CANNOT_RECRUIT = "3 - [Enlightened Can't Recruit]";
const string THREE_EXPAND_SLEEPER_NETWORK = "3 - Expand Sleeper Network";
const string TWO_ADVOCATE_LIBERALISM = "2 - Advocate Liberalism";
const string ONE_LAY_LOW = "1 - Lay Low";
const string ENTER_CONFIRM_SELECTION = "Enter - Confirm Selection";
const string C_JOIN_ACTIVE_LCS = "C - Join the Active LCS";
const string B_ESPIONAGE = "B - Espionage";
const string A_COMMUNICATION = "A - Communication and Advocacy";
const string FOCUS_ON = " focus on?";
const string TAKING_UNDERCOVER_ACTION_WHAT_WILL = "Taking Undercover Action:   What will ";

const string T_TO_SORT_PEOPLE = " T to sort people.";
const string PRESS_A_LETTER_TO_ASSIGN = "Press a Letter to Assign an Activity.";
const string EFFECTIVENESS_COLON = "Effectiveness: ";
const string ACTIVITY_HEADER = "ACTIVITY";
const string SITE_HEADER = "SITE";
const string JOB_HEADER = "JOB";
const string CODE_NAME_HEADER = "CODE NAME";
const string ACTIVATE_SLEEPER = "Activate Sleeper Agents";
Totals about 5000 changes.
I am very, very tired now.

I finally figured out how to get Java to read the text the way pdcurses does.
Now I'm going to change focus, and actually work on those bugs that have been pointed out to me.
Logged
LCS 4.12 Thread
https://discord.gg/HYbss8eswM
Quote
Many people, meeting Aziraphale for the first time, formed three impressions: that he was English, that he was intelligent, and that he was gayer than a tree full of monkeys on nitrous oxide.
Constitution of the Confederate States
Article I Sec. 9 4
No bill of attainder, ex post facto law, or law denying or impairing the right of property in negro slaves shall be passe

Reelya

  • Bay Watcher
    • View Profile
Re: LCS 4.12.33 Now With a Save Editor (And other flags... sort of)
« Reply #224 on: February 02, 2019, 02:51:47 am »

While that's better, an even better system to consider for those strings would be to completely get rid of the enums, and replace them with a string:string mapping system

You've moved a lot of things around in the code, but you should really be focusing on moving things out of the code. The size of the code would probably drop 80% if all hard-coded crap was turned into data like it should be. And that would make future bug-fixing much simpler. For example, types of creatures are enums, leading to gigantic switches and tons of if-then statements. Creatures should entirely be defined in JSON or XML files, with the game only knowing about properties that creatures may possess. Which creature has which property would be defined in the JSON files.

Whatever you do, strongly avoid any desire to add new features. Turn code into external data, and let others play with the data to make mods. This is your most efficient way forward.

For the naming convention, I think adding in some prefixes for the cpp file and function name that use the strings would be advisable. It would make things much clearer than just "WILL_STEAL" since you've now removed the semantic information that this had something to do with "sleepers", which makes it less clear what the string is intended to be for. For example, if the "WILL_STEAL" string is used in sleepers.cpp by a function called actions (for example), you could name it "SLEEPERS__ACTIONS__WILL_STEAL". So, just be reading the name you can tell where to look for uses of that string (note the double-underscore between parts of the name to clarify what's what).

After that, make it so that it reads the string:string mappings from a JSON file, and translators can then just mod a text file to make language-specific full conversions, no compile needed.

However, when that happens, I'd suggest sill maintaining a hard-coded list of "known" strings in the code (by their "name"), which the JSON-strings get loaded against. Then, each code-type mod can maintain their own list of known strings, and there could be a command-line option to just spit out the "list of strings" (e.g. "lcs -dumpstrings") that each variant of the game needs. This would allow translators to pull out a list of all the strings they need to implement for each and every mod that is compliant with the system. e.g. if Terra Vitae mod was adapted, then any translator could just spit out a list of strings needed for Terra Vitae mod and start adapting their translation to Terra Vitae without looking at the source code whatsoever.
« Last Edit: February 02, 2019, 03:33:25 am by Reelya »
Logged
Pages: 1 ... 13 14 [15] 16 17 ... 23