SYDEKICK/F ver. 0.0.0.2

This is an imaginary example of SYDEKICK BASIC BASIC in formal language. And yet, writing and consideration.

SYDEKICK/F is lexicalized by words. Each word is separated by spaces. This means if there is not any spaces between surface string, it makes one word.

Formal language which is used by SYDEKICK/F will be defined "SYDEKICK/L SYNTAX" and "SYDEKICK/L SEMANTICS" .

# SYDEKICK/F v. 0.0.0.2 作業中
# "FRAME" is reserved and special word for frame of SYDEKICK.
# "module" is a reserved name name for types.
# : means set or define something as provided name(s).
# Quoted string can be a word.

"1. kN-SYDEKICK-0-1-0 BASIC BASIC" : module/dummy [
#   nop means no operation
    nop

#   ###[ means start position of block comment.
#   ###] means end position of block comment.
    ###[
 “System Development Kit with module Complex for ttrpg by
Kuzu/null” (“SYDEKICK”) とは、TTRPG用の簡略かつモジュール化された
System Development Kit です。ユーザ — GMとプレイヤー — が様々な世界
観とシステムを作り、そしてそれを遊ぶことの手助けとなるように構築してい
ます。
 このモジュールはBASICグループに属する “kN-SYDEKICK-0-1-0 BASIC 
BASIC” モジュールであり、いくつかのスロット の設置位置の例示と、それ
ぞれのスロット に対応するフィラー の内容の例示を行ないます。同時に、部
分と全体の module Complex の例示でもあります。以下には、 “2. キャラク
ター・メイキング”、 “3. 判定方法”、 “4. 運プール”、 “5. 行動の順
番と移動可能距離”、 “6. ダメージと消耗”、 “7. PCの成長” を含みま
す。
    ###]
]

# Example of FRAME module
FRAME : module [

#   place slots on the FRAME
#   { x y z } is multiple-name-structure. Each multiple-name-structure has
#   same body but has multiple names.
#   Example of below, { "2. キャラクター・メイキング" "2. Character Making" }, 
#   "2. キャラクター・メイキング", and "2. Character Making" will refer
#   same body.
    place [ { "2. キャラクター・メイキング" "2. Character Making" } ]
    place [ { "3. 判定方法" "3. Challenges" } ]
    place [ { "4. 運プール" "4. Luck Pool" } ]
    place [ { "5. 行動の順番と移動可能距離" "5. Initiative, Movement, and Support Action" } 
            { "6. ダメージと消耗" "6. Damage/Exhaustion" } { "7. PCの成長 "7. Advancement" } ]
]


##   connect modules (fillers) with interface on the FRAME bidirectional
#    connect [ "2. キャラクター・メイキング" with "3. 判定方法"
#    connect/share [ "2. キャラクター・メイキング" with [
#        "4. 運プール" 
#        "5. 行動の順番と移動家の距離"
#        "6. ダメージと消耗"
#        "7. PCの成長"
#    ]
#    [omit others]
#]

#   Example other module
# Quoted string can be a word, again I will say.

#   This is an fully dummy module definition.
#   In this case, there is name(s) only.
#   This module exist for sameness of module or section composition
#   on text document.
#
#   { "2. キャラクター・メイキング" "2. Character Making" } is 
#   multiple-name-structure
#   module/dummy is refined module. / makes composit words.
#   For example, mother/daughter/granddaughter...
#   In this case, daughter must be defined in mother.
#   / likes something . in many object oriented programming languages.
{ "2. キャラクター・メイキング" "2. Character Making" } : module/dummy [
#   transparent makes channels for interface and connect, automaticaly.
    transparent
]

#   module means type of this structure is a module.
{ "2.1 キャラクターをイメージする" "2.1 Imaging Your Character" } : module [

#   Users must write down concepts of his/her character.
    { "キャラクターのイメージ" "Concepts of character"} : text [

#       This means write down concepts as the same name of this structure. 
#       name is another reserved word.
        writedown/byUSER name this
    ]

#   read and eval itemize.
#   text/itemize is another reserved name for a type.
#   text/itemize type means just imaginary and itemize.
#   In this case, text/itemizes are read and evaled by User.
#   eval/byUSER and read are functional words.
#   First, read will read { "キャラクターのイメージ" "Concepts of character" } .
#   Then, eval/byUSER will eval contents of  { "キャラクターのイメージ" 
#   "Concepts of character" } .
#   This means textual information must be transformed some more clear image
#   as itemize.
    { "キャラクターのイメージ Itemize" 
      "Concepts of Character Itemize" } : text/itemize [
            eval/byUSER read { "キャラクターのイメージ" "Concepts of character" }
        ]

#   interface will make connection in bidirectional with upper and lower layers.
#   But the lowest layer is the first layer. Never to access FRAME.
#   Each variables, structs, and maybe consts are refered by pointers.
#   receiver will be made automatically, based on transparent and place.
    interface { "キャラクターのイメージ Itemize" "Concepts of Character Itemize" }

    place [ "2.2 能力" ]
    place [ "2.3 技能" ]
    [omit rest of here]
]

#   Example other module
"2.2 能力" : module [

#   functin is a name of types of structure.
#   function define function/procedure.
    method1 : function [
    ]

    method2 : function [
    ]

    method3 : function [
    ]


    # "struct" is a name of types
    能力 : struct [
        # You can access this as 能力/心 or "能力/心.
        # "integer" is a name of type. 
        [ 心 : integer [ 5 ... 9 ] ]
        [ 体 : integer [ 5 ... 9 ] ]
        [ 技 : integer [ 5 ... 9 ] ]
        [ 魂 : integer [ 5 ... 9 ] ]
    ]

#   How to treat Attributes Points?

    

    能力/心 : set/byUSER
    cond [
        [ [ ( 能力/心 < 5 ) ] [ alart "ERROR" ] ]
        [ [ ( 能力/心 > 9 ) ] [ alart "ERROR" ] ]
    ]

    能力/体 : set/byUSER
    cond [
        [ [ ( 能力/体 < 5 ) ] [ alart "ERROR" ] ]
        [ [ ( 能力/体 > 9 ) ] [ alart "ERROR" ] ]
    ]

    能力/技 : set/byUSER
    cond [
        [ [ ( 能力/技 < 5 ) ] [ alart "ERROR" ] ]
        [ [ ( 能力/技 > 9 ) ] [ alart "ERROR" ] ]
    ]

    能力/魂 : set/byUSER
    cond [
        [ [ ( 能力/魂 < 5 ) ] [ alart "ERROR" ] ]
        [ [ ( 能力/魂 > 9 ) ] [ alart "ERROR" ] ]
    ]

    interface 能力

#   Each variables, structs, and maybe consts are refered by pointers.
#   receiver will be made automatically, based on transparent or place.
#   connect will make channel to other fillers except upper layers.
#   connect can make channel through FRAME.
    connect 能力

]

[omit others]

We will make more development of SYDEKICK/F. SYDEKICK/L SYNTAX and SYDEKICK/L SEMANTICS will come later. Enjoy and Comment!

Previous note is here.

ここから先は

0字

¥ 100

この記事が気に入ったらサポートをしてみませんか?