d/jak2: second documentation PR and finish forest-scenes and palace-scenes (#2136)

Also fixes #2135

Co-authored-by: water <awaterford111445@gmail.com>
This commit is contained in:
Tyler Wilding
2023-01-21 20:26:51 -05:00
committed by GitHub
parent 7ac22e8449
commit e5d6ac1c41
188 changed files with 11964 additions and 6538 deletions
+1 -1
View File
@@ -200,7 +200,7 @@ Form* try_cast_simplify(Form* in,
auto g = dynamic_cast<GenericElement*>(in->try_as_single_element());
if (g && g->op().kind() == GenericOperator::Kind::FUNCTION_EXPR) {
auto f = dynamic_cast<SimpleExpressionElement*>(g->op().func()->try_as_single_element());
if (f->expr().is_identity() && f->expr().get_arg(0).is_sym_val()) {
if (f && f->expr().is_identity() && f->expr().get_arg(0).is_sym_val()) {
auto& func_name = f->expr().get_arg(0).get_str();
if (func_name == "rand-vu-int-range" || func_name == "nav-enemy-rnd-int-range") {
std::vector<Form*> new_forms;