# \[Solved\] How do you command properly

**URL:** <https://discourse.codecombat.com/t/solved-how-do-you-command-properly/25651>\
**Category:** Level Help\
**Created:** [November 24, 2020, 1:07pm UTC](https://discourse.codecombat.com/t/solved-how-do-you-command-properly/25651 "2020-11-24T13:07:26Z")\
**Posts on this page:** 1\
**Showing post:** 8

<div class="post-metadata">

**Author:** ![brooksy125](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.codecombat.com/brooksy125/32/9966_2.png) [@brooksy125](https://discourse.codecombat.com/u/brooksy125)\
**Post date:** [November 24, 2020, 7:26pm UTC](https://discourse.codecombat.com/t/solved-how-do-you-command-properly/25651/8 "2020-11-24T19:26:44Z")

</div>

> [@riticmaster9087](#):
>
> try using findByType(minnion name)

I agree with @riticmaster9087 on this one. The findByType() method works very well if you have the correct glasses that include this method. One note for this method, you need to understand that this is going to return an array list of all the soldiers. So using a for loop to command them individually works very well.

You can also include an additional parameter that ensures you are only finding friendly soldiers or whatever type you search for. This is important when you fight against warlocks since they can raise your soldiers from the dead to fight against you. If you don’t include the friends limitation, you will try to command the raised soldiers that are now enemies and you can’t, you will get an error.

`hero.findByType("soldier", hero.findFriends())`  
 ![findByType](https://us1.discourse-cdn.com/flex016/uploads/codecombat/original/3X/6/4/64d35ed670fb30848c169d0153593098f8eef688.jpeg)

Otherwise, using a for loop with your friends like @Lydia_Song suggested with the type check included like @abc mentioned is another great way to isolate the type of friends you want to command.

Extra note for those that are new to commanding friends: you have the right Boss Star that allows you command the different friends.

> [@Summonable units and their basic stats](https://discourse.codecombat.com/t/summonable-units-and-their-basic-stats/18501):
>
> As I like to have an easily view-able list of sorts for the summon-able units, I thought I’d do this. In case of misspellings, wrong stats or similar, let me know! Hope someone else might find it as interesting or useful as me! Not sure if anyone else might have a need for it though. Summonable Units - as of the 31th of May, 2019 Some basic Summonable-Unit Stats that I thought would be useful in this kind of fashion. (if not changed by level) Soldier - Boss Star I
> 
> > **Click to show/hide Sta…**
> >

---

_[View the full topic](https://discourse.codecombat.com/t/solved-how-do-you-command-properly/25651)._
