瀏覽代碼

Added to check for Sveta being homeless.

netuttki 2 月之前
父節點
當前提交
aeff8607ff
共有 1 個文件被更改,包括 3 次插入2 次删除
  1. 3 2
      locations/homes_properties.qsrc

+ 3 - 2
locations/homes_properties.qsrc

@@ -864,7 +864,7 @@ if $ARGS[0] = 'tenants_move_in':
 	gs 'homes_properties', 'set_access', $ARGS[1], TENANTS
 	accessible_property['<<$ARGS[1]>>-tenant-day'] = ARGS[2]
 	accessible_property['<<$ARGS[1]>>-tenant-month'] = ARGS[3]
-	if $home['current'] = '' and accessible_property['accessible_home_count'] = 1:
+	if ($home['current'] = '' or dyneval($is_homeless)) and accessible_property['accessible_home_count'] = 1:
 		gs 'homes_properties', 'get_accessible_properties', 'home'
 		if accessible_property['<<$property_code>>-is-home']: gs 'homes_properties', 'set_home', $property_code
 		gs 'homes_properties', 'clean_up_property_data'
@@ -905,7 +905,8 @@ if $ARGS[0] = 'tenant_move_out_check':
 			killvar 'property'
 		if hp_i < count: jump 'tenantloop'
 	end
-	if accessible_property['accessible_home_count'] = 1 and $home['current'] = '':
+
+	if accessible_property['accessible_home_count'] = 1 and ($home['current'] = '' or dyneval($is_homeless)):
 		gs 'homes_properties', 'get_accessible_properties', 'home'
 		if accessible_property['<<$property_code>>-is-home'] = 1: gs 'homes_properties', 'set_home', $property_code
 		gs 'homes_properties', 'clean_up_property_data'