

 <?mf-xml version="1.0"?>
	<block ID="94411989391090970" Active="1" Name="Простой финансовый план, ЗА" Repeat="0.0" RepeatTimes="0" Protected="0" Enabled="1">
		<Triggers>
			<trigger>
				<BlockID>94411989391090970</BlockID>
				<Active>1</Active>
				<CondMet>0</CondMet>
				<Market>0</Market>
				<ID>94411989391090976</ID>
				<SelectionType>6</SelectionType>
				<HandicapID>0</HandicapID>
				<MarketStatus>6</MarketStatus>
				<Name>Обновление значения текущего убытка</Name>
				<RepeatTimes>0</RepeatTimes>
				<Repeat>0.0</Repeat>
				<Enabled>1</Enabled>
				<Logged>1</Logged>
				<ActionSet>
					<Action>32</Action>
					<Persistence>0</Persistence>
					<AmountChange>0</AmountChange>
					<SettleType>2</SettleType>
					<Price>current_loss</Price>
					<Amount>IF(current_loss - market_settled_pl &gt; 0.05, current_loss - market_settled_pl, 0)</Amount>
					<AdjustAmounts>0</AdjustAmounts>
					<WinLoseOption>0</WinLoseOption>
					<RemVariable>1</RemVariable>
					<GreenupType>0</GreenupType>
					<RemBets>0</RemBets>
					<UserVariable>2</UserVariable>
					<UseOptions>0</UseOptions>
					<TrailingSL>0</TrailingSL>
					<CancelOptions>
						<OptNoBet>0</OptNoBet>
						<OptPersistence>0</OptPersistence>
						<OptPersistenceValue>0</OptPersistenceValue>
						<OptAmount1>0.01</OptAmount1>
						<OptAmount2>10000000</OptAmount2>
						<OptPrice1>1.01</OptPrice1>
						<OptPrice2>1000</OptPrice2>
					</CancelOptions>
					<TriggerID>0</TriggerID>
				</ActionSet>
				<conditions>
					<tblck AndOr="1" Order="0">
						<blcks/>
						<conds/>
					</tblck>
				</conditions>
			</trigger>
			<trigger>
				<BlockID>94411989391090970</BlockID>
				<Active>1</Active>
				<CondMet>0</CondMet>
				<Market>0</Market>
				<ID>94411989391090983</ID>
				<SelectionType>6</SelectionType>
				<HandicapID>0</HandicapID>
				<MarketStatus>6</MarketStatus>
				<Name>Увеличение размера ставки</Name>
				<RepeatTimes>0</RepeatTimes>
				<Repeat>0.0</Repeat>
				<Enabled>1</Enabled>
				<Logged>1</Logged>
				<ActionSet>
					<Action>32</Action>
					<Persistence>0</Persistence>
					<AmountChange>0</AmountChange>
					<SettleType>2</SettleType>
					<Price>current_bet</Price>
					<Amount>init_bet + current_loss</Amount>
					<AdjustAmounts>0</AdjustAmounts>
					<WinLoseOption>0</WinLoseOption>
					<RemVariable>1</RemVariable>
					<GreenupType>0</GreenupType>
					<RemBets>0</RemBets>
					<UserVariable>2</UserVariable>
					<UseOptions>0</UseOptions>
					<TrailingSL>0</TrailingSL>
					<CancelOptions>
						<OptNoBet>0</OptNoBet>
						<OptPersistence>0</OptPersistence>
						<OptPersistenceValue>0</OptPersistenceValue>
						<OptAmount1>0.01</OptAmount1>
						<OptAmount2>10000000</OptAmount2>
						<OptPrice1>1.01</OptPrice1>
						<OptPrice2>1000</OptPrice2>
					</CancelOptions>
					<TriggerID>0</TriggerID>
				</ActionSet>
				<conditions>
					<tblck AndOr="1" Order="0">
						<blcks/>
						<conds>
							<condition AndOr="1" Body="1" Param="61" CondIndex="2" Value2="" Value1="max_bet" TriggerID="0" SecondParam="init_bet + current_loss" Overall="0" Order="1"/>
						</conds>
					</tblck>
				</conditions>
			</trigger>
			<trigger>
				<BlockID>94411989391090970</BlockID>
				<Active>1</Active>
				<CondMet>0</CondMet>
				<Market>0</Market>
				<ID>94411989391090971</ID>
				<SelectionType>1</SelectionType>
				<HandicapID>0</HandicapID>
				<MarketStatus>7</MarketStatus>
				<Name>Ставка ЗА</Name>
				<RepeatTimes>0</RepeatTimes>
				<Repeat>0.0</Repeat>
				<Enabled>1</Enabled>
				<Logged>1</Logged>
				<ActionSet>
					<Action>0</Action>
					<Persistence>0</Persistence>
					<AmountChange>0</AmountChange>
					<SettleType>2</SettleType>
					<Price>back_price</Price>
					<Amount>current_bet/(back_price-1)</Amount>
					<AdjustAmounts>0</AdjustAmounts>
					<WinLoseOption>0</WinLoseOption>
					<RemVariable>1</RemVariable>
					<GreenupType>0</GreenupType>
					<RemBets>0</RemBets>
					<UserVariable>0</UserVariable>
					<UseOptions>0</UseOptions>
					<TrailingSL>0</TrailingSL>
					<CancelOptions>
						<OptNoBet>0</OptNoBet>
						<OptPersistence>0</OptPersistence>
						<OptPersistenceValue>0</OptPersistenceValue>
						<OptAmount1>0.01</OptAmount1>
						<OptAmount2>10000000</OptAmount2>
						<OptPrice1>1.01</OptPrice1>
						<OptPrice2>1000</OptPrice2>
					</CancelOptions>
					<TriggerID>0</TriggerID>
				</ActionSet>
				<conditions>
					<tblck AndOr="1" Order="0">
						<blcks>
							<tblck AndOr="1" Order="2">
								<blcks/>
								<conds>
									<condition AndOr="0" Body="6" Param="70" CondIndex="0" Value2="" Value1="0" TriggerID="94411989391090971" SecondParam="" Overall="1" Order="1"/>
									<condition AndOr="0" Body="20" Param="53" CondIndex="18" Value2="" Value1="" TriggerID="0" SecondParam="" Overall="0" Order="2"/>
								</conds>
							</tblck>
						</blcks>
						<conds>
							<condition AndOr="1" Body="1" Param="0" CondIndex="2" Value2="" Value1="4" TriggerID="0" SecondParam="" Overall="0" Order="1"/>
						</conds>
					</tblck>
				</conditions>
			</trigger>
		</Triggers>
	</block>
	<constants>
		<const name="current_loss" value="0" descr="Текущий убыток" saveValue="0"/>
		<const name="max_bet" value="100" descr="Максимальный размер ставки" saveValue="0"/>
		<const name="current_bet" value="4" descr="Размер текущей ставки" saveValue="1"/>
		<const name="init_bet" value="4" descr="Initial bet size" saveValue="0"/>
	</constants>
	<annotation/>
 