A few questions about Ring and PWCT

102 views
Skip to first unread message

Ari

unread,
Oct 16, 2023, 7:52:33 AM10/16/23
to The Ring Programming Language
I picked up PWCT 2.0 during the 90% off sale because I was curious about it and I've been meaning to try Ring out. I just had a few questions about Ring and PWCT.

- Is there a means of allowing user-defined scripts to be loaded at runtime? For example, first-class support for game development is mentioned in the GitHub readme, so I am mostly thinking about modding use cases when I ask this.

- In PWCT 2.0, is there a way to directly import PWCT source files without exporting to Ring source code first? I couldn't seem to find any mention of it in the manual.

- Are there any notable limitations to using PWCT 2.0 as a result of, for example, not being able to create my own components yet?

Thanks!

Mahmoud Fayed

unread,
Oct 16, 2023, 5:31:26 PM10/16/23
to The Ring Programming Language
Hello Ari

>> "I picked up PWCT 2.0 during the 90% off sale because I was curious about it and I've been meaning to try Ring out."

PWCT2 is visual programming language on the top of a textual programming language (Ring)
This provides multiple options about how we can use PWCT2

(1) Using PWCT2 as a visual language where we think only about visual components and steps tree generation through interaction with these visual components.
(2) Using Ring code to generate the steps tree (Interactive Visualization) so we get high writability from Ring and high readability from PWCT2.

Understanding Ring concepts is necessary in both cases. 

>> "Is there a means of allowing user-defined scripts to be loaded at runtime?"


In PWCT2, we can write Ring code directly, OR we can use the Eval() component
good.png

>> "In PWCT 2.0, is there a way to directly import PWCT source files without exporting to Ring source code first?"

No, because PWCT visual source file are just design files, we must generate ring source code from these design files before execution by Ring Virtual Machine (Ring VM)

On the other hand, these *.pwct files are just (Ring Source Code) that define lists that determine the steps tree, generated source code, time information, values for data entry forms.

So, What PWCT2 does is reading these lists from PWCT files, then processing it to get the Ring source code
You can develop a program that does that, but in practice, we don't have to do this because PWCT2 automatically generate the Ring code once we save the PWCT visual source file.

 >> "Are there any notable limitations to using PWCT 2.0 as a result of, for example, not being able to create my own components yet?"

No limitations, but we have missing features.
No limitations because anything can be done using Ring, can be done using PWCT2
But as expected we have many missing features that could be added to PWCT2 to have a better tool
Many of these features already exist in PWCT1 like creating custom visual components.
In the future many features will be added to PWCT2 

Greetings,
Mahmoud

Ari

unread,
Oct 21, 2023, 10:55:44 AM10/21/23
to The Ring Programming Language
No, because PWCT visual source file are just design files, we must generate ring source code from these design files before execution by Ring Virtual Machine (Ring VM)

What is the proper way to manage large projects, then? Is the only way to do it to have one PWCT source file per Ring source file and export them individually before importing them into other PWCT source?

Ari

Mahmoud Fayed

unread,
Oct 21, 2023, 11:05:54 AM10/21/23
to The Ring Programming Language
Hello Ari

>> "Is the only way to do it to have one PWCT source file per Ring source file and export them individually before importing them into other PWCT source?"

Yes, Each PWCT visual source file will generate a Ring textual source code file.
But this operation is done by PWCT automatically once we save a PWCT file.

Each large project could be a group of folders & sub folder
And each folder/sub folder could contains one or many of related files. 

These files could contains group of functions
Or it could contains one or more of classes
These classes could belong to a specific namespace/package name.

The way we organize a project depends on the project size & what we prefer.

Run PWCT2 - Click (Project Files) and open (GoldMagic800) folder
It's an example about using many files in the same project

shot1.png

shot2.png

Greetings,
Mahmoud
Reply all
Reply to author
Forward
0 new messages