Units not attacking

Units not attacking

Discuss game development here, from a distinct game project to an accessible third-party mutator, down to the interaction and design of individual units if you like.

Moderator: Moderators

Post Reply
berryblizzard
Posts: 8
Joined: 10 Feb 2012, 22:22

Units not attacking

Post by berryblizzard »

My units will not attack each other. I believe that for some reason they are viewing each other as on the same team but I am not sure how. The player controlled character can injure the other character by hitting near the other character but they cannot actually aim at the other character. I will attach my code. When I start the game in the Spring lobby I do start the other character as a bot on a different team. Any tips would be very appreciated. I have attached my code for the unit definition and for the unit script.
Attachments
samuel.lua
The unit definition/weapon definition file
(2.71 KiB) Downloaded 122 times
mainChar.lua
The unit script
(4.33 KiB) Downloaded 15 times
User avatar
FLOZi
MC: Legacy & Spring 1944 Developer
Posts: 6242
Joined: 29 Apr 2005, 01:14

Re: Units not attacking

Post by FLOZi »

Not the problem - but is your unit supposed to be mobile or a building? Currently it has tags for both (movementclass and yardmap)
User avatar
knorke
Posts: 7971
Joined: 22 Feb 2006, 01:02

Re: Units not attacking

Post by knorke »

try setting Category on the unit.
could also be that the targeted point (model center in upspring) is way underground or in the sky.
The player controlled character can injure the other character by hitting near the other character but they cannot actually aim at the other character.
fps mode is pretty meh, so that is "normal"
User avatar
FLOZi
MC: Legacy & Spring 1944 Developer
Posts: 6242
Joined: 29 Apr 2005, 01:14

Re: Units not attacking

Post by FLOZi »

try setting Category on the unit.
Almost certainly the issue iirc.
Post Reply

Return to “Game Development”