Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion engine/player/player.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -12611,7 +12611,7 @@ std::unique_ptr<expr_t> player_t::create_expression( util::string_view expressio
// pet
if ( splits.size() >= 2 && splits[ 0 ] == "pet" )
{
if ( splits[ 1 ] == "any" && splits[ 2 ] == "active" )
if ( splits.size() == 3 && splits[ 1 ] == "any" && splits[ 2 ] == "active" )
{
return make_fn_expr( expression_str, [ this ]
{
Expand Down
2 changes: 1 addition & 1 deletion engine/sim/sim.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3609,7 +3609,7 @@ std::unique_ptr<expr_t> sim_t::create_expression( util::string_view name_str )
if ( splits.size() >= 3 && splits[ 0 ] == "actors" )
{
player_t* actor = sim_t::find_player( splits[ 1 ] );
if ( !target )
if ( !actor )
return nullptr;

auto rest = std::string( splits[ 2 ] );
Expand Down
Loading