Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length

 
Advanced search

1397321 Posts in 67457 Topics- by 60681 Members - Latest Member: benchmarkses

December 07, 2021, 10:48:32 PM

Need hosting? Check out Digital Ocean
(more details in this thread)
TIGSource ForumsCommunityDevLogsBunneh
Pages: 1 2 [3]
Print
Author Topic: Bunneh  (Read 4457 times)
Xander Bunny
Level 9
****


By Joseph T.P. Corcelli


View Profile WWW
« Reply #40 on: November 12, 2021, 09:08:07 PM »

I got the start menu on the laptop interface to display early this week, it's not the fact it displays but it's a prototype for how buttons will work at the moment. So, I can see the atomic scale of work in action. It's a little lackluster still.

I've begun to put the variable capacity of the system to practice. Ok, that's all you really need to know but I like to write a lot. Here are more details.

...

I've had to relearn what I'm working on. Here is what I learned.

The basis of the game is augmented dialogue. I wrote a calculator so dialogue and physical filters intertwine. The game industry calls the approach I use systemic design.

GUI generated from text is an amazing idea for this circumstance where I already wrote a dialogue calculator. Specifically, the text can be copied, altered, and display generated graphics with randomized flaws later, and because it's a GUI that can turn a useful prompt into something confusing or broken.


I am programming widgets now. Things like radio buttons...

The system I modeled emulates a real-life context: 1 interface, n apps. There's a slight differentiation between the two in code. In practice, interfaces determine how apps are displayed and accessed, ie a laptop shows us software, and software has icons and it's stored in a hard drive, etc.

I wrote this at the beginning of the day. Now, what I wrote at the end of the day.
...

The way that I interpret GUI has changed quite a lot as I iterated. I just finished understanding how it works all over again.

The concept of shared resources often calls on HUBs, subscriptions, and limited scopes. Ok, I don't know where the heck things were going to be while I wrote the system, so I wrote search methods instead.

And then there are variables with global scopes, literally, they will affect everything. Is the laptop plugged into a powered wire? Or How's its battery? Both amounting to, is the laptop powered? And if so Is the laptop off? (yes it's off) Then I shouldn't see the screen. The OS emulation needs to go through a boot sequence if it's turned on again later. The apps should all be off. All progress should be lost, but a player character will remember everything. My attention to detail here might be a bit much, I haven't implemented this yet. Vice-versa, turn off the app normally and it auto-saves. Nothing changes but the player character, an emulation of semipermanent changes in behavior, and soon to discover that the app does in fact auto-save, to a particular player character's relief.
Logged

Feel great.
Xander Bunny
Level 9
****


By Joseph T.P. Corcelli


View Profile WWW
« Reply #41 on: November 14, 2021, 08:29:31 AM »

Logged

Feel great.
Xander Bunny
Level 9
****


By Joseph T.P. Corcelli


View Profile WWW
« Reply #42 on: November 22, 2021, 06:54:01 PM »

So this week I moved the interpretation of inner-scoped variables to take place in an object's unique interpreter, if that's desired. A set of rules are also easily defined by mixing classes. I already knew how to do this already because I wrote a lambda interpreter. So the only thing left to experiment and implement is a default ruleset. I added the potential to call on custom functions, and any string being interpreted can also be altered on the fly allowing for, anything, but more importantly, I can write a "variable" like a fake OS registry, inside of code... that emulates an OS. A folder like C/users/%user%, for Jerri, would add a folder named "Jerri" to C/users, close enough it resembles a real OS.

...
Everything after this point is pretty complicated, so, if a GUI can be generated to a satisfactory level before I get to really implementing control logic, I might say the foundation for the code is pretty much done.

I modeled the Bunny Datesim as a mockup which involves control logic and potentially loading assets, issues I considered but haven't begun programming yet. I'm sure they will work, but will it be optimal?

keywords
There are a few keywords that declare lists.

rulesets
If it turns out that I'm better off reusing rules by scripting them, I can add another keyword.

Control flow
A C# script is probably good enough.

But this new scripting language is high level. Virtual methods can have their body interpreted at real-time allowing for sequences to be modified at real-time. Sentinel variables implement selection. Loops? No loops. It should be safe for program illiterate end-users. In the same sense that dropping your W...... OS folder into a trashcan doesn't sound possible, but you can probably do it. I had a M........ for a couple weeks, and I put the M. C...... icon in the trash to see, and it never turned on again.

End-user Safety
This is a very high-level interpreter, it should be difficult to cause it to slow down or crash the game. I won't claim to know what it can do, even if I program it entirely, but I'm pretty sure.

I have added coroutines to my parsers in the past. So, when I write the parser that interprets virtual methods, you can bet I'm adding a coroutine that handles real-time scripting separately.

Programmer level control
Regardless, GUI always follows whatever the prefab's script tells it. So, if someone writes C# and then calls it from a script, that's not what I consider end-user programming. I'd have to write an initial class that understands more intricately defined rules and force it to be inherited, I'm not going that far.


Initial concept
My initial idea was... optional:
Some variables declared in components are global
nevermind this isn't going to make sense without a longer explanation.

Hypothetically, the GUI has a built-in event system, already set up. It will require a bit more work to add control logi. In practice, an event system is already working as I have described, all the components can easily subscribe and listen, so I just want to build off that to produce an automatic connection to common methods.
« Last Edit: November 23, 2021, 10:59:57 AM by Xander Bunny » Logged

Feel great.
Xander Bunny
Level 9
****


By Joseph T.P. Corcelli


View Profile WWW
« Reply #43 on: November 27, 2021, 02:48:32 PM »

Variables are now read in ways that I find acceptable. Although it's not exactly what I want.
edit: It works like I want now, although I will be removing redundant keywords so if A is variable, and B is in A without another declaration, B is obviously a variable unless it was added by another script, soon as I get back to it.

Any variable between brackets reference a dictionary. Components reference a prefab. And most importantly, bracket variables reference components defined in the script. All other variables are inert for now.




edit2: I am trying to get to the good part sooner, but I have to prioritize tweaking the parser to enable code like:
Code:
# within a bracket delimited object, each of these will declare a
#component within it ( a component is actually some kind of Unity
#GameObject at the moment, it'll be like that for the foreseeable future)
object{
AComponent, Name

DComponent:
BComponent:{}

EComponent,
CComponent,{}
BComponent,:{} #why? idk


# I even acknowledged that it might look better to list things in one line without a
#fuss and added semicolon as a soft line-break
GComponent:;KComponent:

}

# but generally a component with a lot of functionality looks like...
D, Name:[activator],[operation]
{ #body#
 #keyword, variable, method, component, or window,
#A window looks kind of like ASCII art, but that is only one possible use.
+---+
|   |
|   |
+---+

}

# one big component definition like this can be assigned
#to a variable and spread around the document making it
#incredibly fast at populating hierarchy lists
#very fast string-searchable
#codable, parametric, and easily marked up, that's all so far. Functionality, coming soon.


I went out of my way a long time ago to get the window portion of the code working. I'm glad I'm able to address even these mundane bits while I'm returning to programming adequacy.
« Last Edit: November 29, 2021, 09:03:19 AM by Xander Bunny » Logged

Feel great.
Xander Bunny
Level 9
****


By Joseph T.P. Corcelli


View Profile WWW
« Reply #44 on: December 04, 2021, 08:49:55 AM »

I've been working to interpret the methods:
As a function called by the interpreter, works fine. I can also use this to call a validating method and check if the variables are in scope.

As lambda.
Code:
OnClick(){
...Do this...
[if this][ANDthis]...Do this...
... Keep going...
[not this]...Do this....
[this][this]...Do this...
... Keep going...

[this] exit

}


I should add an else. I should add an or. I need to test this next week.

Finally, a method is easily a more interesting variable if I can change its definition on the fly. A bit-wise comparison is fast, and it can be very complicated, but it's not Shakespear.

Different topic the calculator
This is one of my more abstract filters for a series based on detection, which either does or doesn't allow a portion of text to be read.
Code:

public DChemicalFilterIn(){type = "Chemical.in";}
public override void Filter(Redacted t)  {
int hits = Intersection ();
string binHits = Convert.ToString(hits, 2);
int spills = Spills     ();
string binSpills = Convert.ToString(spills, 2);

int total = Convert.ToString(chem, 2).Count('1');

hits = binHits.Count('1');
spills = binSpills.Count('1');

captureRate = (float)hits / total;
spillRate = (float)spills / total;
if (captureRate >= UnityEngine.Random.value)
Redacted.captured = true;
else
Redacted.captured = false;


}

Basically, "captured" is the most important point, when the variable is set the stream of text will be transferred through the calculator into the scanner, and if that's connected to long-term memory it's copied there.
Logged

Feel great.
Pages: 1 2 [3]
Print
Jump to:  

Theme orange-lt created by panic