<?xml version="1.0" encoding="ISO-8859-1" ?>
<Game>
    <GDVersion Major="2" Minor="1" Build="10682" Revision="53886" />
    <Info winExecutableFilename="" winExecutableIconFile="" linuxExecutableFilename="" macExecutableFilename="" useExternalSourceFiles="false">
        <Nom value="Save and load" />
        <Auteur value="" />
        <WindowW value="800" />
        <WindowH value="600" />
        <Portable value="true" />
        <Extensions>
            <Extension name="BuiltinObject" />
            <Extension name="BuiltinAudio" />
            <Extension name="BuiltinVariables" />
            <Extension name="BuiltinTime" />
            <Extension name="BuiltinMouse" />
            <Extension name="BuiltinKeyboard" />
            <Extension name="BuiltinJoystick" />
            <Extension name="BuiltinCamera" />
            <Extension name="BuiltinWindow" />
            <Extension name="BuiltinFile" />
            <Extension name="BuiltinNetwork" />
            <Extension name="BuiltinScene" />
            <Extension name="BuiltinAdvanced" />
            <Extension name="Sprite" />
            <Extension name="BuiltinCommonInstructions" />
            <Extension name="BuiltinCommonConversions" />
            <Extension name="BuiltinStringInstructions" />
            <Extension name="BuiltinMathematicalTools" />
            <Extension name="TextObject" />
            <Extension name="CommonDialogs" />
        </Extensions>
        <FPSmax value="60" />
        <FPSmin value="10" />
        <verticalSync value="false" />
        <Chargement>
            <Afficher value="true" />
            <Border value="true" />
            <Smooth value="true" />
            <Width value="170.000000" />
            <Height value="50.000000" />
            <TexteAfficher value="true" />
            <TexteXPos value="0.000000" />
            <TexteYPos value="0.000000" />
            <Texte value="Chargement" />
            <PourcentAfficher value="false" />
            <PourcentXPos value="0.000000" />
            <PourcentYPos value="0.000000" />
            <ImageAfficher value="false" />
            <Image value="" />
        </Chargement>
    </Info>
    <Resources>
        <Resources>
            <Resource kind="image" name="Block-Normal.png" alwaysLoaded="false" smoothed="true" userAdded="true" file="Block-Normal.png" />
        </Resources>
        <ResourceFolders />
    </Resources>
    <Objects />
    <ObjectGroups />
    <Variables />
    <Scenes>
        <Scene nom="Nouvelle scène 1" r="94.000000" v="174.000000" b="255.000000" titre="" oglFOV="90.000000" oglZNear="1.000000" oglZFar="500.000000" standardSortMethod="true" stopSoundsOnStartup="true" gridWidth="32.000000" grid="false" snap="false" gridHeight="32.000000" gridR="158.000000" gridG="180.000000" gridB="255.000000" windowMask="true">
            <GroupesObjets />
            <Objets>
                <Objet nom="Bloc" type="Sprite">
                    <Variables />
                    <Animations>
                        <Animation typeNormal="true">
                            <Direction boucle="false" tempsEntre="1.000000">
                                <Sprites>
                                    <Sprite image="Block-Normal.png">
                                        <Points />
                                        <PointOrigine nom="origine" X="0.000000" Y="0.000000" />
                                        <PointCentre nom="centre" X="35.000000" Y="30.000000" automatic="true" />
                                        <CustomCollisionMask custom="false" />
                                    </Sprite>
                                </Sprites>
                            </Direction>
                        </Animation>
                    </Animations>
                </Objet>
                <Objet nom="ExplanationFR" type="TextObject::Text" smoothed="true">
                    <Variables />
                    <String value="Appuyez sur S pour sauvegarder&#x0A;Appuyez sur L pour charger&#x0A;Appuyez sur A pour ajouter un bloc&#x0A;Appuyez sur D pour le supprimer" />
                    <Font value="" />
                    <CharacterSize value="15" />
                    <Color r="255" g="255" b="255" />
                    <Style value="0" />
                </Objet>
                <Objet nom="Explanation" type="TextObject::Text" smoothed="true">
                    <Variables />
                    <String value="Press S to save&#x0A;Press L to load&#x0A;Press A to add a block&#x0A;Press D to delete a block" />
                    <Font value="" />
                    <CharacterSize value="15" />
                    <Color r="255" g="255" b="255" />
                    <Style value="0" />
                </Objet>
            </Objets>
            <Layers>
                <Layer Name="" Visibility="true">
                    <Camera DefaultSize="true" Width="0.000000" Height="0.000000" DefaultViewport="true" ViewportLeft="0.000000" ViewportTop="0.000000" ViewportRight="1.000000" ViewportBottom="1.000000" />
                </Layer>
            </Layers>
            <Variables>
                <Variable Name="Etat" Value="" />
            </Variables>
            <AutomatismsSharedDatas />
            <Dependencies />
            <Positions>
                <Objet nom="ExplanationFR" x="572.000000" y="5.000000" plan="0" layer="" angle="0.000000" personalizedSize="false" width="0.000000" height="0.000000">
                    <floatInfos />
                    <stringInfos />
                    <InitialVariables />
                </Objet>
                <Objet nom="Explanation" x="298.000000" y="5.000000" plan="0" layer="" angle="0.000000" personalizedSize="false" width="0.000000" height="0.000000">
                    <floatInfos />
                    <stringInfos />
                    <InitialVariables />
                </Objet>
            </Positions>
            <Events>
                <Event disabled="false" folded="false">
                    <Type value="BuiltinCommonInstructions::Comment" />
                    <Couleur r="255.000000" v="230.000000" b="109.000000" textR="0.000000" textG="0.000000" textB="0.000000" />
                    <Com1 value="Adding a block" />
                    <Com2 value="Ajout d&apos;un bloc" />
                </Event>
                <Event disabled="false" folded="false">
                    <Type value="BuiltinCommonInstructions::Standard" />
                    <Conditions>
                        <Condition>
                            <Type value="KeyPressed" loc="true" Contraire="false" />
                            <Parametre value="" />
                            <Parametre value="a" />
                        </Condition>
                        <Condition>
                            <Type value="Timer" loc="true" Contraire="false" />
                            <Parametre value="" />
                            <Parametre value="0.25" />
                            <Parametre value='&quot;Insertion&quot;' />
                        </Condition>
                    </Conditions>
                    <Actions>
                        <Action>
                            <Type value="Create" loc="true" />
                            <Parametre value="" />
                            <Parametre value="" />
                            <Parametre value="" />
                            <Parametre value="Bloc" />
                            <Parametre value="MouseX()" />
                            <Parametre value="MouseY()" />
                        </Action>
                        <Action>
                            <Type value="ResetTimer" loc="true" />
                            <Parametre value="" />
                            <Parametre value='&quot;Insertion&quot;' />
                        </Action>
                    </Actions>
                </Event>
                <Event disabled="false" folded="false">
                    <Type value="BuiltinCommonInstructions::Comment" />
                    <Couleur r="255.000000" v="230.000000" b="109.000000" textR="0.000000" textG="0.000000" textB="0.000000" />
                    <Com1 value="Deleting a block" />
                    <Com2 value="Suppression d&apos;un bloc" />
                </Event>
                <Event disabled="false" folded="false">
                    <Type value="BuiltinCommonInstructions::Standard" />
                    <Conditions>
                        <Condition>
                            <Type value="KeyPressed" loc="true" Contraire="false" />
                            <Parametre value="" />
                            <Parametre value="d" />
                        </Condition>
                        <Condition>
                            <Type value="SourisSurObjet" loc="true" Contraire="false" />
                            <Parametre value="Bloc" />
                            <Parametre value="" />
                            <Parametre value="" />
                        </Condition>
                    </Conditions>
                    <Actions>
                        <Action>
                            <Type value="Delete" loc="true" />
                            <Parametre value="Bloc" />
                        </Action>
                    </Actions>
                </Event>
                <Event disabled="false" folded="false">
                    <Type value="BuiltinCommonInstructions::Comment" />
                    <Couleur r="255.000000" v="230.000000" b="109.000000" textR="0.000000" textG="0.000000" textB="0.000000" />
                    <Com1 value="Start Saving or loading" />
                    <Com2 value="Lancement de la sauvegarde/chargement si besoin." />
                </Event>
                <Event disabled="false" folded="false">
                    <Type value="BuiltinCommonInstructions::Standard" />
                    <Conditions>
                        <Condition>
                            <Type value="KeyPressed" loc="true" Contraire="false" />
                            <Parametre value="" />
                            <Parametre value="s" />
                        </Condition>
                        <Condition>
                            <Type value="VarSceneTxt" loc="true" Contraire="false" />
                            <Parametre value="" />
                            <Parametre value="Etat" />
                            <Parametre value='&quot;&quot;' />
                            <Parametre value="=" />
                        </Condition>
                    </Conditions>
                    <Actions>
                        <Action>
                            <Type value="ModVarSceneTxt" loc="true" />
                            <Parametre value="" />
                            <Parametre value="Etat" />
                            <Parametre value='&quot;Save&quot;' />
                            <Parametre value="=" />
                        </Action>
                        <Action>
                            <Type value="ModVarScene" loc="true" />
                            <Parametre value="" />
                            <Parametre value="ID" />
                            <Parametre value="0" />
                            <Parametre value="=" />
                        </Action>
                        <Action>
                            <Type value="DeleteFichier" loc="true" />
                            <Parametre value='&quot;Save.txt&quot;' />
                        </Action>
                    </Actions>
                </Event>
                <Event disabled="false" folded="false">
                    <Type value="BuiltinCommonInstructions::Standard" />
                    <Conditions>
                        <Condition>
                            <Type value="KeyPressed" loc="true" Contraire="false" />
                            <Parametre value="" />
                            <Parametre value="l" />
                        </Condition>
                        <Condition>
                            <Type value="VarSceneTxt" loc="true" Contraire="false" />
                            <Parametre value="" />
                            <Parametre value="Etat" />
                            <Parametre value='&quot;&quot;' />
                            <Parametre value="=" />
                        </Condition>
                    </Conditions>
                    <Actions>
                        <Action>
                            <Type value="ModVarScene" loc="true" />
                            <Parametre value="" />
                            <Parametre value="ID" />
                            <Parametre value="0" />
                            <Parametre value="=" />
                        </Action>
                        <Action>
                            <Type value="ModVarSceneTxt" loc="true" />
                            <Parametre value="" />
                            <Parametre value="Etat" />
                            <Parametre value='&quot;Load&quot;' />
                            <Parametre value="=" />
                        </Action>
                        <Action>
                            <Type value="Delete" loc="true" />
                            <Parametre value="Bloc" />
                        </Action>
                    </Actions>
                </Event>
                <Event disabled="false" folded="false">
                    <Type value="BuiltinCommonInstructions::Comment" />
                    <Couleur r="255.000000" v="230.000000" b="109.000000" textR="0.000000" textG="0.000000" textB="0.000000" />
                    <Com1 value="Save" />
                    <Com2 value="Sauvegarde" />
                </Event>
                <Event disabled="false" folded="false">
                    <Type value="BuiltinCommonInstructions::Standard" />
                    <Conditions>
                        <Condition>
                            <Type value="VarSceneTxt" loc="true" Contraire="false" />
                            <Parametre value="" />
                            <Parametre value="Etat" />
                            <Parametre value='&quot;Save&quot;' />
                            <Parametre value="=" />
                        </Condition>
                    </Conditions>
                    <Actions />
                    <Events>
                        <Event disabled="false" folded="false">
                            <Type value="BuiltinCommonInstructions::Comment" />
                            <Couleur r="255.000000" v="230.000000" b="109.000000" textR="0.000000" textG="0.000000" textB="0.000000" />
                            <Com1 value="For each object block,&#x0A;we create an entry in the save fil" />
                            <Com2 value="On passe en revue chaque bloc.&#x0A;Et on enregistre leurs positions." />
                        </Event>
                        <Event disabled="false" folded="false">
                            <Type value="BuiltinCommonInstructions::ForEach" />
                            <Object value="Bloc" />
                            <Conditions />
                            <Actions>
                                <Action>
                                    <Type value="EcrireFichierExp" loc="true" />
                                    <Parametre value='&quot;Save.txt&quot;' />
                                    <Parametre value='&quot;Bloc&quot; + VariableString(ID) + &quot;/X&quot;' />
                                    <Parametre value="Bloc.X()" />
                                </Action>
                                <Action>
                                    <Type value="EcrireFichierExp" loc="true" />
                                    <Parametre value='&quot;Save.txt&quot;' />
                                    <Parametre value='&quot;Bloc&quot; + VariableString(ID) + &quot;/Y&quot;' />
                                    <Parametre value="Bloc.Y()" />
                                </Action>
                                <Action>
                                    <Type value="ModVarScene" loc="true" />
                                    <Parametre value="" />
                                    <Parametre value="ID" />
                                    <Parametre value="1" />
                                    <Parametre value="+" />
                                </Action>
                            </Actions>
                        </Event>
                        <Event disabled="false" folded="false">
                            <Type value="BuiltinCommonInstructions::Standard" />
                            <Conditions />
                            <Actions>
                                <Action>
                                    <Type value="ModVarSceneTxt" loc="true" />
                                    <Parametre value="" />
                                    <Parametre value="Etat" />
                                    <Parametre value="" />
                                    <Parametre value="=" />
                                </Action>
                            </Actions>
                        </Event>
                    </Events>
                </Event>
                <Event disabled="false" folded="false">
                    <Type value="BuiltinCommonInstructions::Comment" />
                    <Couleur r="255.000000" v="230.000000" b="109.000000" textR="0.000000" textG="0.000000" textB="0.000000" />
                    <Com1 value="Loading" />
                    <Com2 value="Chargement" />
                </Event>
                <Event disabled="false" folded="false">
                    <Type value="BuiltinCommonInstructions::Standard" />
                    <Conditions>
                        <Condition>
                            <Type value="VarSceneTxt" loc="true" Contraire="false" />
                            <Parametre value="" />
                            <Parametre value="Etat" />
                            <Parametre value='&quot;Load&quot;' />
                            <Parametre value="=" />
                        </Condition>
                    </Conditions>
                    <Actions />
                    <Events>
                        <Event disabled="false" folded="false">
                            <Type value="BuiltinCommonInstructions::Comment" />
                            <Couleur r="255.000000" v="230.000000" b="109.000000" textR="0.000000" textG="0.000000" textB="0.000000" />
                            <Com1 value="While there is a block in the file,&#x0A;create a new one at the specified position" />
                            <Com2 value="Tant qu&apos;on peut charger un bloc.&#x0A;On le créé à la position relevée." />
                        </Event>
                        <Event disabled="false" folded="false">
                            <Type value="BuiltinCommonInstructions::While" />
                            <WhileConditions>
                                <Condition>
                                    <Type value="GroupExists" loc="true" Contraire="false" />
                                    <Parametre value='&quot;Save.txt&quot;' />
                                    <Parametre value='&quot;Bloc&quot; + VariableString(ID) + &quot;/X&quot;' />
                                </Condition>
                            </WhileConditions>
                            <Conditions />
                            <Actions>
                                <Action>
                                    <Type value="LireFichierExp" loc="true" />
                                    <Parametre value='&quot;Save.txt&quot;' />
                                    <Parametre value='&quot;Bloc&quot; + VariableString(ID) + &quot;/X&quot;' />
                                    <Parametre value="" />
                                    <Parametre value="NewBlocX" />
                                </Action>
                                <Action>
                                    <Type value="LireFichierExp" loc="true" />
                                    <Parametre value='&quot;Save.txt&quot;' />
                                    <Parametre value='&quot;Bloc&quot; + VariableString(ID) + &quot;/Y&quot;' />
                                    <Parametre value="" />
                                    <Parametre value="NewBlocY" />
                                </Action>
                                <Action>
                                    <Type value="Create" loc="true" />
                                    <Parametre value="" />
                                    <Parametre value="" />
                                    <Parametre value="" />
                                    <Parametre value="Bloc" />
                                    <Parametre value="Variable(NewBlocX)" />
                                    <Parametre value="Variable(NewBlocY)" />
                                </Action>
                                <Action>
                                    <Type value="ModVarScene" loc="true" />
                                    <Parametre value="" />
                                    <Parametre value="ID" />
                                    <Parametre value="1" />
                                    <Parametre value="+" />
                                </Action>
                            </Actions>
                        </Event>
                        <Event disabled="false" folded="false">
                            <Type value="BuiltinCommonInstructions::Standard" />
                            <Conditions />
                            <Actions>
                                <Action>
                                    <Type value="ModVarSceneTxt" loc="true" />
                                    <Parametre value="" />
                                    <Parametre value="Etat" />
                                    <Parametre value="" />
                                    <Parametre value="=" />
                                </Action>
                            </Actions>
                        </Event>
                    </Events>
                </Event>
            </Events>
        </Scene>
    </Scenes>
    <ExternalEvents />
    <ExternalSourceFiles />
</Game>
