Skip to content

grandstack/Pronto

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Pronto

auto main() -> int
{
	using person = pronto::entity<food, hunger, human>;
	using bulldog = pronto::entity<food, hunger, dog>;

	// Synchronization for concurrent read and write attempts ...
	pronto::synchronize<person, bulldog>([]
	{
		auto people = pronto::create<person>(1000);
		auto bulldogs = pronto::create<bulldog>(1000);

		pronto::process(people, [&](person & p, food & f) {
			std::cout << "entity id: " << p << std::endl;

			pronto::process(bulldogs, [&](hunger & h) {
				h.eat(f)
			});
		});

		pronto::destroy(bulldogs);
		pronto::destroy(people);
	});
}

About

Entity System

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages