diff --git a/.idea/.idea.igem-quantifly/.idea/workspace.xml b/.idea/.idea.igem-quantifly/.idea/workspace.xml index d3e8b24..6c083db 100644 --- a/.idea/.idea.igem-quantifly/.idea/workspace.xml +++ b/.idea/.idea.igem-quantifly/.idea/workspace.xml @@ -2,12 +2,7 @@ <project version="4"> <component name="ChangeListManager"> <list default="true" id="59a76139-b7c6-419c-b685-d99043abb4e4" name="Default" comment=""> - <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/.idea/vcs.xml" /> - <change type="MODIFICATION" beforePath="$PROJECT_DIR$/../../ProjectSettings/GraphicsSettings.asset" afterPath="$PROJECT_DIR$/../../ProjectSettings/GraphicsSettings.asset" /> - <change type="MODIFICATION" beforePath="$PROJECT_DIR$/../../ProjectSettings/ProjectSettings.asset" afterPath="$PROJECT_DIR$/../../ProjectSettings/ProjectSettings.asset" /> - <change type="MODIFICATION" beforePath="$PROJECT_DIR$/../../Assets/Scripts/GameController.cs" afterPath="$PROJECT_DIR$/../../Assets/Scripts/GameController.cs" /> - <change type="MODIFICATION" beforePath="$PROJECT_DIR$/../../Assets/Scripts/MapGeneration/CellularAutomaton.cs" afterPath="$PROJECT_DIR$/../../Assets/Scripts/MapGeneration/CellularAutomaton.cs" /> - <change type="MODIFICATION" beforePath="$PROJECT_DIR$/../../ProjectSettings/ProjectVersion.txt" afterPath="$PROJECT_DIR$/../../ProjectSettings/ProjectVersion.txt" /> + <change type="MODIFICATION" beforePath="$PROJECT_DIR$/.idea/workspace.xml" afterPath="$PROJECT_DIR$/.idea/workspace.xml" /> </list> <ignored path="igem-quantifly.iws" /> <ignored path=".idea/workspace.xml" /> @@ -29,79 +24,35 @@ <component name="FileEditorManager"> <splitter split-orientation="horizontal" split-proportion="0.5"> <split-first> - <leaf SIDE_TABS_SIZE_LIMIT_KEY="300"> - <file leaf-file-name="CellularAutomaton.cs" pinned="false" current-in-tab="true"> - <entry file="file://$PROJECT_DIR$/../../Assets/Scripts/MapGeneration/CellularAutomaton.cs"> - <provider selected="true" editor-type-id="text-editor"> - <state relative-caret-position="-881"> - <caret line="3" column="17" selection-start-line="3" selection-start-column="17" selection-end-line="3" selection-end-column="17" /> - <folding> - <marker date="1476631531534" expanded="true" signature="6:139" ph="..." /> - <marker date="1476631531534" expanded="true" signature="179:3168" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="221:600" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="280:325" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="380:425" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="493:594" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="636:3166" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="651:913" ph="Delegates" /> - <marker date="1476631531534" expanded="true" signature="923:1179" ph="Fields" /> - <marker date="1476631531534" expanded="true" signature="1189:1679" ph="Ctors" /> - <marker date="1476631531534" expanded="true" signature="1298:1659" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="1689:3160" ph="Methods" /> - <marker date="1476631531534" expanded="true" signature="1732:2101" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="2177:2834" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="2899:2961" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="3026:3140" ph="{...}" /> - </folding> - </state> - </provider> - </entry> - </file> - <file leaf-file-name="Cell.cs" pinned="false" current-in-tab="false"> - <entry file="file://$PROJECT_DIR$/../../Assets/Scripts/MapGeneration/Cell.cs"> + <leaf> + <file leaf-file-name="GameController.cs" pinned="false" current-in-tab="true"> + <entry file="file://$PROJECT_DIR$/../../Assets/Scripts/GameController.cs"> <provider selected="true" editor-type-id="text-editor"> - <state relative-caret-position="255"> - <caret line="17" column="8" selection-start-line="17" selection-start-column="8" selection-end-line="17" selection-end-column="8" /> + <state relative-caret-position="68"> + <caret line="4" column="0" selection-start-line="4" selection-start-column="0" selection-end-line="4" selection-end-column="0" /> <folding> - <marker date="1470048894837" expanded="true" signature="6:46" ph="..." /> - <marker date="1470048894837" expanded="true" signature="86:437" ph="{...}" /> - <marker date="1470048894837" expanded="true" signature="110:435" ph="{...}" /> - <marker date="1470048894837" expanded="true" signature="125:249" ph="Fields" /> - <marker date="1470048894837" expanded="true" signature="259:429" ph="Ctors" /> - <marker date="1470048894837" expanded="true" signature="322:409" ph="{...}" /> + <marker date="1476654271367" expanded="true" signature="6:97" ph="..." /> + <marker date="1476654271367" expanded="true" signature="122:1273" ph="{...}" /> + <marker date="1476654271367" expanded="true" signature="155:542" ph="{...}" /> + <marker date="1476654271367" expanded="true" signature="262:536" ph="{...}" /> + <marker date="1476654271367" expanded="true" signature="591:1271" ph="{...}" /> + <marker date="1476654271367" expanded="true" signature="859:1198" ph="{...}" /> + <marker date="1476654271367" expanded="true" signature="1221:1265" ph="{...}" /> </folding> </state> </provider> </entry> </file> - <file leaf-file-name="Map.cs" pinned="false" current-in-tab="false"> - <entry file="file://$PROJECT_DIR$/../../Assets/Scripts/Utils/Map.cs"> - <provider selected="true" editor-type-id="text-editor"> - <state relative-caret-position="0"> - <caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" /> - <folding /> - </state> - </provider> - </entry> - </file> </leaf> </split-first> <split-second> - <leaf SIDE_TABS_SIZE_LIMIT_KEY="300"> - <file leaf-file-name="GameController.cs" pinned="false" current-in-tab="true"> - <entry file="file://$PROJECT_DIR$/../../Assets/Scripts/GameController.cs"> + <leaf> + <file leaf-file-name="NewBehaviourScript.cs" pinned="false" current-in-tab="true"> + <entry file="file://$PROJECT_DIR$/../../Assets/Scripts/NewBehaviourScript.cs"> <provider selected="true" editor-type-id="text-editor"> - <state relative-caret-position="405"> - <caret line="27" column="8" selection-start-line="27" selection-start-column="8" selection-end-line="27" selection-end-column="8" /> - <folding> - <marker date="1476634864569" expanded="true" signature="6:96" ph="..." /> - <marker date="1476634864569" expanded="true" signature="122:1273" ph="{...}" /> - <marker date="1476634864569" expanded="true" signature="155:542" ph="{...}" /> - <marker date="1476634864569" expanded="true" signature="262:536" ph="{...}" /> - <marker date="1476634864569" expanded="true" signature="591:1271" ph="{...}" /> - <marker date="1476634864569" expanded="true" signature="859:1198" ph="{...}" /> - <marker date="1476634864569" expanded="true" signature="1221:1265" ph="{...}" /> - </folding> + <state relative-caret-position="255"> + <caret line="15" column="0" selection-start-line="15" selection-start-column="0" selection-end-line="15" selection-end-column="0" /> + <folding /> </state> </provider> </entry> @@ -124,9 +75,10 @@ </option> </component> <component name="ProjectFrameBounds"> - <option name="y" value="27" /> - <option name="width" value="1920" /> - <option name="height" value="1053" /> + <option name="x" value="-8" /> + <option name="y" value="-8" /> + <option name="width" value="1936" /> + <option name="height" value="1056" /> </component> <component name="ProjectLevelVcsManager" settingsEditedManually="true"> <OptionsSetting value="true" id="Add" /> @@ -199,32 +151,6 @@ <option name="myItemType" value="com.jetbrains.resharper.projectView.solutionExplorer.SolutionExplorerNodeRider" /> </PATH_ELEMENT> <PATH_ELEMENT> - <option name="myItemId" value="Utils" /> - <option name="myItemType" value="com.jetbrains.resharper.projectView.solutionExplorer.SolutionExplorerNodeRider" /> - </PATH_ELEMENT> - </PATH> - <PATH> - <PATH_ELEMENT> - <option name="myItemId" /> - <option name="myItemType" value="com.jetbrains.resharper.projectView.solutionExplorer.SolutionExplorerViewPane$ProjectViewPaneTreeStructure$createRoot$1" /> - </PATH_ELEMENT> - <PATH_ELEMENT> - <option name="myItemId" value="igem-quantifly (1 project)" /> - <option name="myItemType" value="com.jetbrains.resharper.projectView.solutionExplorer.SolutionExplorerNodeRider" /> - </PATH_ELEMENT> - <PATH_ELEMENT> - <option name="myItemId" value="Assembly-CSharp" /> - <option name="myItemType" value="com.jetbrains.resharper.projectView.solutionExplorer.SolutionExplorerNodeRider" /> - </PATH_ELEMENT> - <PATH_ELEMENT> - <option name="myItemId" value="Assets" /> - <option name="myItemType" value="com.jetbrains.resharper.projectView.solutionExplorer.SolutionExplorerNodeRider" /> - </PATH_ELEMENT> - <PATH_ELEMENT> - <option name="myItemId" value="Scripts" /> - <option name="myItemType" value="com.jetbrains.resharper.projectView.solutionExplorer.SolutionExplorerNodeRider" /> - </PATH_ELEMENT> - <PATH_ELEMENT> <option name="myItemId" value="MapGeneration" /> <option name="myItemType" value="com.jetbrains.resharper.projectView.solutionExplorer.SolutionExplorerNodeRider" /> </PATH_ELEMENT> @@ -289,11 +215,12 @@ <workItem from="1476627994724" duration="3690000" /> <workItem from="1476632678696" duration="296000" /> <workItem from="1476633454562" duration="1491000" /> + <workItem from="1476654268053" duration="92000" /> </task> <servers /> </component> <component name="TimeTrackingManager"> - <option name="totallyTimeSpent" value="6426000" /> + <option name="totallyTimeSpent" value="6518000" /> </component> <component name="TodoView"> <todo-panel id="selected-file"> @@ -305,7 +232,7 @@ </todo-panel> </component> <component name="ToolWindowManager"> - <frame x="0" y="27" width="1920" height="1053" extended-state="6" /> + <frame x="-8" y="-8" width="1936" height="1056" extended-state="6" /> <editor active="true" /> <layout> <window_info id="Change Signature" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="7" side_tool="true" content_ui="tabs" /> @@ -341,41 +268,64 @@ <component name="editorHistoryManager"> <entry file="file://$PROJECT_DIR$/../../Assets/Scripts/MapGeneration/CellularAutomaton.cs"> <provider selected="true" editor-type-id="text-editor"> - <state relative-caret-position="60"> - <caret line="4" column="20" selection-start-line="4" selection-start-column="20" selection-end-line="4" selection-end-column="20" /> + <state relative-caret-position="51"> + <caret line="3" column="17" selection-start-line="3" selection-start-column="17" selection-end-line="3" selection-end-column="17" /> + <folding /> + </state> + </provider> + </entry> + <entry file="file://$PROJECT_DIR$/../../Assets/Scripts/MapGeneration/Cell.cs"> + <provider selected="true" editor-type-id="text-editor"> + <state relative-caret-position="289"> + <caret line="17" column="8" selection-start-line="17" selection-start-column="8" selection-end-line="17" selection-end-column="8" /> + <folding /> + </state> + </provider> + </entry> + <entry file="file://$PROJECT_DIR$/../../Assets/Scripts/Utils/Map.cs"> + <provider selected="true" editor-type-id="text-editor"> + <state relative-caret-position="0"> + <caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" /> + <folding /> + </state> + </provider> + </entry> + <entry file="file://$PROJECT_DIR$/../../Assets/Scripts/GameController.cs"> + <provider selected="true" editor-type-id="text-editor"> + <state relative-caret-position="459"> + <caret line="27" column="0" selection-start-line="27" selection-start-column="0" selection-end-line="27" selection-end-column="0" /> <folding> - <marker date="1476631531534" expanded="true" signature="6:139" ph="..." /> - <marker date="1476631531534" expanded="true" signature="179:3168" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="221:600" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="280:325" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="380:425" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="493:594" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="636:3166" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="651:913" ph="Delegates" /> - <marker date="1476631531534" expanded="true" signature="923:1179" ph="Fields" /> - <marker date="1476631531534" expanded="true" signature="1189:1679" ph="Ctors" /> - <marker date="1476631531534" expanded="true" signature="1298:1659" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="1689:3160" ph="Methods" /> - <marker date="1476631531534" expanded="true" signature="1732:2101" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="2177:2834" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="2899:2961" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="3026:3140" ph="{...}" /> + <marker date="1476654271367" expanded="true" signature="6:97" ph="..." /> + <marker date="1476654271367" expanded="true" signature="122:1273" ph="{...}" /> + <marker date="1476654271367" expanded="true" signature="155:542" ph="{...}" /> + <marker date="1476654271367" expanded="true" signature="262:536" ph="{...}" /> + <marker date="1476654271367" expanded="true" signature="591:1271" ph="{...}" /> + <marker date="1476654271367" expanded="true" signature="859:1198" ph="{...}" /> + <marker date="1476654271367" expanded="true" signature="1221:1265" ph="{...}" /> </folding> </state> </provider> </entry> + <entry file="file://$PROJECT_DIR$/../../Assets/Scripts/MapGeneration/CellularAutomaton.cs"> + <provider selected="true" editor-type-id="text-editor"> + <state relative-caret-position="60"> + <caret line="4" column="20" selection-start-line="4" selection-start-column="20" selection-end-line="4" selection-end-column="20" /> + <folding /> + </state> + </provider> + </entry> <entry file="file://$PROJECT_DIR$/../../Assets/Scripts/GameController.cs"> <provider selected="true" editor-type-id="text-editor"> <state relative-caret-position="0"> <caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" /> <folding> - <marker date="1476634864569" expanded="true" signature="6:96" ph="..." /> - <marker date="1476634864569" expanded="true" signature="122:1273" ph="{...}" /> - <marker date="1476634864569" expanded="true" signature="155:542" ph="{...}" /> - <marker date="1476634864569" expanded="true" signature="262:536" ph="{...}" /> - <marker date="1476634864569" expanded="true" signature="591:1271" ph="{...}" /> - <marker date="1476634864569" expanded="true" signature="859:1198" ph="{...}" /> - <marker date="1476634864569" expanded="true" signature="1221:1265" ph="{...}" /> + <marker date="1476654271367" expanded="true" signature="6:97" ph="..." /> + <marker date="1476654271367" expanded="true" signature="122:1273" ph="{...}" /> + <marker date="1476654271367" expanded="true" signature="155:542" ph="{...}" /> + <marker date="1476654271367" expanded="true" signature="262:536" ph="{...}" /> + <marker date="1476654271367" expanded="true" signature="591:1271" ph="{...}" /> + <marker date="1476654271367" expanded="true" signature="859:1198" ph="{...}" /> + <marker date="1476654271367" expanded="true" signature="1221:1265" ph="{...}" /> </folding> </state> </provider> @@ -384,24 +334,7 @@ <provider selected="true" editor-type-id="text-editor"> <state relative-caret-position="105"> <caret line="7" column="13" selection-start-line="7" selection-start-column="13" selection-end-line="7" selection-end-column="13" /> - <folding> - <marker date="1476631531534" expanded="true" signature="6:139" ph="..." /> - <marker date="1476631531534" expanded="true" signature="179:3168" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="221:600" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="280:325" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="380:425" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="493:594" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="636:3166" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="651:913" ph="Delegates" /> - <marker date="1476631531534" expanded="true" signature="923:1179" ph="Fields" /> - <marker date="1476631531534" expanded="true" signature="1189:1679" ph="Ctors" /> - <marker date="1476631531534" expanded="true" signature="1298:1659" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="1689:3160" ph="Methods" /> - <marker date="1476631531534" expanded="true" signature="1732:2101" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="2177:2834" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="2899:2961" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="3026:3140" ph="{...}" /> - </folding> + <folding /> </state> </provider> </entry> @@ -410,13 +343,13 @@ <state relative-caret-position="0"> <caret line="0" column="28" selection-start-line="0" selection-start-column="28" selection-end-line="0" selection-end-column="28" /> <folding> - <marker date="1476634864569" expanded="true" signature="6:96" ph="..." /> - <marker date="1476634864569" expanded="true" signature="122:1273" ph="{...}" /> - <marker date="1476634864569" expanded="true" signature="155:542" ph="{...}" /> - <marker date="1476634864569" expanded="true" signature="262:536" ph="{...}" /> - <marker date="1476634864569" expanded="true" signature="591:1271" ph="{...}" /> - <marker date="1476634864569" expanded="true" signature="859:1198" ph="{...}" /> - <marker date="1476634864569" expanded="true" signature="1221:1265" ph="{...}" /> + <marker date="1476654271367" expanded="true" signature="6:97" ph="..." /> + <marker date="1476654271367" expanded="true" signature="122:1273" ph="{...}" /> + <marker date="1476654271367" expanded="true" signature="155:542" ph="{...}" /> + <marker date="1476654271367" expanded="true" signature="262:536" ph="{...}" /> + <marker date="1476654271367" expanded="true" signature="591:1271" ph="{...}" /> + <marker date="1476654271367" expanded="true" signature="859:1198" ph="{...}" /> + <marker date="1476654271367" expanded="true" signature="1221:1265" ph="{...}" /> </folding> </state> </provider> @@ -425,24 +358,7 @@ <provider selected="true" editor-type-id="text-editor"> <state relative-caret-position="1815"> <caret line="121" column="0" selection-start-line="121" selection-start-column="0" selection-end-line="121" selection-end-column="0" /> - <folding> - <marker date="1476631531534" expanded="true" signature="6:139" ph="..." /> - <marker date="1476631531534" expanded="true" signature="179:3168" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="221:600" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="280:325" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="380:425" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="493:594" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="636:3166" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="651:913" ph="Delegates" /> - <marker date="1476631531534" expanded="true" signature="923:1179" ph="Fields" /> - <marker date="1476631531534" expanded="true" signature="1189:1679" ph="Ctors" /> - <marker date="1476631531534" expanded="true" signature="1298:1659" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="1689:3160" ph="Methods" /> - <marker date="1476631531534" expanded="true" signature="1732:2101" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="2177:2834" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="2899:2961" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="3026:3140" ph="{...}" /> - </folding> + <folding /> </state> </provider> </entry> @@ -453,73 +369,51 @@ </state> </provider> </entry> - <entry file="file://$USER_HOME$/.local/share/JetBrains/Shared/v07/DecompilerCache/decompiler/5A2748CB-8DB8-4A56-B1DB-8F59D9BDA51F/0d/f5d64388/GC.cs"> + <entry file="file://$USER_HOME$/.local/share/JetBrains/Shared/v07/DecompilerCache/decompiler/5A2748CB-8DB8-4A56-B1DB-8F59D9BDA51F/0d/f5d64388/GC.cs" /> + <entry file="file://$PROJECT_DIR$/../../Assets/Scripts/MapGeneration/Cell.cs"> <provider selected="true" editor-type-id="text-editor"> - <state relative-caret-position="165"> - <caret line="11" column="22" selection-start-line="11" selection-start-column="22" selection-end-line="11" selection-end-column="22" /> + <state relative-caret-position="255"> + <caret line="17" column="8" selection-start-line="17" selection-start-column="8" selection-end-line="17" selection-end-column="8" /> + <folding /> </state> </provider> </entry> - <entry file="file://$PROJECT_DIR$/../../Assets/Scripts/Utils/Map.cs"> + <entry file="file://$PROJECT_DIR$/../../Assets/Scripts/MapGeneration/CellularAutomaton.cs"> <provider selected="true" editor-type-id="text-editor"> - <state relative-caret-position="0"> - <caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" /> + <state relative-caret-position="-881"> + <caret line="3" column="17" selection-start-line="3" selection-start-column="17" selection-end-line="3" selection-end-column="17" /> <folding /> </state> </provider> </entry> - <entry file="file://$PROJECT_DIR$/../../Assets/Scripts/MapGeneration/Cell.cs"> + <entry file="file://$PROJECT_DIR$/../../Assets/Scripts/NewBehaviourScript.cs"> <provider selected="true" editor-type-id="text-editor"> <state relative-caret-position="255"> - <caret line="17" column="8" selection-start-line="17" selection-start-column="8" selection-end-line="17" selection-end-column="8" /> - <folding> - <marker date="1470048894837" expanded="true" signature="6:46" ph="..." /> - <marker date="1470048894837" expanded="true" signature="86:437" ph="{...}" /> - <marker date="1470048894837" expanded="true" signature="110:435" ph="{...}" /> - <marker date="1470048894837" expanded="true" signature="125:249" ph="Fields" /> - <marker date="1470048894837" expanded="true" signature="259:429" ph="Ctors" /> - <marker date="1470048894837" expanded="true" signature="322:409" ph="{...}" /> - </folding> + <caret line="15" column="0" selection-start-line="15" selection-start-column="0" selection-end-line="15" selection-end-column="0" /> + <folding /> </state> </provider> </entry> - <entry file="file://$PROJECT_DIR$/../../Assets/Scripts/GameController.cs"> + <entry file="file://$PROJECT_DIR$/../../Assets/Scripts/Utils/Map.cs"> <provider selected="true" editor-type-id="text-editor"> - <state relative-caret-position="405"> - <caret line="27" column="8" selection-start-line="27" selection-start-column="8" selection-end-line="27" selection-end-column="8" /> - <folding> - <marker date="1476634864569" expanded="true" signature="6:96" ph="..." /> - <marker date="1476634864569" expanded="true" signature="122:1273" ph="{...}" /> - <marker date="1476634864569" expanded="true" signature="155:542" ph="{...}" /> - <marker date="1476634864569" expanded="true" signature="262:536" ph="{...}" /> - <marker date="1476634864569" expanded="true" signature="591:1271" ph="{...}" /> - <marker date="1476634864569" expanded="true" signature="859:1198" ph="{...}" /> - <marker date="1476634864569" expanded="true" signature="1221:1265" ph="{...}" /> - </folding> + <state relative-caret-position="357"> + <caret line="21" column="0" selection-start-line="21" selection-start-column="0" selection-end-line="21" selection-end-column="0" /> + <folding /> </state> </provider> </entry> - <entry file="file://$PROJECT_DIR$/../../Assets/Scripts/MapGeneration/CellularAutomaton.cs"> + <entry file="file://$PROJECT_DIR$/../../Assets/Scripts/GameController.cs"> <provider selected="true" editor-type-id="text-editor"> - <state relative-caret-position="-881"> - <caret line="3" column="17" selection-start-line="3" selection-start-column="17" selection-end-line="3" selection-end-column="17" /> + <state relative-caret-position="68"> + <caret line="4" column="0" selection-start-line="4" selection-start-column="0" selection-end-line="4" selection-end-column="0" /> <folding> - <marker date="1476631531534" expanded="true" signature="6:139" ph="..." /> - <marker date="1476631531534" expanded="true" signature="179:3168" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="221:600" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="280:325" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="380:425" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="493:594" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="636:3166" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="651:913" ph="Delegates" /> - <marker date="1476631531534" expanded="true" signature="923:1179" ph="Fields" /> - <marker date="1476631531534" expanded="true" signature="1189:1679" ph="Ctors" /> - <marker date="1476631531534" expanded="true" signature="1298:1659" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="1689:3160" ph="Methods" /> - <marker date="1476631531534" expanded="true" signature="1732:2101" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="2177:2834" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="2899:2961" ph="{...}" /> - <marker date="1476631531534" expanded="true" signature="3026:3140" ph="{...}" /> + <marker date="1476654271367" expanded="true" signature="6:97" ph="..." /> + <marker date="1476654271367" expanded="true" signature="122:1273" ph="{...}" /> + <marker date="1476654271367" expanded="true" signature="155:542" ph="{...}" /> + <marker date="1476654271367" expanded="true" signature="262:536" ph="{...}" /> + <marker date="1476654271367" expanded="true" signature="591:1271" ph="{...}" /> + <marker date="1476654271367" expanded="true" signature="859:1198" ph="{...}" /> + <marker date="1476654271367" expanded="true" signature="1221:1265" ph="{...}" /> </folding> </state> </provider> diff --git a/Assets/Prefabs/Player.prefab.meta b/Assets/Images.meta similarity index 58% rename from Assets/Prefabs/Player.prefab.meta rename to Assets/Images.meta index 8918377..3d6fd58 100644 --- a/Assets/Prefabs/Player.prefab.meta +++ b/Assets/Images.meta @@ -1,8 +1,9 @@ fileFormatVersion: 2 -guid: a0438dee19db39d4f8e47a6a83709b0e -timeCreated: 1469997714 +guid: 0dcaa528c3d6b304987dad5504a14b70 +folderAsset: yes +timeCreated: 1475322288 licenseType: Free -NativeFormatImporter: +DefaultImporter: userData: assetBundleName: assetBundleVariant: diff --git a/Assets/Images/BG.png b/Assets/Images/BG.png new file mode 100644 index 0000000..ad440b1 Binary files /dev/null and b/Assets/Images/BG.png differ diff --git a/Assets/Images/BG.png.meta b/Assets/Images/BG.png.meta new file mode 100644 index 0000000..b2d4989 --- /dev/null +++ b/Assets/Images/BG.png.meta @@ -0,0 +1,64 @@ +fileFormatVersion: 2 +guid: b3d5feb9f4e6ba04798dbfcab5599481 +timeCreated: 1476749624 +licenseType: Free +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + linearTexture: 0 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + cubemapConvolution: 0 + cubemapConvolutionSteps: 7 + cubemapConvolutionExponent: 1.5 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 2048 + textureSettings: + filterMode: 2 + aniso: 16 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + rGBM: 0 + compressionQuality: 50 + allowsAlphaSplitting: 0 + spriteMode: 1 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 8 + buildTargetSettings: + - buildTarget: Standalone + maxTextureSize: 8192 + textureFormat: -2 + compressionQuality: 50 + allowsAlphaSplitting: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Images/BG_double.png b/Assets/Images/BG_double.png new file mode 100644 index 0000000..3381728 Binary files /dev/null and b/Assets/Images/BG_double.png differ diff --git a/Assets/Images/BG_double.png.meta b/Assets/Images/BG_double.png.meta new file mode 100644 index 0000000..ae822cb --- /dev/null +++ b/Assets/Images/BG_double.png.meta @@ -0,0 +1,64 @@ +fileFormatVersion: 2 +guid: ec51cb931534401419d3e3af7374cfdf +timeCreated: 1476749627 +licenseType: Free +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + linearTexture: 0 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + cubemapConvolution: 0 + cubemapConvolutionSteps: 7 + cubemapConvolutionExponent: 1.5 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 2048 + textureSettings: + filterMode: 2 + aniso: 16 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + rGBM: 0 + compressionQuality: 50 + allowsAlphaSplitting: 0 + spriteMode: 1 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 200 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 8 + buildTargetSettings: + - buildTarget: Standalone + maxTextureSize: 8192 + textureFormat: -3 + compressionQuality: 50 + allowsAlphaSplitting: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Images/joueur_fiole-01.png b/Assets/Images/joueur_fiole-01.png new file mode 100644 index 0000000..5db5596 Binary files /dev/null and b/Assets/Images/joueur_fiole-01.png differ diff --git a/Assets/Images/joueur_fiole-01.png.meta b/Assets/Images/joueur_fiole-01.png.meta new file mode 100644 index 0000000..a6b7e39 --- /dev/null +++ b/Assets/Images/joueur_fiole-01.png.meta @@ -0,0 +1,59 @@ +fileFormatVersion: 2 +guid: a3dc2b557aa1b724fb1d4f3e26dfbb5e +timeCreated: 1476749619 +licenseType: Free +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + linearTexture: 0 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + cubemapConvolution: 0 + cubemapConvolutionSteps: 7 + cubemapConvolutionExponent: 1.5 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 2048 + textureSettings: + filterMode: -1 + aniso: -1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + rGBM: 0 + compressionQuality: 50 + allowsAlphaSplitting: 0 + spriteMode: 1 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 8 + buildTargetSettings: [] + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Prefabs/Player.prefab b/Assets/Prefabs/Player.prefab deleted file mode 100644 index 84cafe0..0000000 Binary files a/Assets/Prefabs/Player.prefab and /dev/null differ diff --git a/Assets/Scenes/Main.unity b/Assets/Scenes/Main.unity index dc1dc9c..a29f0dd 100644 Binary files a/Assets/Scenes/Main.unity and b/Assets/Scenes/Main.unity differ diff --git a/Assets/Scripts/GameController.cs b/Assets/Scripts/GameController.cs index b2f43fb..a1ed9d2 100644 --- a/Assets/Scripts/GameController.cs +++ b/Assets/Scripts/GameController.cs @@ -11,12 +11,10 @@ namespace Assets.Scripts public static bool CanGrow(Cell cell) { - - if (cell.Position.x == 0) + if (cell.Position.y == 0) return true; - if (cell.Position.x % 10 == 0) - return (cell.Position.y < 16 && (cell.Position.y * r.Next(100)) / 100 - < 50); + if (cell.Position.x%4 == 0) + return cell.Position.y < 16 && ((100/cell.Position.y)) > 6 + r.Next(94); return false; } } @@ -25,6 +23,8 @@ namespace Assets.Scripts { public static int PoolSize = 256; + public GameObject Wall; + private Map _map; private ObjectPool _pooledWalls; @@ -33,6 +33,8 @@ namespace Assets.Scripts private CellularAutomaton _ca; + private GameObject[] _tiles; + void Start() { _map = new Map(128, 128); @@ -41,13 +43,44 @@ namespace Assets.Scripts _pooledProjectiles = new ObjectPool(PoolSize); _pooledWalls = new ObjectPool(PoolSize); - _ca = new CellularAutomaton(_map, TileType.Wall); - _ca.CanGrowRule = CADelegates.CanGrow; + _ca = new CellularAutomaton(_map, TileType.Wall) {CanGrowRule = CADelegates.CanGrow}; + _tiles = new GameObject[_map.Columns*_map.Rows]; + + for (uint i = 0 ; i < _map.Columns * _map.Rows ; i++) + { + _tiles[i] = (GameObject) Instantiate(Wall, new Vector3(0, 0, 0), Quaternion.identity); + _tiles[i].SetActive(false); + } } void Update() { - _ca.Step(); + Camera.main.transform.Translate(new Vector3(0.5f * Time.deltaTime, 0, 0)); + var rightBorder = Camera.main.ScreenToWorldPoint(new Vector3(Screen.width, + Screen.height, 0)).x; + var leftBorder = Camera.main.ScreenToWorldPoint(new Vector3(0, 0, 0)).x; + _ca.Step(rightBorder); + + DrawMap(leftBorder, rightBorder); + // Debug.Log(_map); + } + + void DrawMap(float min, float max) + { + for (uint y = 0; y < _map.Rows; y++) + { + for (uint x = (uint) min % _map.Columns; x < max + 1 % _map.Columns; x++) + { + if (_map[x, y] == TileType.Wall) + { + var tile = _tiles[_map.Columns * y + x]; + var newX = (uint) (min / _map.Columns) * _map.Columns + x; + + tile.transform.position = new Vector3(newX, y, 0); + tile.SetActive(true); + } + } + } } } } \ No newline at end of file diff --git a/Assets/Scripts/MapGeneration/Cell.cs b/Assets/Scripts/MapGeneration/Cell.cs index 4be8067..f772d8b 100644 --- a/Assets/Scripts/MapGeneration/Cell.cs +++ b/Assets/Scripts/MapGeneration/Cell.cs @@ -14,7 +14,7 @@ namespace Assets.Scripts.MapGeneration #region Ctors - public Cell(int x, int y, TileType type) + public Cell(uint x, uint y, TileType type) { Type = type; Position = new Vector2(x, y); diff --git a/Assets/Scripts/MapGeneration/CellularAutomaton.cs b/Assets/Scripts/MapGeneration/CellularAutomaton.cs index 97c274a..6a0e1a6 100644 --- a/Assets/Scripts/MapGeneration/CellularAutomaton.cs +++ b/Assets/Scripts/MapGeneration/CellularAutomaton.cs @@ -2,6 +2,7 @@ using System.Collections; using System.Collections.Generic; using System.Linq; +using System.Runtime.Remoting.Messaging; using Assets.Scripts.Utils; using UnityEngine; @@ -18,11 +19,6 @@ namespace Assets.Scripts.MapGeneration { return true; } - - public static Cell DefaultPickTarget(Map map, Cell origin) - { - return CellularAutomaton.GetNeighbors(map, origin).FirstOrDefault(); - } } public class CellularAutomaton @@ -54,39 +50,64 @@ namespace Assets.Scripts.MapGeneration #region Ctors - public CellularAutomaton(Map map, TileType targetType, int startX = 0, int startY = 0) + public CellularAutomaton(Map map, TileType targetType, uint startX = 0, uint startY = 0) { _map = map; _targetType = targetType; CanGrowRule = DefaultCellDelegates.DefaultCanGrow; WillGrowRule = DefaultCellDelegates.DefaultWillGrow; - PickTargetRule = DefaultCellDelegates.DefaultPickTarget; _toProcess = new List<Cell> {new Cell(startX, startY, targetType)}; + _map[startX, startY] = targetType; + ApplyToMap(_toProcess); } #endregion #region Methods - public void Step() + public void Step(float max) { + if (!_toProcess.Any()) + return; var newCells = new List<Cell>(); foreach (var cell in _toProcess) { - if (!CanGrowRule(cell) || !WillGrowRule(cell)) + if (!NeedToCompute(cell, max)) + { + newCells.Add(cell); continue; + } - Grow(PickTargetRule(_map, cell), _targetType); + foreach (var target in GetNeighbors(_map, cell)) + { + if (!CanGrowRule(target) || !WillGrowRule(target)) + continue; - newCells.Add(cell); - } + Grow(target, _targetType); + newCells.Add(target); + } + } + ApplyToMap(newCells); _toProcess = newCells; } + private bool NeedToCompute(Cell cell, float max) + { + return cell.Position.x < max % _map.Columns; + } + + public void ApplyToMap(List<Cell> cells) + { + foreach (var cell in cells) + { + _map[(uint) cell.Position.x, (uint) cell.Position.y] = cell.Type; + } + } + public static IEnumerable<Cell> GetNeighbors(Map map, Cell origin) { var ret = new List<Cell>(); @@ -98,7 +119,7 @@ namespace Assets.Scripts.MapGeneration if ((Math.Abs(x - origin.Position.x) > .1f || Math.Abs(y - origin.Position.y) > .1f) && IsInMapRange(map, (int) x, (int) y) && map[(uint) x, (uint) y] != origin.Type) { - ret.Add(new Cell((int) x, (int) y, map[(uint) x, (uint) y])); + ret.Add(new Cell((uint) x, (uint) y, map[(uint) x, (uint) y])); } } } diff --git a/Assets/Scripts/Utils/Map.cs b/Assets/Scripts/Utils/Map.cs index fed9c54..db8020e 100644 --- a/Assets/Scripts/Utils/Map.cs +++ b/Assets/Scripts/Utils/Map.cs @@ -43,5 +43,21 @@ get { return _map[x, y]; } set { _map[x, y] = value; } } + + public override string ToString() + { + string ret = ""; + + for (int y = 0; y < Rows; y++) + { + for (int x = 0; x < Columns; x++) + { + ret += _map[x, y] + " "; + } + ret += "\n"; + } + + return ret; + } } } \ No newline at end of file