Other Projects > Curses

LCS 4.12.68

<< < (45/67) > >>

Rawb:

--- Quote from: IsaacG on January 19, 2019, 03:47:34 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

--- End quote ---

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

IsaacG:

--- Quote from: Rawb on January 19, 2019, 07:02:38 am ---
--- Quote from: IsaacG on January 19, 2019, 03:47:34 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

--- End quote ---

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

--- End quote ---
This will be a great help.

Rawb:
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. :)

IsaacG:
Went through and refactored a bunch of code.  Example:

--- Code: ---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";

--- End code ---
is now

--- Code: ---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";

--- End code ---
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.

Reelya:
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.

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version