red
New vMember
Posts: 18
|
Post by red on Apr 22, 2018 14:33:53 GMT
I have 2 questions...
1) How do I make a Magic AI Enemy use magic against me?
2) Can anyone help me fix this error when a Magic AI Enemy dies? The problem is this error causes the enemy to stay alive.
MissingReferenceException: The object of type 'MagicAISpriteHealth' has been destroyed but you are still trying to access it. Your script should either check if it is null or you should not destroy the object. Shadex.MagicAISpriteHealth.UpdateHUDListener (Shadex.CharacterBase LevelingSystem, Shadex.CharacterUpdated Stats) (at Assets/Invector-3rdPersonController/Add-ons/ShadesSpellSystem/Scripts/MagicAISpriteHealth.cs:75) Shadex.CharacterBase.ForceUpdateHUD () (at Assets/Invector-3rdPersonController/Add-ons/ShadesSpellSystem/Scripts/CharacterBase.cs:372) Shadex.CharacterBase.OnRecieveMagicDamage (Shadex.MagicObjectDamage MagicDamage, Single Damage) (at Assets/Invector-3rdPersonController/Add-ons/ShadesSpellSystem/Scripts/CharacterBase.cs:671) Shadex.CharacterBase.OnRecieveDamage (Invector.vDamage Damage) (at Assets/Invector-3rdPersonController/Add-ons/ShadesSpellSystem/Scripts/CharacterBase.cs:516) UnityEngine.Events.InvokableCall`1[Invector.vDamage].Invoke (Invector.vDamage args0) (at C:/buildslave/unity/build/Runtime/Export/UnityEvent.cs:206) UnityEngine.Events.UnityEvent`1[T0].Invoke (.T0 arg0) (at C:/buildslave/unity/build/Runtime/Export/UnityEvent_1.cs:58) Invector.vHealthController.TakeDamage (Invector.vDamage damage) (at Assets/Invector-3rdPersonController/Basic Locomotion/Scripts/Generic/vHealthController.cs:139) Invector.vCharacterController.vCharacter.TakeDamage (Invector.vDamage damage) (at Assets/Invector-3rdPersonController/Basic Locomotion/Scripts/CharacterController/vCharacter.cs:113) Invector.vCharacterController.AI.v_AIMotor.TakeDamage (Invector.vDamage damage) (at Assets/Invector-3rdPersonController/Melee Combat/Scripts/CharacterAI/v_AIMotor.cs:530) Invector.vCharacterController.AI.v_AIController.OnReceiveAttack (Invector.vDamage damage, vIMeleeFighter attacker) (at Assets/Invector-3rdPersonController/Melee Combat/Scripts/CharacterAI/v_AIController.cs:526) Invector.EventSystems.vIMeeleFighterHelper.ApplyDamage (UnityEngine.GameObject receiver, Invector.vDamage damage, vIMeleeFighter attacker) (at Assets/Invector-3rdPersonController/Melee Combat/Scripts/MeleeWeapon/vIMeleeFighter.cs:59) Invector.vMelee.vMeleeAttackObject.ApplyDamage (Invector.vMelee.vHitBox hitBox, UnityEngine.Collider other, Invector.vDamage damage) (at Assets/Invector-3rdPersonController/Melee Combat/Scripts/MeleeWeapon/vMeleeAttackObject.cs:132) Invector.vMelee.vMeleeManager.OnDamageHit (Invector.vMelee.vHitInfo hitInfo) (at Assets/Invector-3rdPersonController/Melee Combat/Scripts/MeleeWeapon/vMeleeManager.cs:156) Invector.vMelee.vMeleeAttackObject.OnHit (Invector.vMelee.vHitBox hitBox, UnityEngine.Collider other) (at Assets/Invector-3rdPersonController/Melee Combat/Scripts/MeleeWeapon/vMeleeAttackObject.cs:101) Invector.vMelee.vHitBox.OnTriggerEnter (UnityEngine.Collider other) (at Assets/Invector-3rdPersonController/Melee Combat/Scripts/MeleeWeapon/vHitBox.cs:64)
|
|
red
New vMember
Posts: 18
|
Post by red on Apr 22, 2018 15:17:44 GMT
Regarding issues with MagicAISpriteHealth here's what I can see right now...
1) it's constantly rotating on all 3 axes 2) it's scale is 140 times bigger 3) it has no assigned layer
|
|
Deleted
Deleted Member
Posts: 0
|
Post by Deleted on Apr 23, 2018 9:29:06 GMT
What would cause this? I've read through this thread and saw other's with problems with the CharacterBaseEditor.cs file, but can't find a solution to the CharacterBase.cs error. Hi mate, you need to use the latest version of invector, the most recent version renamed alot of namespaces eg CharacterController to vCharacterController. Regarding issues with MagicAISpriteHealth here's what I can see right now... 1) it's constantly rotating on all 3 axes 2) it's scale is 140 times bigger 3) it has no assigned layer just an FYI, invectors AI is not production capable, you need to either use behavior designer or ice creature control or maybe emerald, invectors AI v2 is just around the corner but isnt quite ready yet i will look into the error and see what is broken, sounds like a missing null check
|
|
Deleted
Deleted Member
Posts: 0
|
Post by Deleted on Apr 23, 2018 22:01:56 GMT
I have 2 questions... 1) How do I make a Magic AI Enemy use magic against me? 2) Can anyone help me fix this error when a Magic AI Enemy dies? The problem is this error causes the enemy to stay alive. MissingReferenceException: The object of type 'MagicAISpriteHealth' has been destroyed but you are still trying to access it. Your script should either check if it is null or you should not destroy the object. Shadex.MagicAISpriteHealth.UpdateHUDListener (Shadex.CharacterBase LevelingSystem, Shadex.CharacterUpdated Stats) (at Assets/Invector-3rdPersonController/Add-ons/ShadesSpellSystem/Scripts/MagicAISpriteHealth.cs:75) Shadex.CharacterBase.ForceUpdateHUD () (at Assets/Invector-3rdPersonController/Add-ons/ShadesSpellSystem/Scripts/CharacterBase.cs:372) Shadex.CharacterBase.OnRecieveMagicDamage (Shadex.MagicObjectDamage MagicDamage, Single Damage) (at Assets/Invector-3rdPersonController/Add-ons/ShadesSpellSystem/Scripts/CharacterBase.cs:671) Shadex.CharacterBase.OnRecieveDamage (Invector.vDamage Damage) (at Assets/Invector-3rdPersonController/Add-ons/ShadesSpellSystem/Scripts/CharacterBase.cs:516) UnityEngine.Events.InvokableCall`1[Invector.vDamage].Invoke (Invector.vDamage args0) (at C:/buildslave/unity/build/Runtime/Export/UnityEvent.cs:206) UnityEngine.Events.UnityEvent`1[T0].Invoke (.T0 arg0) (at C:/buildslave/unity/build/Runtime/Export/UnityEvent_1.cs:58) Invector.vHealthController.TakeDamage (Invector.vDamage damage) (at Assets/Invector-3rdPersonController/Basic Locomotion/Scripts/Generic/vHealthController.cs:139) Invector.vCharacterController.vCharacter.TakeDamage (Invector.vDamage damage) (at Assets/Invector-3rdPersonController/Basic Locomotion/Scripts/CharacterController/vCharacter.cs:113) Invector.vCharacterController.AI.v_AIMotor.TakeDamage (Invector.vDamage damage) (at Assets/Invector-3rdPersonController/Melee Combat/Scripts/CharacterAI/v_AIMotor.cs:530) Invector.vCharacterController.AI.v_AIController.OnReceiveAttack (Invector.vDamage damage, vIMeleeFighter attacker) (at Assets/Invector-3rdPersonController/Melee Combat/Scripts/CharacterAI/v_AIController.cs:526) Invector.EventSystems.vIMeeleFighterHelper.ApplyDamage (UnityEngine.GameObject receiver, Invector.vDamage damage, vIMeleeFighter attacker) (at Assets/Invector-3rdPersonController/Melee Combat/Scripts/MeleeWeapon/vIMeleeFighter.cs:59) Invector.vMelee.vMeleeAttackObject.ApplyDamage (Invector.vMelee.vHitBox hitBox, UnityEngine.Collider other, Invector.vDamage damage) (at Assets/Invector-3rdPersonController/Melee Combat/Scripts/MeleeWeapon/vMeleeAttackObject.cs:132) Invector.vMelee.vMeleeManager.OnDamageHit (Invector.vMelee.vHitInfo hitInfo) (at Assets/Invector-3rdPersonController/Melee Combat/Scripts/MeleeWeapon/vMeleeManager.cs:156) Invector.vMelee.vMeleeAttackObject.OnHit (Invector.vMelee.vHitBox hitBox, UnityEngine.Collider other) (at Assets/Invector-3rdPersonController/Melee Combat/Scripts/MeleeWeapon/vMeleeAttackObject.cs:101) Invector.vMelee.vHitBox.OnTriggerEnter (UnityEngine.Collider other) (at Assets/Invector-3rdPersonController/Melee Combat/Scripts/MeleeWeapon/vHitBox.cs:64) Ok this has been resolved in the latest release, was found to be a double error, a missing null check on the 2nd hand particle effect was cascading and causing a endless null situation by failing to remove the event delegate.
Release 2.1f Fixes AI in features scene github.com/ShadesOfInsomnia/SpellSystem/releases
This release includes Refreshed features scene Fix for endless AI sprite errors caused by event deregister timing Null checking for the second limb on MagicAttackBehavior & SpellBookAttack
DO NOT INSTALL THIS RELEASE UNLESS YOU ARE RUNNING INVECTOR MELEE 2.3 OR SHOOTER 1.2
|
|
bdk
New vMember
Posts: 7
|
Post by bdk on Apr 24, 2018 8:55:24 GMT
Hi, I'm am loving this add on, but I have a few issues and gripes.
SUPER IMPORTANT I cannot build. Because you include SpellSystem/Invector-3rdPersonController/Add-ons/ShadesSpellSystem/Scripts/SpellBook.cs 7: using UnityEditor.Animations;
I have the latest, I even looked in the GitHub and it is in the latest version. (04/24/18) Very annoying to get to a stable position and then realize your cannot build because some third party assets referenced the editor not in the editor.
Why isn't the spell book purely a editor window? Why make it a custom inspector at all? There's no need for it to be in any scene, right?
ANNOYING In the spell book, it never remembers the defaults. Thus every-time I want to make even the most minor change, I have to grab all he defaults again and again and again. I don't understand how you could test the system without going insane.
Thanks, this system is going to go great with my current project, once the build issue is fixed.
|
|
red
New vMember
Posts: 18
|
Post by red on Apr 24, 2018 19:36:38 GMT
Haha this is ingenious :D Also, thanks for the super awesome support!
|
|
Deleted
Deleted Member
Posts: 0
|
Post by Deleted on Apr 24, 2018 23:25:12 GMT
Hi, I'm am loving this add on, but I have a few issues and gripes. SUPER IMPORTANT I cannot build. Because you include SpellSystem/Invector-3rdPersonController/Add-ons/ShadesSpellSystem/Scripts/SpellBook.cs 7: using UnityEditor.Animations; I have the latest, I even looked in the GitHub and it is in the latest version. (04/24/18) Very annoying to get to a stable position and then realize your cannot build because some third party assets referenced the editor not in the editor. Why isn't the spell book purely a editor window? Why make it a custom inspector at all? There's no need for it to be in any scene, right? ANNOYING In the spell book, it never remembers the defaults. Thus every-time I want to make even the most minor change, I have to grab all he defaults again and again and again. I don't understand how you could test the system without going insane. Thanks, this system is going to go great with my current project, once the build issue is fixed. ok first thing, is that the spell book does not need to be in scene, just select the prefab in the project view and the settings will persist, as stated on release if you instead use it in scene, then you need to either delink the spell book from its prefab or apply the changes to the prefab. it was included in the scene so people could find it, not as the ideal way of accessing it you also need to ensure that the prefab is not read only i have used compiler directives to exclude unity editor specific components preventing build, in classes, CharacterDataBase and spell book original levelling system also had a reference but that class is not needed and provided for reference basically the spell book is using the prefab as its spell database, which is why it needs animator controller in the base class, but you are correct that doesnt build but compiler directives easily solve this i am getting issues building with SQLLite included, simply delete the plugins folder and CharacterDataBaseSQLLite class, i will have a look another time into the system.data.dll error download the latest release, it builds on the current unity and invector versions
Release 2.1g Build fixes github.com/ShadesOfInsomnia/SpellSystem/releases
This release includes - added editor compiler directives to CharacterDatabase and SpellBook classes - removed the un-needed include to UnityEditor in Original levelling system - removed the un-needed include to system.data in CharacterDataEasySave2 - Fixed the warning in GameObjectProximitySpawner
DO NOT INSTALL THIS RELEASE UNLESS YOU ARE RUNNING INVECTOR MELEE 2.3 OR SHOOTER 1.2
Also, thanks for the super awesome support! Shades Of Insomnia notes your appreciation
|
|
|
Post by shadex on Apr 25, 2018 0:23:50 GMT
Hi, I'm am loving this add on, but I have a few issues and gripes. SUPER IMPORTANT I cannot build. Because you include SpellSystem/Invector-3rdPersonController/Add-ons/ShadesSpellSystem/Scripts/SpellBook.cs 7: using UnityEditor.Animations; Dude, if you can't build, remove the include yourself. It's really not that hard.... And if it is, then welcome to scripting, keep at it man! So out of question, what was the rush for this? I see the SUPER IMPORTANT... did you have like an investor deadline or something? Ahh, i think there is a misunderstanding. You should really read the first post. We didn't make the spell system, and give it away for free so that you personally could make a game. See, we are making a game as well. We just decided to give away the tools and systems we made. So the design choices, like the custom inspector, are things we like. And if you get a weird include from something else, it's most likely because we just updated the system with something we just finished working on, and wanted to give it away. As to your being annoyed.... Honestly, why should i care? I mean logically, think of the reasons. I can't. I tested it. Though you could probly make a good case for insanity, everything worked fine for me. Post a video or the error in the console window. Your kinda a dick, and i don't feel like playing the guessing game with how you screwed up our system.
|
|
|
Post by projectsolid on Apr 25, 2018 0:51:31 GMT
What would cause this? I've read through this thread and saw other's with problems with the CharacterBaseEditor.cs file, but can't find a solution to the CharacterBase.cs error. Hi mate, you need to use the latest version of invector, the most recent version renamed alot of namespaces eg CharacterController to vCharacterController. I'm updated to the most recent version of Invector V2.3. It's a brand new project to test so should be a clean build. Does my folder structure look accurate?
|
|
|
Post by gamifytheworld on Apr 25, 2018 2:48:04 GMT
When I open a chest in the first demo (Generic AI) scene my player will start rolling forever hi mate, change the animator to the v3 one on the player, also note that is not the main demo, load features_showcase (recommended) or lobby scenes (if you want the save/load capability, make sure you add the scenes to the build settings as described in the PDF) make sure you have the latest release from github also the generic AI is more of a demo rather than the core project I figured you added this scene as a quest for someone to try to figure out how to turn it off when playing. Does this have anything to do with the "shrooms" stat? :D
|
|
bdk
New vMember
Posts: 7
|
Post by bdk on Apr 25, 2018 5:08:33 GMT
Hi, thanks for the very quick response insomnia. I got my build issue fixed. I had moved some assets(including yours) to a subfolder and apparently it broke the hardcoding links in two of the assets. I guess I'm not used to paths being hardcoded. That hard coding also why my spell book defaults didn't auto populate. Thanks got the quick help insomnia. shadex, I feel I didn't communicate my message as well as I would have liked to you. I called it it super important because under the [Important, Urgent] square it is very important, but not urgent. Thus I didn't call it urgent but important. I was hoping it was some stupid and simple mistake that could be easily fixed. It was insomnia helped, which sounds weird if you didn't know insomnia was a person's name. I was just trying to provided some constructive criticism and see if you could point me in the right direction if you happened to have the time. I am under no illusions that you owe me any aid, but was very surprised at the level of discourse level at me with out even throw away advice. If the spell book inspector window works for you that's great. I still maintain it would work better as a standalone editor window, but that's more ideal design ideas than necessary action. Ideas: Take them or leave them - Remove hardcoded paths
- Spell book as an Editor window (Invector/AddOn/Shadex/Spellbook) could be a good place
- Auto generate magic ids
- Spell chains like the melee attack chains where pressing weak attack once gets A then a second time in X time Frame gets B then C
Again thanks for this asset it will save months of work, I very much appreciate all the hard work you've put into it.
|
|
|
Post by gamifytheworld on Apr 25, 2018 6:30:16 GMT
I don't think the script "MagicInput" is in the package here is a screenshot, I found the script it is Actually called "MagicSettings" a little error in the docs, No Biggie. This was driving me nuts for a while. I thought for sure I saw it somewhere, then I threw my hands up and searched here. Thanks for figuring it out.
|
|
Deleted
Deleted Member
Posts: 0
|
Post by Deleted on Apr 25, 2018 8:02:22 GMT
Hi, thanks for the very quick response insomnia. I got my build issue fixed. I had moved some assets(including yours) to a subfolder and apparently it broke the hardcoding links in two of the assets. I guess I'm not used to paths being hardcoded. That hard coding also why my spell book defaults didn't auto populate. Thanks got the quick help insomnia. shadex, I feel I didn't communicate my message as well as I would have liked to you. I called it it super important because under the [Important, Urgent] square it is very important, but not urgent. Thus I didn't call it urgent but important. I was hoping it was some stupid and simple mistake that could be easily fixed. It was insomnia helped, which sounds weird if you didn't know insomnia was a person's name. I was just trying to provided some constructive criticism and see if you could point me in the right direction if you happened to have the time. I am under no illusions that you owe me any aid, but was very surprised at the level of discourse level at me with out even throw away advice. If the spell book inspector window works for you that's great. I still maintain it would work better as a standalone editor window, but that's more ideal design ideas than necessary action. you really need to sort out your communication skills mate, re-read your post and then imagine that you had provided at zero cost thousands of lines of code to someone and see if you think your post would endear you to them and it didn't come out as constructive criticism, it came across as a rant. your lack of understanding is impressive, can you code at all, if not shadex is correct, good luck with trying to make a game. It took literally 5mins to make that build, you couldn't accomplish this, do you understand the concept of open source? the idea is that if you think something can be improved then you go and improve it and post the code for the benefit of all. i do like the way you have expanded your criticism, but with enhanced manners though still lacking in understanding, a few points - hardcoded path, where exactly, lets see, the only hard coded paths are in the wizards, including in the spell book wizard, how exactly would you like it to find the default resources, lets see you could put them in a resources folder (then they will be compiled into the game) or search the project structure (possible but why) or lets store a base path somewhere (again why), do either of these options sound sensible when it is just for a wizard to create something to save you time, go tell invector that their wizards need to do the same and see what kind of answer you get. So no the spell system has a specific place in the addons folder which doesnt clog the root structure which is preferred by lets see, my team. Can you improve on this, sure, feel free to post the code. - spell book as an editor window? it already is an editor window, of a prefab (which you missed completly and edited it in scene and didnt even think to press Apply Changes to save the data to the prefab, just leaving it in scene), i really dont think your thinking this through, how does the spell book store its data? it stores it in a prefab as a class array, to have it as a popup editor window it would need a different storage method, however what your not understanding is that the very same class array is shared between the SpellBook and the SpellBookAttack on the animator states, hence why it is stored as a prefab enabling a direct copy in memory between the two when you apply the changes to the animator. This is a massive time saver when multiple animators are in play. - auto generate magic id's? thats not right either, surely what you would like is to auto create the item in the inventory and auto assign the new magic id, manna cost attributes, that would make more sense. I have considered this but am more interested in making a game than a perfect wizard, why not show off and update the script to do this? - spell book attack chains, mate what is stopping you doing this with the existing code, just requires updating the animator to work in such a fashion, not hard either. now then before you respond, can you dial down the temperature, put on your coding hat, improve the code and post the changes I found the script it is Actually called "MagicSettings" a little error in the docs, No Biggie. This was driving me nuts for a while. I thought for sure I saw it somewhere, then I threw my hands up and searched here. Thanks for figuring it out. noted, originally the class was called magic input, i will update the docs hi mate, change the animator to the v3 one on the player, also note that is not the main demo, load features_showcase (recommended) or lobby scenes (if you want the save/load capability, make sure you add the scenes to the build settings as described in the PDF) make sure you have the latest release from github also the generic AI is more of a demo rather than the core project I figured you added this scene as a quest for someone to try to figure out how to turn it off when playing. Does this have anything to do with the "shrooms" stat? :D hahah yeah no that is just a what happened after unity did there usual thing of breaking stuff which caused endless rolling for all invector users. Hi mate, you need to use the latest version of invector, the most recent version renamed alot of namespaces eg CharacterController to vCharacterController. I'm updated to the most recent version of Invector V2.3. It's a brand new project to test so should be a clean build. Does my folder structure look accurate? yeah looks right mate
|
|
|
Post by gamifytheworld on Apr 25, 2018 8:47:22 GMT
Hi Diddly Ho Neighborino!
I've got the latest build and I cannot get the spells to equip. I first went through the tutorial and created everything from scratch. I open the offensive chest and if I load the inventory, I can see the items equipped there, but they don't show in the HUD equip slots and nothing happens on input.
I thought I missed something, so I loaded up the pre-made tutorial scenes you have provided, and I get the same problem.
Any idea where I can hunt this down?
Thanks!
PS - Invector changed the method names for their "LockInput" stuff to "SetLock...", so when you bind those on open/close chest events, the "LockInput" is no longer there in the vMeleeCombatInput.
|
|
|
Post by shadex on Apr 25, 2018 14:47:30 GMT
Hi Diddly Ho Neighborino! I've got the latest build and I cannot get the spells to equip. I first went through the tutorial and created everything from scratch. I open the offensive chest and if I load the inventory, I can see the items equipped there, but they don't show in the HUD equip slots and nothing happens on input. I thought I missed something, so I loaded up the pre-made tutorial scenes you have provided, and I get the same problem. Any idea where I can hunt this down? Thanks! PS - Invector changed the method names for their "LockInput" stuff to "SetLock...", so when you bind those on open/close chest events, the "LockInput" is no longer there in the vMeleeCombatInput. Ok first thing, check the inventory's equip slots (inventory window -> equipment inventory -> equip area -> equip area spells -> equip slots) to make sure under "Item Type" it's set to spell. Then if that doesn't solve it, go check magic Settings, and make sure the equip slots are setup. It should be right next to the inputs in a fold out called equip slots. Some times, for an unknown reason, it remove's the links for weird reasons. Like if you grouped the camera, player, eventsystem, and everything else in a gameobject and hit play (Invector really likes to be on the top level). Let me know if that fixes it. The LockInput stuff on the animator i haven't fixed yet. To be honest, right now i'm debugging some stuff with generic actions, and wanted to get some of that sorted before i released a new animator. You should be able to just replace were it said LockInput with LockMeleeInput atm.
|
|