This site is currently in read-only mode during migration to a new platform.
You cannot post questions, answers or comments, as they would be lost during the migration otherwise.
0 votes

Hello, can you give an example source code for an enemy that walks and shooting? Please provide an example source code. I have a gltf file. Tell me how to create an enemy that walks and shooting. Please provide an example source code.

in Engine by (181 points)

I've just noticed there is a pretty cool multiplayer fps project in the Godot templates. Open your Godot launcher and click on the Templates tab. Search for FPS and click on the project with the black mannequin face. Then click download and install. It will add two projects to your Godot launcher: a server and a client. In order to run the game, you'll have to open Godot twice: once with the server project and one with the client. Just press F5 in your server project, then F5 in your client project. In the client window, press the play button.

This project is neat, and it's got some pretty nice bot ai. They run, the shoot, etc. If you want to put these bots in your game, look for the files scenes/player/bot.tscn and scripts/player/ in the server project. I'm not saying it'll be easy to add to your game, but there is lots of interesting stuff to learn from this project and it's the most complete fps I've seen in Godot yet. Also, since the license is MIT, nothing is stopping you from just copying this project and adding your own stuff.

Good luck!

uh, confused as to why this was flagged.

Yeah me too. Maybe because I linked a project and said plagiarise that? But the license is permissive, that's what the project is for.

Please log in or register to answer this question.

Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read Frequently asked questions and How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to [email protected] with your username.