Action Robots Game (New design for the main character!

Hi everyone!

I and my father are creating an action game with robots.
The gameplay is based on games like Dino Crisis 2, Resident Evil and others, with the action from Dino Crisis and the puzzles form RE (or at least we will try to make it :smile: )

So far, we have an animated character with some controls, like shooting, walking, running and reloading his machine gun.

We plan to add other weapons too, like shotguns, pistols and rocket launcher (if everything runs OK, two of each).

Of course this is a learning project, but we have a little bit of experience with games, we already have a finished action RPG made in Blender, but we decided to use Unity because it’s much more powerful and professional.

Here’s a video of what we have so far:

Criticism and suggestions are very welcome!

man this is gonna be a good game,looks cool… :shock:

The firing animation looks powerful :slight_smile: shells look great.

I was going to say some of the animations look rigid but it’s a robot so maybe that is what you were after :stuck_out_tongue:

I would put in an animation for shuffling their feet around as they turn though.

Keep it up!

It looks really cool!

Bom dia Fiori!

Fellow Brazilian game developer :slight_smile:

Your animations look good, and also that it works in Unity.
The lightning also looks cool on the robot when shooting.

Need any help with 3d models?

see my www link.

Very cool that you’re building this with your dad.

good luck!

Looks great! And hey, a left-handed player character. Yea! Though true to life it looks like he’s firing a right-handed gun. :wink:

Hey thanks everyone for the replies!

marcos

Well, hehe, to tell you the truth that was not what we’re after, but I agree with you, it’s because we’re learning.
And my father told me about the feet too, so I’ll fix it ASAP.
Thanks for the reply!

heliora

Opa! Brasileiro no fórum!
Yeah, it’s good to make this with my father, because it’s simpler and it’s a family work.
Thanks for the comment!

Alvarus

Thanks Alvarus, and yeah he’s left-handed (altough I had not noticed until now :lol: , maybe it’s beacuse I’m left-handed too, and I did the animations).
And about the weapon, humm… errgg, I mean, it’s because he stole this from a right-handed soldier hahah…
To tell you the truth, some things about the weapons in the game are already inconsistent :stuck_out_tongue: , just like this machine gun (HK MG4), it’s a belt fed gun, not magazine fed… (lots of easier to do)
He shots a Benelli M4 too, but recharge it after each shot (like you can see in the other video), but M4 is a semi-automatic shotgun, ie. it does not need to be ā€œpumpedā€ after each shot (unless you use some special ammo).

Sorry for the long post, and here are the other weapons we have until now:

Thanks everybody, your comments and criticism keep us motivated!

Hi!

I got a question for the programmers (I think you are tired of hearing this, but I still couldn’t find the answer, so any help is apreciated!):

What is the best way to access variables in another script?

I have a GuiText displaying the ammo of my character, just like this:

var gun_script;

function Awake(){
gun _script=GameObject.Find("player").GetComponent(player_gun); 
}

function Update () {

guiText.text = "" + gun_script.ammo_left;
}

But with this method I noticed a drop of ~300 frames (from 900 to 600 fps). (I don’t know if this is the right method to pre-cache an object.)

So I tried this way:
Did ammo_left a static var and changed Update to this:

guiText.text = ā€œā€ + player_gun.ammo_left;

This way there’s no drop, but I would like not to use static var.
Is there any other way to do this?

Thanks in advance!

Looking good man. I would help with your script but I hate messing around with GUI crap.

declaring a static var is the only way I know of. Whats wrong with it? :wink:

Thanks for the replies guys!

Theformand

I was reading this: http://c2.com/cgi/wiki?GlobalVariablesAreBad

then I guessed I should use it only when there’s no other option.
But what I don’t understand is: since I use the getComponent on the awake(), is the component really stored in memory (pre-cached) or is it being searched each time in the Update (since it drop the fps)?

Hi!

I spent the past days increasing the performance of the scripts.

I did a little flying robot too, and I would like to hear what you think, if it fits with the design of the character.
Those ears would have some electrical sparks, and in one part of the game, one of these would act just like the head of a giant robot.

It has 598 tris.

Thanks in advance!

Whoa, very nice animations you have for the robot. I like how the clips shells fall bounce when hitting the ground.

Thanks Eleventh!
The clips and shells are all rigidbodies, we liked it a lot too!

Hi everybody!

We have some progress in the gameplay, now he can:

*Dodge to left anf right
*Lock on target (if you press the ā€œR3ā€ button (for ps2 like joysticks) he aims to the nearest enemy.
*Strafe left and right while aiming
*Do somersaults to avoid attacks

I still need to code him to get hit by explosions or other strong attacks (he will be thrown away).

Here’s the vid showing the progress, we hope you like it!

I do have to say, that looks really good. Lots of detail for just the basics :slight_smile: Makes me think the rest is going to be that much better.

really like it, love the animations and the backflip it great :stuck_out_tongue: might get old soon but still cool.
keep up the good work

Have the code that decrements the ammo call this script, with something like a SetAmmoCount function. When you get a new ammo count, update the text. Doing it once per frame is overkill - since it can only change so often, and the gun script knows when it changes.

You can save the ammo count in a private var, rather than a static. Globals are bad, and the design of the Unity engine is very conducive to avoiding them.

Thanks for the replies!

kyoryu
Thanks for the tips, made things clearer.

What do you think about this:

In idle state in that vid, I get an average of 470 fps and 2.1ms/frame.
When I shoot to fully unload the magazine(40 bullets), it can drop to 150fps, because each bullet gives me 2 draw calls and has a rigidbody and a capsule collider, so I end up with ~100 draw calls.
Is it a bad performance for a scene like that or is it ok?

Hardware:
Pentium 4 3GHz
1GB Ram
NVidia Geforce 6200 (256MB ram)

Thanks in advance!

Any thoughts about it ^ ?

There’s another video showing the damage system and a particle test: