Found this tutorial on Space Invaders in Python pretty Cool. Alot of people are interested in game dev... so it may be interesting for some people? it's in PyGame not Tkinter, think for advanced Sprits you can't do it in Tkinter. But see in some tutorials you can include both. If you can 100% integrate or not at this time have no knowledge on that...
Wednesday, December 11, 2024
Monday, December 9, 2024
DTR in Python
Sunday, December 8, 2024
New method for associative arrays
What you think about this method I created?
char array_keys = {"empty", "full"}
char array_values = {"0", "0.1", "0.4", "1.20"}
int array_map = {[0,1], [0-2], [0-3], [1-4]} (multi dimension array to link stuff for us)
int array_deleted = {[0,1,V], [2,0,K]}
(*this part was added after) we could also add delete because in some language once deleted the field still exist as empty. When creating dynamic layouts the fields will still show. You can check if they are empty in the code but you have more options this way like adding stuff to deleted fields, instead of creating new ones. May need a 3 dimension array to represent also what kind of field : keys or values.
it instantly creates category's and avoids keep track on thigs you just add and remove.
just feed the loop width this 3 arrays and it do the rest.
and we have the information all structured for us :
empty : 0, 0.1, 0.4
full : 1,20
You can do it width other stuff like OOP but if need more performance.
Tuesday, December 3, 2024
DTR 2.0
To start any project we need to store data.
After tweaking around width XML and though is so restrictive i got the idea of adding more stuff to DTR so is becoming really good. (The DTR is the costume format use to store data in project)
The top of the file represents settings for it. the first version only worked width basic lines in 1.0x and now add groups, and it represents all kind of things.
Add:
- Keys (already in 1.x) avoid adding then again in file is declared only one. It makes it harder to read from file you need a interface to represents. The goal is to make faster files.
- groups to mimic xml
- type of interface to load,
- costume scripts you build,
- Separator : how to add data to the files: line for for editor or grouped for manual input,
- settings to tell the prog how to tweaking a style
- The type is still under dev don't know... it allow to have different styles of data in the same file
- Lines reference to set performance points. Lets say that characters are at 100+ line, and spells at 1-100 line. This prevents him to search so much.
- the settings end after the maximum reserved lines in here 8 lines. After that assumes data input.
- *Missing a function to remove efficiency mode for the keys in this case you need to type all the keys again for witch entry.
Keys : Name, Code, Notes, Dependency's
Groups\Tags : Language, Library, Macro
Interface : Template A\grid left
Scripts :
separator\view : #,line
Settings : background gray, topics font Arial 24
type : macros, characters
Lines reference : <100 characters, >100 spells
<python> #groups like XML
<tkinter>
# group for manual type. easy to read and input data from file
label;
variable = Label(root, text="info", width=20, font=("bold",15));
needs parent element in here named root;
# Line keys input by interface hard to read from file
button; variable = Button(root, text="Register", command=register);needs parent element in here named root
# Efficiency mode off, need to input all keys.
<button>
<macro>variable = Button(root, text="Register", lambda: function(values)) </macro>
<notes>lambda used to pass variables</notes>
<dependencys></dependecys>
</button>
Thursday, November 28, 2024
Tkinter
If you do not believe me that is easy to work width Python take a look at this video, how easy is to set up things up.
Thursday, November 21, 2024
Wednesday, November 20, 2024
How fast we develop in Python
Monday, November 18, 2024
Python 3x Version
The project moved to Python.
C language is to complex for a "realistic learning curve". Only hard core programmers can program in it.
This new version of Python 3 is great. I was able to complete a hole bunch of tasks width only 20 errors. In terms of productivity is like 1000% increase compared to C.
Using the simplest GUI library Tkinter which is the standard included in Python. Found tutorials for Tkinter for all kind of things.
The fact that is interpreted and not compile produces less bugs since is less restrictive.
When I try Python 10, 20 years ago was to buggy to use. The white space tab function was constantly giving errors. But after 20 years of development they improve this pretty well got almost no errors from white space.
The fact that it does not use "; " semi-colons seems a bit strange but, it do increase your readability of the code.
Most effective 30 MB donwload you can get. This is because is independent of 3º party programs, as they develop all things editor and language.
3 clicks is all it takes to be working : download, click the editor, put your prog code on file and click execute. On Codeblocks IDE the compiler some times does not work.
By the amount of tutorials you need until is working you can see is effectiveness. Only 1 tutorial is enough to start working on your app, while in C you need hundreds of hours\tutorials.
The amount of code is much smaller in Python most progs are 50 lines, for C\C++ is more, width all that linking happening in code, semi-colans and the { enclosing tags.
For some reasons Python is the 1º and most used language at the moment, is able to complete all kind of tasks width efficiency. It have the low level input merged width high level ex: manipulation of files, and high quality of GUI's.
Most social networks say its user base is well above 1 million of active developers.
Some one say on the project, Lyberta : "you will not get any help in C", this change open the door for people be able to do so. As at least is easy to tweak stuff around.
https://www.python.org/
Monday, July 8, 2024
Odin Programming & array programming
At their site or in the manual we can read array programming which is something is heavly used in PHP. Think one of the best things to use.
Din't have much time to study this but so far looks cool.
We have width this language extensive suporting it...
Construct an array with designated initializers:
from : https://odin-lang.org/docs/overview/#fixed-arrays
We can see 2 new features to C lang and i think low level in general :
Assign by index and ranges. Ranges is something new to me having the same value populate several fields it may be helpfull in manipulating large fields of data like in Journals for example.
More info check the link manual... "Something in developing..."
favorite_animals := [?]string{
// Assign by index
0 = "Raven",
1 = "Zebra",
2 = "Spider",
// Assign by range of indices
3..=5 = "Frog",
6..<8 = "Cat"
}
New Programming Languages
The use of Chat GPT really speeds projects up you don't need to search for things you just type commands.
Was informed about how really this libraries are working like SDL and Ray Lib they are kind of wrappers to xlib and OpenGL which are direct library to work width.
A side note : no one in a couple of years of search was able to tell how this stuff as doing. This is really a advantage to use ChatGPT.
Once i explored this 2 librarys I could see how the C language is praticaly dead from the point of view of development. Both C and C++ are propertery licenseded they do not have open repositorys. Which translating they don't evolve.
Also to add to this C have great amount of bugs which are not easy to fix by non C expert. This thing are supose to be fixed at development level not at code.
Most of these stuff in C take ages of configuring, like: strings, loops, types. No serius developer whant to configure these things. Because why do it at local level : "all most also do it", when it can be done at language level and is available to every one.
So i though ?! no point in using C and assembly is to complicated for or neededs. Then check the development of new languages and find out a lot of information. This guy is gathering information on the main programing languages being develop at the moment.
He is set on github : https://github.com/robertmuth/awesome-low-level-programming-languages
and come out width this list. I explored them a bit and a few stand up from the rest. They all if not most attempt to replace C at low level language:
- Odin seems nice is a programing language already being used in comercial. if you check their github rep is extremly active it have updates just a couple days ago and so many forks and contributers. A note on Odin it seem focus on game development which so many intuasiastes : "we may see a implementation of a new laguage";
- C3 also seems great but i don't see that much activity as in Odin. The concept of adding new things to the old C seems the way to go or at least a good solution. You get the style that you like width updated things like boolenas and foreach loops and classes;
- People in the comments talk about : Rust, (Odin) Nim and Zig; watched a video on youtube about Zig this lone guy width "just a few hours analising C code updated and fix it". "There isn't not much interest in updating this things" by the companys behind it...
- D also seem stable is being use at company level and they put all their work out there seems nice; A note on D it have many inovating stuff like : unitests, interfaces, classes and so on...
- Other do a lot of stuff for web like Crystal also seem realy adavantage;
- Rust is also debated Thing. Is being used in Firefox which shows how people don't trust C that much.
- Some represents this style of not using pontuation. People that prefer Python look it is also available at low level.
- The conclusion : all this people have done their share and are doing a great work in implementing new languages.
- ATS
- Ada
- Alumina
- Beef
- C2
- C3
- Carp
- Cone
- Crystal
- CSpydr
- D
- Forth
- Hare
- Hylo (formerly: Val)
- Jai
- Kit
- Lobster
- Modula-2
- Nim
- Oberon
- Odin
- Pascal (FreePascal)
- Rust
- Scopes
- V
- Vale
- Vox
- Zig
We can check a GUI implementation for Odin in github. the code is so small to implement a full interface. A lot of stuff being wrapped.
Wednesday, March 6, 2024
Rules
Rules, Steps & methods
This is the current way to implement and be implemented but there could be more things to add :
- Root or loader (which load things in to the interface, all frameworks\engines have or should have a loader, so it automates many things).
- Prototypes or Pseudo objects (can also be called schemes, whis is what they are schematics for problems solved or rules)
- Global inheritance ( like Variables in scheames, may also be defined as inherarquy)
- Stack Librarys (format code in files that can inherit global variables )
- Fuctions (also should work on a global scale)
- DTR (Database text fromat reader, a kind of tool to improve performance, but a thing that all project uses they way to deal width information can also be called data structures)
- Stand alone programs (for easy to develop, this is optional you don't need to do like this)
- Standard Coding (which we could divide in to several parts like standard names, a fixed set of names so that we can access at any time)
- Unit tests (tests should be available in any project that have a large size.)
- Librarys (part of standard coding, a basic set of high quality raw assets that allow to create and set up a project, their names should be standard so that they are ready to include).
- Structure (this is kind of a more theory, once we decompose our framework or engine in to all this steps we have a structure framework. Every thing is decomposed on a ready to use hierarquy... )
- Hierarquy (part of the structure a simple way to see what we need to have at the higher levels)
- Templates (applay the standard structure that we can easy use templates in to projects)
- Modules (a bit the same as templates)
- Interfaces (can be a part of templates
Monday, March 4, 2024
Status of Project & Updates
- Chaged the posts on tutorials and debate on what language to use on it's own forum this one will only be focus on posts relevant to this project beginner programing will be at the other blog:
- Organized even better the posts and improve them. Now when you start reading the information should be logic connected and ordered
- Also moved things relevant to game develop in to a blog so is not mixed up
Global Inheritance
The main reason for a adopt a object kind of style in procedural programing is because procedural or raw programing style is to complex. We can see that functions, the base of prog is to hard to manage.
This is done by separete "settings from logic" in the functions.
A example of a nested function that recive 3 variables:
Function test_vars(var1, var2, var3)
{
int result;
result = var1 + var2 + var3;
printf(result)
}
These aproach have 2 main problems. One is scoop of variables and the other is the nesting of variables.
Enviorment or scoop for the variables demands thats calls to be used in conjuntion width function "test_var" its assume the same scoop or enviorment.
which is often local, need to have them keep close or in the same file due to this connection.
Example of a file:
int var1 = 11
int var2 = 4
int var3 = 3
test_vars(var1, var2, var3)
The secound problem :
the test_vars() once changed need to be changed in 40 files. Like if we need to pass 4 variables or no longer need to pass a 3º variable. The problem is that now we already callned this function in this format in several files. Is to static to work width.
Solution :
Make variables global to not need to change our functions we just need to chage 2 file and is where the function includes are.
Our new variables which represent prototype file and the function file where our test_vars() is, width the new functionality on the function.
The "includes" folder should have a global_variables.h file width all our global variables.
This stuff grows by adding more prototypes. So your global_variables file have all this prototypes for call kind of actions.
the new enviorment looks like :
- 40 files calling the functions test_vars()
- 1 file width the global variables.
- 1 file width the global function.
- test_vars() no longer is nested we can do width it all we want to.
Our new format transformas the function in to more a link for funcionality then a funcionality it self. Which is often is better. The more static you build harder it is to change which leads to more work needed.
Sunday, March 3, 2024
Hierarchy
The hierarchy concept is pretty simple, things that have more dependencys are at the top or higher level while those width less dependecy are at the lower level.
A login pseudo object does not need to be in the top level, since is only used at the login interface.
- char login;
- char login_name;
- char login_user;
- char login_password;
- char login_db;
Pseudo Objects or Prototypes
Pseudo Objects work as Object in OOP programming but they are applied in a Procedural Structure. Which i called structural programming. Pseudo Object that we are using can be translated easily to object programming since they work the same. The diference in here they are all global so this represent our global_variables.h. The unic naming avoid name collision and help our global_functions to access it more easy.
Our objects currently in development:
- -Text
- -Folder
- -Path
- -Link
- -File
- -Error
- -Test
- -Font (still in dev)
- -String
- -Memory
- -History
- -Array
- -Loop
- -Login
- -Paginator
- -Effect
- -Menu
- -Settings
- -Translation
- -Window
- -Layer
- -Graphics
- -Position
- -Color
- -Space
When we access your "global_variables.h" file we should be able to see the variables prototypes for this topics. If you read on Objects and OOP oriented object programing you can read. The main issue is delegation. When a object is doing to much and other is doing to less. The work and work in development is to balance this objects back and foward that they represent cleanly the task that they should deal.
In the interface we have several elements that we need to decompose in to p-objects:
-Menu
-Button
-Box (html for example, use: list, div, span, ul, etc...)
-Links
In here is not properly implemented is still in "property" which was a bit abstract but is a good example on how to implement objects. So it was a kind of to generic aproach to implement one of the refered elements. It become to big becase is not specific enought it will lead to bad programming. But still we can see the decomposition that is necessary in order to achieve prototypes.
int property_id;
int property_name;
int property_title;
int property_button;
int property_background_color;
int property_3d_model;
int property_padding;
int property_margin;
int property_pos_x;
int property_pos_y;
int property_pos_z;
int property_clickable;
int property_image;
...
button_image;
button_padding;
...
menu_image;
menu_padding;
...
A better way to do this is to manage only one property in this case "space".
- char space;
- char space_name;
- int space_type;
- int space_amount;
- char space_element;
For the background instead of puting a background in all items we can administrate width the color p-object.
- color;
- color_name;
- color_type;
- color_number_hex;
We are going to repeat our self's if we create a button, with background color, then a menu with background color, then a interface with background color and so on...
In this way we have a prototype for color which we can access and use at any time. Allow to programing width less knowledge. Any thing realtead width color\s it maps to the color object we don't need to search where the color is or study about color,s background and color connections.
The only draw back on this aproach it lead to more code in some parts not all since we reause, but is like unity tests that repeat code. Are they bad? like if you can program your app in 4 hours why do it in 8. But lather if you spend 3 days looking for a bug or 1 weak learning this new framework time can be over consume rapidly when things go wrong. In programming better play safe.
Paginator on pseudo object example
This example it show the evolution of the application of variables.
Lets look at a paginator.
Often we only declare one variable : "string paginator_result". and applay the math directly on it. So it may end width something like : paginator regult = (100 / 10 = 10).
But some parts repeat throw all programing languages. Expecialy the variables involved in Math in this case: total rows will devide by rows per page to achieve the amount of pages to be filled or be display in the interface.
So we have 100 rows per 10 items we goat 10 pages and this need to go in to the interface. By this example you can understand that our prototypes start to assemble. As we dismount more and more parts of the planning in to the structure that's why i call it structural programming we start to assemble a structure throw prototypes.
lets see the new look, but if we separte in to parts the paginator :
- paginator_total = 100
- paginator_rows_page = 5
- paginator_current_page = 1
- paginator_generated_pages = 20
- paginator_name
- paginator_id
- paginator_total = 100
- paginator_rows_page = 5
- paginator_current_page = 1
- paginator_generated_pages = 20
- paginator_db_extension = mysql
- paginator_type = dtr
- Code will be just a raw paginator
- DB a dinamic throw the db
- Test a DTR dinamic file access
Friday, March 1, 2024
Natural writting
Why adopt this style of natural writting?
There are many reasons:
- Performance to use procedural
- Maintanability of code since we need some kind of oop structures
- Computer lights are hypnotic
The computer lights are hipnotic. You can't concentrate on the computer. The concept that you can writte in any way you want it work in theory in pratice it will lead to problems. In Facebook there is a post there debating width the title "I cant read my code afther some time" this is because you can't memorise that well from computer due to this effect of these artificial lights.
To play games is ok because you are not concentrating but actually using a lot of reflexes. For that is very suited.
But for planning and maintaing code is not that great because you need high amount of concentration.
That is one of the main reasons to adopt a natural way of writting code. The others may be better maintanability and reusability of code.
In this style you can writte large blocks of code before you need to test any thing. It have a feel like a natural language.
You need to memory less stuff may be another important point since all is very structured. Since we can't memorise large amount of stuff from computer. Having the code structure in a way you need to memorise less seems the way to go...
Of curse performance is always nice to be able to execture things in a faster way even if computers evolve which is a claim from programmers to use this heavy librarys you can always save some electicity.
Stack Librarys
Inside the structural programming methos refered there is stack librarys. A set of of includes files that deploys complex funcionality.
width less resurce demand? In s cases it may decreases resurces consumption wihch increases performance.
Name come from that they can stack or inherit so they are a file that works width the structure.
When you include the "file" you gain a new set of funcionality. This saves resurces because is not functions but basic code and gain a bit of reusability.
For what i tested both files .h can communicate with which other. The ".c" extension can't access which other files.
The .h files need to be in main, to work with variables, because of the single treat thing. People for what i read advice not to use variables inside .h but only declare them. This way we can use files like in PHP.
If we whant to implement several things is better to have a file then a function :
- Verifications
- Unit tests
- Errors
- Variables
- Open things
- Memory handle
- Interface load
In here we have a good and a bad example of stack lybraris. A bad example will be image since is to general is more content for a pseudo object. A good example is image_jpg which we need to load a specific set of verifications for the jpg which are only needed for the jpg but are very complex for a function.
- image
- image_JPG
include "button_effect_fade.c" // the fade effect "should be added".
image_jpg.h is inheriting successfully from image.h
We can see now a structure in the main. Looks is like a configuration page. (is Tweakble in the code or lather outside with a interface.)
The point of this is , if some one code a camera_RPG for their game if using a inheriting structure, can be use in your game also. A waste of time we all have to program that rpg camera again and again.
- time.h"
- error.h"
- file.h"
- string.h"
- paths.h"
- database.h"
- image.h"
- image_jpg.h"
- image_png.h"
- image_gif.h"
- sound
- keys
- resolution
- interface
- model
- model_textures
- model_animation
- model_particles
- model_bounds //colision, triggers
- model_blend
- model_DAE
- model_FBX
- model_OBJ
- camera
- camera_RTS
- camera_FPS
- camera_2D
- camera_3Person
- print_screen
- movement_RPG
- movement_Vehicles
- AI
/* GAME STRUCTURE LIBRARY */
- game
- money //timers
- loots
- spells.c"
- abilitys.c"
- items.c"
- items_sci_fi.c"
- items_rpg.c"
- items_fantasy.c"
/* TEST LIBRARY */
- //#include "variables_interface.c"
- //#include "interfaces/interface2.c"
TOOLS LIBRARY
-Interfaces can be in .c since they do not delegate any to other files.
-The previous .h files cam delegate to .c files.
*/
if(interface == 0){ // Main Menu
//printf("Main Menu loading");
#include "interfacces/main_menu_GTK.c"
//#include "interfacces/main_menu_SDL.c"
//#include "interfacces/main_menu_Free_GLUT.c"
}
else if(interface == 1){ // Character Creator
//printf("Character Creator loading");
#include "interfaces/character_generator_GTK.c"
}
else if(interface == 2){ // Shadder Tool
//printf("Interface2");
//#include "interfaces/interface2.c"
}
else if(interface == 3){ // Map Editor
//printf("Interface3");
//#include "interfaces/interface3.c"
}
else if(interface == 4){ // Variable Manager
//printf("Interface3");
//#include "interfaces/interface3.c"
}
else if(interface == 5){ // Generic Animation
//printf("Interface3");
//#include "interfaces/interface3.c"
}
else if(interface == 6){ // Particle Tool
//printf("Interface3");
//#include "interfaces/interface3.c"
}
else if(interface == 7){ // Particle Tool
//printf("Interface3");
//#include "interfaces/interface3.c"
}
else if(interface == 8){ // Level Models Position
//printf("Interface3");
//#include "applications/the_box/levels_models_position.c"
}
else if(interface == 9){ // Level Editor
//printf("Interface9");
//#include "applications/the_box/levels_models_position.c"
}
else if(interface == 10){ // Database tool
//printf("Interface9");
//#include "applications/the_box/levels_models_position.c"
}
else if(interface == 11){ // Options
//printf("Interface9");
//#include "applications/the_box/levels_models_position.c"
}
system("cls");
system("pause");
return 0; // Zero indicates success any other failed
}
CSS style
This is the code for the Code Editor.
-> Inherit global variables
-> Inherit global functions
-> Calling global variables to set up the code editor interface
Variables Prototype for general settings ( this case is a title)
measurement = "px";
width = 800;
height = 600;
background_color = "white";
Variables Prototype for title
category = "tile";
text = "Code Editor";
text_style = "underline";
text_size = 30;
localization_top = 5;
localization_left = 10;
Ex: Code Editor
Variables Prototype for loops auto builds (general settings)
loop_name = top links
loop_data = "file";
Variables Prototype for top links
layer = 1;
background_color = "white";
build_background();
category = "menu links";
localization_top = 5;
localization_left = 100;
background_color = "#32383a"; //Gray
text_size = 20;
action = "clicable";
layer = 2;
region = top links
hight = 100
width = automatic
link_id = 1;
link_name = "File";
link();
link_hover();
link_id = 2;
link_name = "Edit";
link();
Variables Prototype for left panel
category = "left panel";
localization_top = 100;
localization_left = 5;
text_style = "bold";
layer = "top";
link_id = 1;
link_name = "Categorys";
link();
Variables Prototype for left panel
category = "right panel";
localization_top = 100;
localization_right = 5;
text_style = "bold";
layer = "top";
link_id = 1;
link_name = "library - ";
link();
category = "code area";
localization_top = 100;
localization_left = 100;
text_style = "bold";
layer = "top";
while(1)
{
view_lines = 1
view = "display width line"
open_file()
display_file()
}
Folders & files types
Current Structure :
- Includes ->
- Stack_librarys_inc ->
- Header ->
- Macros ->
- External Includes ->
- Data ->
- Librarys ->
- Abstract ->
- Main ->
Structure width discription :
Samples -> Example projects width diferent librarys and code frames for games layers or projects.
Librarys -> Better organized Files, filtered and ready to work by themes. Is supose to work width library tool to also organize links to files. And also to work width file browser to organize this stuff for us.
- Images icons
- Images Art
- 3D models RPG
- 3D models Sci-fi
External Includes -> thought in putting inside the main folder, but outside it's easy to update and its very large. External Library: mainly for external librarys which is not develop by this project.
- GraphApp ->
- EZ lib ->
- Vulkan -> will pack some form of install
The Box ->
Progs ->
- tasks.c
- projects_web.c
- dtr.c -> database format text reader. To improve access to information.
- links.c
- tutorials.c
- structure.c -> the structure mecanics develop, is not related to the general structural filosofy of the box, but a dedicated tool to handle things.
- Forum -> it reflects well the philosophy of the software which is to have tool to automate a great deal of tasks. It allow to administrate forums in a much more robust way.
- librarys.c
- File_browser.c
- Back_office.c
Main -> will include all stand alone parts, now we have several mains, depending on what thing we want to work, also good to explore diferent librarys that we may like or not. Or even pending for an update.
- GTK 4.6 -> High level funcionality
- Ray Lib -> High efficiency in code design
- Ncurses -> Low resurces demand
- graphics.h -> Study of basic funcionality
- Vulkan -> High level graphics
Abstract -> Settings are a good example of abstract thing is used, have no dedicated panel or tool, it is a sub include.
- Settings.c
- Font.c -> raster types for font(+-)
Includes -> how it's devided. Standard in here it means it's adopting the general structure of TB design.
- Standard_variables.c
- atandard_variables_game.c
- standard_functions.c
- standard_functions_game.c
Headers/Macros -> Generic dumping of macros.
- Macros.h
Standard Programing
The same variable name need to be accessible also in other languages the amount of work for that is pretty large.
The concept of standard programing main categorys : Variables\Folders\Templates\Files\Functions\data\DB\Includes\Translation\Color\Paths
- The Variables which we can devide in several categorys:
- Settings - Often hold a pre value to be tweaked
- Rules - Kid of setting but more specific
- Values - Math calcs
- Information - Arrays
- Function kind - Fragmentation of function parts
- Data - Mainly raw info for db or files
- Functions
- Think in C we can prototype functions but is not that advanced at the moment.
- Templates
- Another thing that can facility our life is to have a standard way to connect between code and interface.
- Design some main categorys so that we know which is doing what.
- Files
- How to acces your files and set a better path to files to be better to use standard.
- Data Base
- Databases often have a lot of redudancy and repetition. And one of those things that does not have a standard way of doing. It can extract alot of redability and accessibility.
- But dbs are a complex thing to do standard since the way they are build is to create modularity. While in code people create modularity because they want. Is not that needed.
- Data
- Data is one of those things that is lacking a lot of standards. Since companys often encode their code many of this files are not open source or are coded on top of the format.
- But acces them in a standard way could create a lot of better code.
- Folders
- Folders already debated often they are not organized...
- Includes or Librarys
- Includes inherit alot from the standard way. But depend on how you are going to stucture your project.
- Still a bad planning of the includes will also end up causing problems in mainting code and modularity.
- For example many C librarys have a poorly implementation and could gain a lot if the moved to a standard form of implementation.
- Translate
- One timne shaw a guy asking where is the translate? Actually width so many years of programming there isn't still a simple and automated or maiby standard way of accessing it.
- And translationg is something that most probjects as they evolve will eventualy need.
- Color
- Add colors in a standardized. Which application have a diferent way to add them hold be nice to have some kind of standard. Can you imagine the amount of work that could be saved? (
- At this time in 23 i need to change the color of the of the page. I know the code and i know the hex where do i applay? I do not have a standard way to know where it is still i have the knwoledge to do it. What that means? a couple of hours searching and testing. (waste of time).
- Paths
- Well there is a lot of stuff that we can make standard. But for now think this is more or less ok. Need to update more things. Paths is kind of a minimal thing. Not all small details are that relevant. Like if something makes you waste a couple of hours which time is relevant but if is just a few minutes...
Project obj
Variables are divided in :
- Hierarquy variables,
- CSS inherit
- Prototyping.
Lets assume that the variable "project name" is always "project_name". We could start writing functionality for a project that even don't exist at the moment. We just need the "global_variables.h" file.
Example:
This game have some kind of new functionality. We assume that we can start linking project width project_name variable and adding new functionality to the character : character_name, character_attributes_x;
This how project file tool is looking like, how we map the hole thing width variables and start building the structure. All variables are global. We can't collide variables names.
char project_name;
char project_language;
char project_type;
char project_files;
char project_functions;
char project_variables;
char project_folders;
char project_folder_structure;
char project_language;
char project_modules;
char project_author;
char project_contact;
char project_license;
char project_published;
char project_links;
char project_library's;
char project_snippets;
char project_compiler;
char project_articles;
char project_themes;
char project_templates;
char project_maps; // or levels
char project_images;
char project_fonts;
char project_sounds;
char project_3dmodels;
char project_divs;
char project_file = '\..\dtr\project.txt';
char project_index; //project array index to map the project DTR file
Objects in procedural
Show the work in the interface.
For example in the interface we have several elements:
-menu
-button
-box (html for example, use: list, div, span, ul, etc...)
-interface
-etc...
people can separate in to how many fragments they want.
What i did is convert it in to a object to avoid repetition:
int property_id;
int property_name;
int property_title;
int property_button;
int property_background_color;
int property_3d_model;
int property_padding;
int property_margin;
int property_pos_x;
int property_pos_y;
int property_pos_z;
int property_clickable;
int property_image;
to avoid :
button_image;
button_padding;
...
menu_image;
menu_padding;
...
We have only one element, because we are going to repeat our self's if we create a button, with background color, then a menu with background color, then a interface with background color and so on...
if it lather creates over complex syntax output on code we can always use snippets and leave our code unrepeated or with no repetitions.
Character P.Object
Lets say we want to add a shop in C++:
get the game, standard variables:
[code]
extern char character;
extern int character_id;
extern char character_name[2];
extern int character_age;
extern char character_gender;
extern char character_title;
extern char character_image;
extern int character_3d_model;
extern int character_inventory;
extern int character_items[100]; //link
extern int character_spells[100]; //link
extern int character_abilitys[100]; //link
extern int character_status;
char character_race;
char character_type; // Npc, player
int character_inventory_size;
char character_background; // History
char character_family; // History
char character_language;
char character_language_list = {"common", "orcish"};
int character_health;
int character_max_health;
int character_mana;
int character_max_mana;
int character_stamina;
int character_max_stamina;
int character_damage[2]; // min, max
int character_level;
int character_level_value;
float character_level_up = 0.3;
int character_level_up =
int character_level_ = 0.2;
int character_xp;
int character_xp_level_up;
int shop_id;
int shop_name;
char shop_npc;
int shop_money;
int shop_timer;
int shop_time;
char shop_items;
int shop_slots;
int shop_menus;
int item_id;
extern char items[];
int item_name;
int item_menu[100];
[/code]
How it looks in objects :
new object = shop;
new object = character;
new object = item;
shop->interface;
shop->load_items;
shop->buy;
shop->sell;
character->money;
character->status;
character->unequip;
item->effect;
game interface procedural;
A costume object in this. It alter the state of variables. Width out affecting the code. You only need the standard variables.
In next version they will be in just one file for better readability.
To store in this case you may need the costume storage or save, or you can build yours.
in this case, character_array_index; It have the "register" or "matrix" for the save. It will also be global.
is not that hard. Main is a bit confusing, but it is suppose to be like MVC, you load stuff in to it. You can even have a file
width this objects, and load/#include the file. It to your zone or city to buy.
Study? Not that much, since main is modular, you can use it, width out any more code.
Thursday, February 29, 2024
Pseudo Object on SQL Built in a stack library
SQL_connection = db_conection;
SQL_db = the box;
SQL_rows = user_name, user_id;
SQL_ext = mysql;
SQL_command = select;
SQL_amount = *;
SQL_result ;
SQL_rows_join = user_apps;
if (SQL_query())
{
}
else if (ut_sql())
{
}
else if
help_info_sql(){
}
If the SQL query fails it runs the unit test, also adding a new step to unit tests (the help info), depending on the error's that the unit test detects we get help information. Lets say this example : that unit test detects a invalid row, it says one or more rows invalid, but that does not fix the error. so the help info will get information based on the error for us. Instead or prevent us from going to the db to check it. we get the rows that are there associated width the call. so that we can see directly in the code where is the error.
This is possible because we fragmented the code or command in to parts.
let see how it evolve... Think all code and our knowledge is evolving.
hi
How its going
The pic is from the links editor adopted the simple interface of pop-ups to be easier, lather will hurry on the details. First versions of...
-
Personal tastes All come down to personal preferences, we can't control all things. This style works, it have it's positive and ne...
-
Sorry for the delay on news but think any one can understand the current world events. For a long time i was not able to work on the project...
-
Updates: Chaged the posts on tutorials and debate on what language to use on it's own forum this one will only be focus on posts releva...