-
Posts
8 -
Joined
-
Last visited
Recent Profile Visitors
The recent visitors block is disabled and is not being shown to other users.
fiftysnens's Achievements
-
Hi, iam still not getting the hang of it. I understand if you dont have the time, but i assume u are the best person to ask. Iam getting this error message: Failed to call hook 'OnEntityTakeDamage' on plugin 'Biplane v1.0.2' (NullReferenceException: Object reference not set to an instance of an object) at Oxide.Plugins.Biplane.OnEntityTakeDamage (BaseEntity entity, HitInfo info, UnityEngine.Rigidbody rigidbody, ModularCar modularCar) [0x00014] in <4c56633b7e3a49d69e6a187890c517f7>:0 at Oxide.Plugins.Biplane.DirectCallHook (System.String name, System.Object& ret, System.Object[] args) [0x00192] in <4c56633b7e3a49d69e6a187890c517f7>:0 at Oxide.Plugins.CSharpPlugin.InvokeMethod (Oxide.Core.Plugins.HookMethod method, System.Object[] args) [0x00079] in <60c318df79ed41688ea59335e48d61ad>:0 at Oxide.Core.Plugins.CSPlugin.OnCallHook (System.String name, System.Object[] args) [0x000d8] in <50629aa0e75d4126b345d8d9d64da28d>:0 at Oxide.Core.Plugins.Plugin.CallHook (System.String hook, System.Object[] args) [0x00060] in <50629aa0e75d4126b345d8d9d64da28d>:0 the code refferanced would be: object OnEntityTakeDamage(BaseEntity entity, HitInfo info, Rigidbody rigidbody, ModularCar modularCar) { rigidbody = modularCar.rigidBody; float speed = rigidbody.velocity.magnitude; if (entity == null || info == null) return null; if ((entity.ShortPrefabName.Contains("kayak")&&(speed <=14)) || (entity.ShortPrefabName.Contains("boogieboard")&&(speed <=14)) || (entity.ShortPrefabName.Contains("engine")&&(speed <=14))) { BiplaneComponent biplaneComponent = biplanes.FirstOrDefault(x => x.subEntities.Contains(entity)); if (biplaneComponent == null) return null; biplaneComponent.modularCar.Hurt(info); NextTick(() => { var damagetaken = info.damageTypes.Total(); if (damagetaken >= 15) { Effect.server.Run("assets/content/vehicles/minicopter/debris_effect.prefab", entity.transform.position); var fireball = GameManager.server.CreateEntity("assets/bundled/prefabs/fireball.prefab", entity.transform.position); if (fireball == null) return; fireball.Spawn(); biplaneComponent.modularCar.Kill(); } }); return true; } else if ((entity.ShortPrefabName.Contains("kayak")&&(speed >=15)) || (entity.ShortPrefabName.Contains("boogieboard")&&(speed >=15)) || (entity.ShortPrefabName.Contains("engine")&&(> { return null; } return null; }
-
I do not own the usage right, but i will message you in discord. thanks up front
-
Hi, iam currently editing the Biplane plugin to my needs and i encountered a point where i dont know how to proceed. I tryed to add damage detection for when the plane collides with terrain by using Hitinfo but iam not mistaken by my privous attempts, damage dealt by anything that is not a player / projectile is not handled via Hitinfo ? If thats the case is theer any other way of detecting the collision ? I thought about checking the prefabs velocity for a sudden drop of more then ~15, but can not figure out a way to compare it to 1 or 2 frames before as the only thing i know that comes close to this would be NextTick but i doubt it can be used here. Thanks for any advise or Ideas you might have ! If you would like to see what i did so far, i have asked the same question on umod with a code example (dont worry i did not publish your work) https://umod.org/community/rust/41441-detect-plane-collison?page=1#post-2
-
AAAnd its solved. Thanks
-
No. I guess thats the problem ?^^
-
Hi, very nice Idea, i bought it to test it and play around with, but after installing and troubleshooting for 3 hours, i still cant get it quite to work ... for the whole time, wether the icons were saved localy, with imgur or on a otherwise unused webserver, the pictures dont show up when looking at the prefabs ingame