Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

[Released] Full Game Kit - Hammer 2

Discussion in 'Assets and Asset Store' started by PieterAlbers, Sep 8, 2015.

  1. rafleal

    rafleal

    Joined:
    Jan 11, 2016
    Posts:
    7
    Another question, I'm having trouble changing the Hammer character to another model.
    Everything seems fine, but my new character it's not being hit by the enemies bullets and I didn't managed to discover why yet... Can someone help?
     
  2. superdiederik

    superdiederik

    Joined:
    Apr 25, 2012
    Posts:
    31
    I don't think the game has an auto-aim function.
     
  3. superdiederik

    superdiederik

    Joined:
    Apr 25, 2012
    Posts:
    31
    Best place to start is in the MissionManager.cs, where the CompleteMission is called and there the targets are processed. It will require some actual work and thinking. Also, you need to make it clear to the player what he needs to do, so you might want to add something in the interface for that too...
     
  4. superdiederik

    superdiederik

    Joined:
    Apr 25, 2012
    Posts:
    31
    I think someone made a tutorial pdf for that, check the rest of this forum thread.
     
  5. Goofy420

    Goofy420

    Joined:
    Apr 27, 2013
    Posts:
    248
    transform.Find() no longer iterates through multiple children tiers, so finding the Spine got a little more difficult. Luckily, the new Animator API takes care of that by using spine = animator.GetBoneTransform(HumanBodyBones.Spine); in place of hammerPrefab.Find("Spine") etc. so it matters not what your Spine is named. The new API also supports overrides of the base class such as
    Code (CSharp):
    1.  public override void OnStateEnter(Animator animator, AnimatorStateInfo stateInfo, int layerIndex)
    2.     {
    3.         head = animator.GetBoneTransform(HumanBodyBones.Head);
    4.         leftHand = animator.GetBoneTransform(HumanBodyBones.LeftHand);
    5.         rightHand = animator.GetBoneTransform(HumanBodyBones.RightHand);
    6.         chest = animator.GetBoneTransform(HumanBodyBones.Chest);
    7.         spine = animator.GetBoneTransform(HumanBodyBones.Spine);
    8.         UpdateBones(animator, stateInfo, layerIndex);
    9.     }
     
    Fibonaccov, NeoUnity and Raf_230 like this.
  6. Goofy420

    Goofy420

    Joined:
    Apr 27, 2013
    Posts:
    248
    It has an auto-aim function when using the mobile controls.
    Line 81 of CameraManager.cs (public Enemy AutoAimEnemy) and referenced at line 175 of hammer.cs
    It assists in the snap to enemy headBone if firing and if the crosshair is within 2 degrees left or right of an enemy.
     
    Fibonaccov likes this.
  7. Weendie-Games

    Weendie-Games

    Joined:
    Feb 17, 2015
    Posts:
    75
    Having the same issue. The player only suffers damage from explosions. Anybody know how to fix it?
     
  8. kilik128

    kilik128

    Joined:
    Jul 15, 2013
    Posts:
    909
    thank's for the tut's any info about any news is welcome :!)
     
  9. kilik128

    kilik128

    Joined:
    Jul 15, 2013
    Posts:
    909
    for exemple change bone selection by tHand = animator.GetBoneTransform (HumanBodyBones.RightHand);
    etc ... more easy to use is realy important think's


    look what's goofy say lol :)

    i got difficulty to spawn the good data enemy
    Robot [#type: Enemy, #subType: FutureSoldier_LP, #interval: 1.0, #amount: 15, #unlimitedAmount: false, #range:100.0, #minMaxOffset: [5.0, 15.0], #rotation: Offset]

    give
    KeyNotFoundException: The given key was not present in the dictionary.
    System.Collections.Generic.Dictionary`2[System.String,DicEntry].get_Item (System.String key) (at /Users/builduser/buildslave/mono-runtime-and-classlibs/build/mcs/class/corlib/System.Collections.Generic/Dictionary.cs:150)
    CharacterManager.AddCharacter (System.String aType, CONTROLLER aController, .SpawnData aSpawnData) (at Assets/Project Assets/Scripts/Game/Characters/CharacterManager.cs:37)
    SpawnerManager.Spawn (UnityEngine.GameObject aGameObject, .SpawnerData spawnerData) (at Assets/Project Assets/Scripts/Game/Spawners/SpawnerManager.cs:134)
    Spawner.Update () (at Assets/Project Assets/Scripts/Game/Spawners/Spawner.cs:65)


    when use
    any string in spawner


    any option for player selection ?
     
    Last edited: Mar 4, 2016
  10. hamdouch118

    hamdouch118

    Joined:
    Mar 14, 2016
    Posts:
    12
    give me tutorial of changing character and if it work i will give you directly 10 dollar (this is for every one)
    because i reskin the game and the only thing that make me crazy is the character
     
  11. Raf_230

    Raf_230

    Joined:
    Mar 24, 2016
    Posts:
    2
    Hi !
    I love this asset .. thanks for this !..
    How i can add new weapon to Hammer and Enemy ... :)
     
  12. Proto-G

    Proto-G

    Joined:
    Nov 22, 2014
    Posts:
    213
    Look through previous posts, there's good info in there for you two :)
     
  13. jonny2027

    jonny2027

    Joined:
    Jul 16, 2013
    Posts:
    61
    Has anyone else had problems with Hammer 2 in Unity 5.4.0b10 I get hundred of errors about an invalid AABB a. I am guessing this might be something to do with positioning items but i am unsure, all in all it renders the game unplayable as i don't have characters or weapons

    Thanks
     
  14. rafleal

    rafleal

    Joined:
    Jan 11, 2016
    Posts:
    7
    I'm still having the same problem here... does anyone know what script manages de damages in the game?
     
  15. MiDuS

    MiDuS

    Joined:
    Sep 21, 2015
    Posts:
    5
    Hi, Can anyone help me or show me the direction to how to add admob in Hammer 2?

    Thank you
     
  16. Que

    Que

    Joined:
    Mar 14, 2014
    Posts:
    135
    Any plan supporting iOS and Multiplayer?
     
  17. Goofy420

    Goofy420

    Joined:
    Apr 27, 2013
    Posts:
    248
    That's a bug in Unity that began with Unity 5.3 and the SceneManagement, but it's because of the old ParticleSystem. If you replace the particle system objects with the new Shuriken system, it should fix the errors.
     
    Last edited: Aug 7, 2016
  18. superdiederik

    superdiederik

    Joined:
    Apr 25, 2012
    Posts:
    31
    Hello everybody!

    Thanks again for all your support on this project! It's much appreciated.

    Just wanted to let you know that we just released a new kit called:
    Full Game Kit - Operation Desert Road
    The tech structure of the game has been simplified, and we now even have some tutorial videos that show you how to do stuff.

    You can check it out here:
    https://www.assetstore.unity3d.com/en/#!/content/66144

    Thanks again for your support!

    Diederik / Xform
     
    hopeful likes this.
  19. Proto-G

    Proto-G

    Joined:
    Nov 22, 2014
    Posts:
    213
    How do I edit Camera1 without the game running? When the game starts, Camera1 is created... I know about the two camera scripts and the SharedData.txt, but not sure where to edit that specific camera. Thanks!
     
  20. PieterAlbers

    PieterAlbers

    Joined:
    Dec 2, 2014
    Posts:
    236
    The camera is instiated on runtime from a camera prefab. I am not sure of the correct name since I am not behind a computer. I think it is something like Defaultcamera_Prefab
    It is located in a cameras folder. So you shouldn't have a hard time finding it. :)

    Cheers Pieter
     
  21. Proto-G

    Proto-G

    Joined:
    Nov 22, 2014
    Posts:
    213
    Yeah, I found all the camera prefabs, must have been DefaultCameraLQ & HQ. Thanks
     
  22. arshikh7

    arshikh7

    Joined:
    Nov 28, 2016
    Posts:
    1
    Hai anyone have the documentation of advertising like video ads and interstitial ads using chartboost and admob. There is only a sample advertising file in the game. But how to implement advertisements in the game? Please send me the documentation for adding ads in this game at arshikhkhan@gmail.com Also can i able to put in app purchases for buying cash for real money for Google playstore inside the game? If so send me that documentation too.
     
  23. Goofy420

    Goofy420

    Joined:
    Apr 27, 2013
    Posts:
    248
    Code (CSharp):
    1.     public class ChartboostScript: Monobehaciour
    2.     {
    3.     public float adTime = 180;
    4.     public bool showInterstitial;
    5.     public bool showMoreApps;
    6.     public bool showRewardVideo;
    7.  
    8.     public bool showInPlay;
    9.     public GameObject inPlayIcon;  // for in-play icon
    10.     public GameObject inPlayText;   // for in-play text
    11.     private CBInPlay inPlayAd;
    12.  
    13.     void Awake()
    14.     {
    15.     Chartboost.cacheInterstitial(CBLocation.Default);
    16.     Chartboost.cacheMoreApps(CBLocation.Default);
    17.     Chartboost. cacheRewardedVideo (CBLocation.Default);
    18.     Chartboost. cacheInPlay (CBLocation.Default);
    19.     }
    20.  
    21.     void Start()
    22.     {
    23.     if (showInterstitial) InvokeRepeating("DisplayInterstitial", adTime, adTime);
    24.     if (showMoreApps) InvokeRepeating("DisplaMoreApps", adTime, adTime);
    25.     if (showRewardVideo) InvokeRepeating("DisplayRewardVideo", adTime, adTime);
    26.     if (showInPlay) InvokeRepeating("DisplayInPlay", adTime, adTime);
    27.     }
    28.  
    29.     public void DisplayInterstitial()
    30.     {
    31.     Chartboost.showInterstitial (CBLocation.Default);
    32.     }
    33.     public void DisplayMoreApps
    34.     {
    35.     Chartboost.showMoreApps(CBLocation.Default);
    36.     }
    37.     public void DisplayRewardVideo()
    38.     {
    39.     Chartboost. showRewardedVideo (CBLocation.Default);
    40.     }
    41.     public void DisplayInPlay()
    42.     {
    43.     inPlayAd = Chartboost.getInPlay(CBLocation.Default);
    44.       if(inPlayAd != null) {
    45.       inPlayIcon.guiTexture.texture = inPlayAd.appIcon;
    46.       inPlayText.guiText.text = inPlayAd.appName;
    47.       inPlayAd.show();
    48.       }
    49.     }
    50.     }
    51.  
    If i remember correctly, CBLocation.Default is bottom center, but you can also call the location as well:
    public void DisplayInterstitial(CBLocation location)
    {
    Chartboost.showInterstitial (location);
    }

    call it with DisplayInterstitial(CBLocation.Top);

    Honestly, I personally think the Chartboost dashboard is horrible and their API is extremely difficult to find, so I won't even use it, but to each their own. When you go to their API page, it mostly just threatens you if you don't adhere to their every whim, but very little information on the API itself on that page.

    "These guidelines help us ensure that all customers' requests are returned quickly. If you do not respect these limits, your API access will be limited.
    If you post more than one query a minute, your API access will be limited, if you post more than one request on the same app, your API access will be limited",
    and so on

    So, I suggest conversion to Unity Ads https://www.assetstore.unity3d.com/en/#!/content/66123
     
    Last edited: Nov 30, 2016
    Fibonaccov likes this.
  24. freak77

    freak77

    Joined:
    Nov 19, 2016
    Posts:
    5
    Hello,

    Your posts are amazing helpful. I downloaded your character tutorials too.

    I have 2 questions for changing characters and admob/chartboost integration.

    1- When trying to add characters using your character tutorial, which kind of character can we use? You're using a cowboy pack. But can you advice more character options that is compatible with this game? Any criterias we must consider when buying? I think they need to have something like char1, bip1, right ?

    2- My second question is about ad integration. Where to add these codes that you wrote in your latest reply? Also where to add our APP ID and APP SIGNATURE details?

    Thanks.
     
  25. Goofy420

    Goofy420

    Joined:
    Apr 27, 2013
    Posts:
    248
    1. You can use any humanoid rigged character (Mecanim)
    2. The Chartboost API will use the old Unity onGUI method (although I haven't used it in a long time, it may have changed), and that snipett can go anywhere as long as it's run on Awake(), Start(), or OnEnable() at every scene change (InvokeRepeating only needs to be called once and it'll run forever at the delay specified). The AppID should be entered into the Chartboost editor, Window/Chartboost or something similar.
     
    Last edited: Jan 2, 2017
  26. ApexofReality

    ApexofReality

    Joined:
    Feb 14, 2016
    Posts:
    102
    Is this asset dead and not being updated?
     
  27. PieterAlbers

    PieterAlbers

    Joined:
    Dec 2, 2014
    Posts:
    236
    Hi guys!

    There were some issues with upgrading/updating to Unity 2017.2

    Nothing really special, but for those interested here is a package which will update some scripts to remove any webplayer references. These are now replaced by webgl references.

    We've also updated an .psd file which was behaving oddly in 2017.2

    Apologies for not doing a proper update - but we are swamped and cannot get it done in time.

    - Pieter
     

    Attached Files:

  28. archor

    archor

    Joined:
    Sep 18, 2015
    Posts:
    9
    error CS1061: 'Type' does not contain a definition for 'IsEnum' and no extension method 'IsEnum' accepting a first argument of type 'Type' could be found

    The Line of Code is ...

    if (prop.FieldType.IsEnum) prop.SetValue(aClass, System.Enum.Parse(prop.FieldType, aDictionary[prop.Name].s));

    Any Hints ????
     
  29. PieterAlbers

    PieterAlbers

    Joined:
    Dec 2, 2014
    Posts:
    236
    Doesn't ring a bell. Not at a computer atm. Can you give me some more details. Unity version. Did you change anything? Or was this a clean import?

    -Pieter
     
  30. archor

    archor

    Joined:
    Sep 18, 2015
    Posts:
    9
    Unity 2017.1
    even with clean import / direct download gets error.
    vs 2017
     
  31. udede

    udede

    Joined:
    Jul 26, 2011
    Posts:
    72
    Hi

    hammer I want to fall into the sea die How can I do it?
     
  32. grandgrandgames

    grandgrandgames

    Joined:
    Mar 25, 2018
    Posts:
    2
    Hello,

    Currently i am Working on Your (Full Game Kit - Hammer 2)
    -> I am unable to change character Properly(Spine Missing Not Get by Shared Data). My character structure (Hierarchy) is little bit different. How can i make my character structure same as your Hammer_Prefab Character Structure. How You Rig your character (Which Tool). How can I make Same Character as Your Hammer Character ?

    I Need Some Serious Help. Give Some Attention to me

    Thanks In Advance
    @superdiederik @Ruby-Roid
     
  33. muhammadadilumar

    muhammadadilumar

    Joined:
    Jun 22, 2015
    Posts:
    11
    Can i get to know how to change the "main character". I am a newbie and getting stuck there. a guidance or a PDF would be really thankful
     
  34. superdiederik

    superdiederik

    Joined:
    Apr 25, 2012
    Posts:
    31
    @grandgrandgames from the top of my head: I think the spine is used for some aiming and strafing override animation. If the spine variable transform is not assigned (the code cannot find the spine object) you need to assign a different object to it

    @muhammadadilumar there is no how-to for this. If your character has the same setup (skeleton form), it should be possible. You need to compare your character hierarchy to the Hammer hierarchy and see where the differences are in names. As I mentioned above, the code might not be able to find a particular object in your hierarchy and you need to make fixes.
     
  35. zain1317

    zain1317

    Joined:
    Jun 15, 2020
    Posts:
    4
    How can i change the preloader panel background and how can i replace the branding logo please reply as fast as you can. Thanks in advance
     
  36. zain1317

    zain1317

    Joined:
    Jun 15, 2020
    Posts:
    4
    how to put ads on it
     
  37. Chaxy_Gamers

    Chaxy_Gamers

    Joined:
    Dec 9, 2020
    Posts:
    3
    I was looking at the comments and wanted to know if the project was updated to work correctly in the current versions ...

    unity 2020 or unity 2018
     
  38. PieterAlbers

    PieterAlbers

    Joined:
    Dec 2, 2014
    Posts:
    236
    It hasn't been specifically updated for newer versions - but I have it running properly in Unity 2019.
    There are some small issues to fix but nothing too serious - I can help you with that. Haven't tested 2020 (yet)
     
    Fibonaccov likes this.
  39. Chaxy_Gamers

    Chaxy_Gamers

    Joined:
    Dec 9, 2020
    Posts:
    3
  40. Chaxy_Gamers

    Chaxy_Gamers

    Joined:
    Dec 9, 2020
    Posts:
    3

    Please answer, I want to buy it but I want you to make sure that it works well in the lts version since I have been informed that this project was one of the best and that it was abandoned and I want to know if it can work ...
     
    JoelChala likes this.
  41. PieterAlbers

    PieterAlbers

    Joined:
    Dec 2, 2014
    Posts:
    236
    The game is working just fine on 2018.4 as well as 2019 - you do need to remove the references to the old WebPlayer since that has been deprecated. If you are running into any other issues on getting it to run or you can't build you can send me a mesasge. I am more than happy to help you out - on getting it to work if you are having trouble with it.
     
  42. JoelChala

    JoelChala

    Joined:
    Dec 9, 2019
    Posts:
    2
    The problem that is presenting me is that the text file from where it has to pull the values is doing it in INT and not in FLOAT, as it should, for example, where it has to read me the intensity of the sun that has to be 0.8f it places 8 and the same it happens with the cameras among other things ...

    ps: i am using unity 2019
     
  43. PieterAlbers

    PieterAlbers

    Joined:
    Dec 2, 2014
    Posts:
    236
    I can help you with that - but I need a bit of time since I don't have the files at thand atm
     
  44. udede

    udede

    Joined:
    Jul 26, 2011
    Posts:
    72
    hello again after a long time

    How are you? I hope you're around and replying :)

    I don't want the enemy characters to kill each other, after a while all the enemies kill themselves before I shoot and the episode ends. I hope you reply, thank you very much.
     
  45. PieterAlbers

    PieterAlbers

    Joined:
    Dec 2, 2014
    Posts:
    236
    Hi! Still around ;)

    I gave a quick look at the code this morning and realized how old that stuff is. Miracle it still works...

    I think the best solution would be to give the enemies a new type of projectile. E.g. DefaultEnemyBullet.
    This would be an exact clone of the normal DefaultBullet. Add this in the SharedData.txt under Projectiles.
    Add the new bullet to the AddProjectile method in the ProjectileManager ( in the switch())

    Duplicate and rename the DefaultBullet.cs file to DefaultEnemyBullet.cs. Make sure the switch in the ProjectileManager initializes this new script. In the InitializeSpecific of the new script adjust the projectiles layermask to exclude the enemy layer. This will make the bullet behave as normal but ignores the enemies.
     
  46. udede

    udede

    Joined:
    Jul 26, 2011
    Posts:
    72

    I was surprised to see you around here, I wasn't even expecting an answer :)

    I couldn't do it, so I emailed you again as an answer. Thank you..

    I hope you reply to the mail again. This asset is great I wish you would continue to redevelop it!
     
    PieterAlbers likes this.
  47. laparda14

    laparda14

    Joined:
    Mar 6, 2024
    Posts:
    1
    How do I change the amount of money I have already?