Commit Graph

83 Commits

Author SHA1 Message Date
IceTrooper
47286f40a9
Creating new atom in current directory improvement (#184)
* small improvement for creating new atoms in inspector window

* fixed getting directory path instead of full file path
2020-08-04 01:09:52 +02:00
Adam Ramberg
0540add7b8 #179 - Fixes to AtomDrawer + FSM editor 2020-08-04 00:59:22 +02:00
Gustavo Guimaraes
cd8cd63ec0
Default Value For Changed and ChangedWithHistory (#179)
* Changed now is created even if null

* Added changedwithhistory

* Removed initial implementation
2020-08-04 00:55:26 +02:00
jmacgill
3140feab42
Generator creates compilable code with type specific modifications (#169)
* Make Examples path check OS agnostic.

* Examples path check OS agnostic.

* Update Runtime.cs

* Re-generate and patch back in type specific changes

* Add missing UnityEngine using.

* Marked as not sealed

* Support the current value type as a conditional.

* Nested if blocks

* Use next char instead of next linefeed.

* Remove debug lines.

* Keep Atom Base Variable sepecfic code.

* Fix position of endif

* Add Raise for void type

* Add void and FSM specific logic

* Add is numeric conditional

* Add more type specific logic

* Add is Vector to generator.

* Add type specific logic

* Add collider type

* Add color specific logic

* Working on whitespace diffs

* Working on whitespace diffs

* remove unused test assembly

* removed example nested if

* test comment removed after regen

* missing ValueEquals

* missing ValueEquals on colliders

* missing color speciifc code.

* whitesapce cleanup

* whitesapce cleanup

* whitesapce cleanup

* whitesapce cleanup

* whitesapce cleanup

* whitesapce cleanup

* remove temp debug

* Generated events now follows editoconfig. + Inline conditionals now supports white spaces.

Co-authored-by: jrmacgill <jmacgill@gmail.com>
Co-authored-by: Adam Ramberg <adam@mambojambostudios.com>
2020-07-12 08:18:51 +02:00
Gustavo Guimaraes
1e2ea61044
Instancer improvements (#172)
* Added Raise method and default base event for event instancers

* Added default value for Variable when base is null

* Added Event Instancer Raise editor
2020-07-01 08:32:07 +02:00
Oliver Biwer
3ae6200b8a
Update AtomBaseReferenceDrawer.cs (#174)
* Update AtomBaseReferenceDrawer.cs

* Update AtomBaseReferenceDrawer.cs
2020-07-01 08:23:41 +02:00
Adam Ramberg
46a526c666 - Fixed clear button handler for StackTraces
- Fixed and rearranged StackTraces compiler flags
2020-06-22 09:13:20 +02:00
Adam Ramberg
e3ed5b58fc Hacks to get docs generator working 2020-06-20 09:32:51 +02:00
Adam Ramberg
4278f71c9e #164 - Does not work in Unity 2018.3 2020-06-20 00:49:40 +02:00
Adam Ramberg
70f8130797
Debug events by displaying stack traces for events (#159)
* Add stack trace toggled via user prefs

* Add docs regarding preferences

* Rename color getter functions

* Fix minior order of execution bug

* Use GUID + improved styling of detailed stack view

* - Changed the AddStackTrace method to be conditional (from one of your initial suggestions).
- Removed the implicit conversion operator in StackTraceEntry and is instead using ToString explicitly when needed.
- Improved implementation of GetFirstLine
- Simplified Equals implementation of the StackTraceEntry class
2020-06-06 22:19:07 +02:00
AdamRamberg
27959b9dd4 Fix bug where usage popup sometimes were hidden 2020-05-16 17:30:26 +02:00
Bastien Guyl
4aa1f4a4d7
Fixing drawer for generated reference of complex struct type (#155)
* Adding proposals to fix #153

FIx custom reference doesn't appear properly

* Fix #153

Fix custom reference doesn't appear properly

* Fix #153

Fix custom reference doesn't appear properly

Co-authored-by: Bastien Guyl <bguyl@smart-tale.com>
2020-05-11 20:07:56 +02:00
AdamRamberg
849ae95b58 Add GetParent / GetValue extenstions for SerializedProperty 2020-05-10 16:27:46 +02:00
Adam Ramberg
5dfc5fef7c
Fix code generation bug (#147) 2020-05-03 23:12:37 +02:00
Ignacio Ruiz
3666304b55
Added inspector toggle for triggering Changed and ChangedWithHistory on OnEnable (#126)
* Booleans to decide if OnChanged Events are triggered on Variable's OnEnable were added

* Variable's editor was updated to show both booleans

* Docs updated with new variables

* Changelog update

* Change variable visibility to private and add explicit default value

Co-authored-by: Ignacio Ruiz <iruizm@hiberus.com>
2020-04-26 19:57:55 +02:00
Adam Ramberg
55d96c2250
#122 Add Event Refs for Collections and Lists (#123) 2020-04-03 15:45:08 +02:00
Adam Ramberg
4ba6beee59 Added some more docs 2020-03-21 22:45:39 +01:00
Adam Ramberg
4ad596dcd2 Rename functions correctly 2020-03-21 22:17:59 +01:00
Adam Ramberg
9fd64a12f3 Move AtomListAttribute to core 2020-03-21 21:58:41 +01:00
Adam Ramberg
698c18dbe7 Fix Variable with class type issues 2020-03-20 00:48:23 +01:00
Adam Ramberg
4b2f83e830 Rearranging scenes 2020-03-19 22:29:42 +01:00
Adam Ramberg
cacb2d1594 Correctly generate comments 2020-03-19 08:41:44 +01:00
Adam Ramberg
fdfcf03150 Remove sync functionality in variable instancers 2020-03-19 08:39:43 +01:00
Adam Ramberg
20db73a43f Move sync variable instancer to collection to its own MB 2020-03-19 08:20:15 +01:00
Adam Ramberg
74bfaf7086 Example WIP + Variable ID 2020-03-18 00:17:33 +01:00
Adam Ramberg
e6ac211e70 WIP 2020-03-12 01:30:25 +01:00
Adam Ramberg
17fd35a23d Clean up WIP 2020-03-09 00:37:52 +01:00
Adam Ramberg
5d6e94af63 WIP 2020-03-09 00:16:40 +01:00
Adam Ramberg
ba583f8995 WIP FSM 2020-03-08 13:24:46 +01:00
Adam Ramberg
cb3486ae7f Align base event reference listener 2020-03-08 12:51:22 +01:00
Adam Ramberg
769388c6e4 FSM pkg + Example WIP 2020-03-08 12:32:41 +01:00
Adam Ramberg
05d3549dce Re add accidently deleted stuff 2020-03-05 00:56:56 +01:00
Adam Ramberg
06d89697f3 Example WIP 2020-03-05 00:48:39 +01:00
Adam Ramberg
b4b8ad0c09 Remove white spaces in Variable Instancers 2020-03-02 19:57:51 +01:00
Adam Ramberg
44c2413c56 Fix intro scene 2020-03-02 19:36:52 +01:00
Adam Ramberg
6f78cab386 Update docs + remove ds store 2020-03-02 18:42:19 +01:00
Adam Ramberg
c3bc59259f More WIP 2020-03-02 02:26:06 +01:00
Adam Ramberg
5d9f8dca71 WIP 2020-03-01 21:32:52 +01:00
Adam Ramberg
85f72abf8a Add AddComponentMenu to Variable Instancers 2020-02-23 23:13:30 +01:00
Adam Ramberg
6309943385
Replay subject (#114)
* Add constructor with value to Reference classes

* Implemented ReplayBehaviour for AtomEvents
2020-02-23 21:44:04 +01:00
Adam Ramberg
7c4f92ecd8
Add constructor with value to Reference classes (#113) 2020-02-23 03:17:05 +01:00
Adam Ramberg
d045434eff Fix ValueEquals in AtomVariable template 2020-02-23 02:49:58 +01:00
Adam Ramberg
8a6b8a97a6
Added Variable Instancer, Event Reference, Atom Collection and Atom List (old Atom List renamed to Atom Value List) (#110)
AtomVariableInstancer
- Added AtomVariableInstancer as an option to AtomReference.
- Added AtomVariableInstancer to generator.
- Added editor icon for AtomVariableInstancer.

AtomEventReference
- Added an AtomEventReference class (and AtomEventX2Reference). It’s similar to an AtomReference, but for Events. Let’s you pick between an Event, Variable (will select the Changed event) and a VariableInstancer (see above).
- Added AtomEventReference and AtomEventX2Reference to generator.
- Added a drawer for AtomEventReference.
- Listeners are now using AtomEventReference instead of AtomEvent.
- Refactoring of VoidHooks since Listeners are now using AtomEventReference.

AtomCollection
- Created an AtomCollection - a collection of Atoms associated with key strings (AtomReferences).
- Added new editor icon for collections.
- Created a SerializableDictionary class, which AtomCollection is using.
- Custom property drawer for SerializableDictionary.
- SerializableDictionary supports nested structures meaning that a AtomCollection can have a KVP that is pointing to another AtomCollection.
- AtomCollections have 3 events: Added, Removed, Cleared.
- Added an option to sync an InstanceVariable to collection - adding it to the collection when created (using gameObject’s instance id as key) and removing it from the collection when destroyed.

AtomList
- Renamed old AtomList to AtomValueList
- Added AtomList, like Collection, but a list
- Added new icon for AtomList
- Created a AtomBaseVariableList class, which AtomList is using.
- Custom property drawer for AtomBaseVariableList.
- AtomLists have 3 events: Added, Removed, Cleared.
- Added an option to sync an InstanceVariable to list - adding it to the list when created and removing it from the list when destroyed.
2020-02-23 02:39:43 +01:00
Low Jiahao
9a9b72f052
Reactivate Generator function in Unity 2018.4. (#106)
Co-authored-by: Adam Ramberg <adam@mambojambostudios.com>
2020-02-19 01:25:30 +01:00
Adam Ramberg
ed856beb11
Fix indentation bug in variable drawer (#109) 2020-02-18 22:20:29 +01:00
Adam Ramberg
630d45bceb
IsUnityAtomsRepo should never be settable (#108) 2020-02-16 21:10:45 +01:00
Adam Ramberg
9b027e2308
Added pre change transformers to Variables + Clamp Int / Float (#93)
* Added pre change transformers to Variable + Clamp Value Function (first pre change transformer implementation)
- Added a list of pre change transformers to AtomVariable
- Added docs
- Added two AtomFunctions - ClampInt and ClampFloat
- Added custom editors for ClampInt and ClampFloat
- AtomFunction<T, T> is not part of the generator
- Regenerated all the Atoms

* - Created a base class for the editor for ClampFloat and ClampInt. Apparently it is not allowed to have multiple CustomEditor attributes defined for the same class. To implement this I also created an interface called `IIsValid` (for casting purposes in the editor).
- Initialize `PreChangeTransformers ` at declaration and removed initialization `OnEnable`
- Moved call to `RunPreChangeTransformers ` from `OnEnable` to `OnValidate`. Running it 2 times, once for initialValue and once for value since value can be changed at runtime via editor.
- Made the variable PreChangeTransformers private and created a property instead in order to make it impossible to overwrite the list with `null` from the outside.
- Moved `ClampInt` and `ClampFloat` in the `CreateAssetMenu` for `Unity Atoms/Functions/Transformers`
2020-02-16 12:44:46 +01:00
Low Jiahao
d619146076 Unity v2018.4 Support (#98)
* - Fixed MonoHooks asmdef reference to Core asmdef was broken.
- Fixed dependancy issue for Package Manager.
- Removed Generator function in version 2018.4.

* Updated to include 2018.4 define directive.
2020-01-23 20:01:31 +01:00
AdamRamberg
b51de335e0 v2.1.0 🚀 2019-11-28 19:35:59 +01:00
Oliver Biwer
a5641f6514 Variable and Constant Drawers show a preview value (#89)
* Drawers of Variables and Constants show value field

* #89 Adjust preview width for Vector2 and Vector3
2019-11-14 22:46:58 +01:00