CSCA Encyclopedia crashing if a custom description is long.

Discussion in 'RGSSx Script Support' started by Ninjakillzu, Jun 5, 2019.

  1. Ninjakillzu

    Ninjakillzu Veteran Veteran

    Messages:
    111
    Likes Received:
    34
    First Language:
    English
    Primarily Uses:
    RMVXA
    I recently got Casper's CSCA Encyclopedia script https://www.rpgmakercentral.com/topic/2775-csca-encyclopedia-w-bestiary/ to simulate a "help menu" that adds descriptions for different attributes and skills (as in DnD-esque skills), but the length of my descriptions cause the game to crash with no error message when I go to the custom category in game. Even if I only have half of the description, all the text is squashed and cut off near the end, making it really hard to read. How can I make it so it doesn't crash, and so that the text is displayed clearly? I don't know why it could be crashing, but maybe the limits in the script are too small?

    This is the length of my descriptions:

    Code:
    DESCRIPTION[0] = [0,["Strength (STR) is an index of your physical ability and
    capacity for the exertion of force. Adds modifiers
    that increase melee weapon damage and Intimidation Skill levels."]]
    
    DESCRIPTION[1] = [1,["Body (BODY) is an index that measures your overall health
    and constitution. Increases your maximum Health Points, and
    affects BODY saves."]]
    
    DESCRIPTION[2] = [2,["Intelligence (INT) is an index that measures your problem
    solving ability and capacity for knowledge. Adds modifiers that
    increase Security, Computer Use, and Demolitions Skill levels,
    and can affect dialogue choices."]]
    
    DESCRIPTION[3] = [3,["Wisdom (WIS) is an index that measures your understanding of
    abstract concepts, your center of morality, and your overall
    gut instinct. Adds modifiers that increase First Aid and Repair
    Skill levels and can affect dialogue choices."]]
    
    DESCRIPTION[4] = [4,["Reflexes (REF) is an index that measures your dexterity and
    overall coordination. Adds modifiers to Attack Bonus (increasing
    chance for your attacks to hit) and Armor Class (decreasing
    chance to be hit by enemy attacks). Also, affects REF Saves."]]
    
    DESCRIPTION[5] = [5,["Charisma (CHA) is an index that measures how you relate to
    others, and your understanding of how to act in social situations.
    Adds modifiers that increases Persuasion skill levels and can
    affect dialogue choices."]]
    
     
    #1
  2. DerVVulfman

    DerVVulfman Resident Werewolf Veteran

    Messages:
    297
    Likes Received:
    147
    First Language:
    English
    Primarily Uses:
    RMXP
    Line breaks? Is the code here shown exactly as it is in your script editor, or is each description one single line? Asking because the script editor wouldn't know that your description is meant to continue onto the next.

    An example of having the descriptions entered while accounting for line breaks:

    Code:
    DESCRIPTION[1] = [1,["Body (BODY) is an index that measures your overall health " +
    "and constitution. Increases your maximum Health Points, and " +
    "affects BODY saves."]]
    
    DESCRIPTION[2] = [2,["Intelligence (INT) is an index that measures your problem" +
    "solving ability and capacity for knowledge. Adds modifiers that" +
    "increase Security, Computer Use, and Demolitions Skill levels," +
    "and can affect dialogue choices."]]
    
    DESCRIPTION[3] = [3,["Wisdom (WIS) is an index that measures your understanding of" +
    "abstract concepts, your center of morality, and your overall" +
    "gut instinct. Adds modifiers that increase First Aid and Repair" +
    "Skill levels and can affect dialogue choices."]]
    
    DESCRIPTION[4] = [4,["Reflexes (REF) is an index that measures your dexterity and" +
    "overall coordination. Adds modifiers to Attack Bonus (increasing" +
    "chance for your attacks to hit) and Armor Class (decreasing" +
    "chance to be hit by enemy attacks). Also, affects REF Saves."]]
    
    DESCRIPTION[5] = [5,["Charisma (CHA) is an index that measures how you relate to" +
    "others, and your understanding of how to act in social situations." +
    "Adds modifiers that increases Persuasion skill levels and can" +
    "affect dialogue choices."]]
    
    In this, each string is encapsulated on both left and right sides, and the '+' symbol informs the engine to look to the next line for continuation.
    I preferred the original 'Advanced Dungeons & Dragons' and '2nd Edition'...
     
    #2
  3. KK20

    KK20 Just some XP Scripter Veteran

    Messages:
    88
    Likes Received:
    38
    Location:
    Orange County, California
    First Language:
    English
    Primarily Uses:
    RMXP
    The descriptions are actually an array of strings where each string is drawn on its own line with the next drawn below it (even the config had a comment on that). Would have been nice if the script could parse long strings automatically.

    At a glance I don't see how those strings are causing game.exe to crash.
     
    #3
  4. Ninjakillzu

    Ninjakillzu Veteran Veteran

    Messages:
    111
    Likes Received:
    34
    First Language:
    English
    Primarily Uses:
    RMVXA
    I must be blind. Each line is separated with "," (as mentioned in the script) so if I change the description to look like:
    Code:
    DESCRIPTION[0] = [0,["Strength (STR) is an index of your physical","ability and capacity for the exertion of","force. Adds modifiers that increase melee","weapon damage and Intimidation skill","levels."]]
    it works correctly. It looks like I fixed it for now, although I wish the lines were longer.
     
    #4

Share This Page