mirror of
https://github.com/openshwprojects/OpenBK7231T_App.git
synced 2026-03-19 05:38:16 +01:00
sim: add ability to add prefabs. Also added cmd comment
This commit is contained in:
@@ -248,6 +248,15 @@ bool CSimulator::createSimulation(bool bDemo) {
|
||||
|
||||
return false;
|
||||
}
|
||||
bool CSimulator::beginAddingPrefab(const char *s) {
|
||||
CShape *newShape = prefabs->instantiatePrefab(s);
|
||||
if (newShape == 0) {
|
||||
return true;
|
||||
}
|
||||
newShape->setPosition(80, 80);
|
||||
sim->addObject(newShape);
|
||||
return false;
|
||||
}
|
||||
bool CSimulator::loadSimulation(const char *s) {
|
||||
CString fixed;
|
||||
if (FS_Exists(s) == false) {
|
||||
|
||||
Reference in New Issue
Block a user