• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!
  • If you're using Gesior 2012 or MyAAC, please review this thread for information about a serious security vulnerability and a fix.

TFS 1.X+ player:getFightMode() only gives me 1

Mjmackan

Mapper ~ Writer
Premium User
Joined
Jul 18, 2009
Messages
1,390
Solutions
14
Reaction score
160
Location
Sweden
Printing player:getFightMode() will only print 1, I'm not sure on how to use this command, also tried printing:
player:getFightMode(FIGHTMODE_ATTACK)
player:getFightMode(ATTACK)
player:getFightMode(FIGHTMODE)

But still prints 1 in console.
 
Solution
what are you trying to achieve here?, you will get 1-3 depending what attack mode you have in client
3TWfnZZ.png

FIGHTMODE_ATTACK = 1,
FIGHTMODE_BALANCED = 2,
FIGHTMODE_DEFENSE = 3,

this command player:getFightMode() only show number 1, 2 or 3.

Lua:
if player:getFightMode() == FIGHTMODE_ATTACK then
printf("Player are using full attack mode")
end

if player:getFightMode() == 1 then
printf("Player are using full attack mode")
end
Im only recieving a 1 no matter what If i put full attack, deff or balanced thats the problem.

Nvm, I have no clue but it didnt seem to change when I put it in a login script, but now it does when using it in a onhealthchange script..

chucky91

Well-Known Member
Joined
Apr 8, 2010
Messages
204
Solutions
9
Reaction score
96
Imprimir player:getFightMode() imprimirá apenas 1, não tenho certeza de como usar este comando, também tentei imprimir:
jogador:getFightMode(FIGHTMODE_ATTACK)
jogador:getFightMode(ATTACK)
jogador:getFightMode(FIGHTMODE)

Mas ainda imprime 1 no console.
FIGHTMODE_ATTACK = 1,
FIGHTMODE_BALANCED = 2,
FIGHTMODE_DEFENSE = 3,

this command player:getFightMode() only show number 1, 2 or 3.

Lua:
if player:getFightMode() == FIGHTMODE_ATTACK then
printf("Player are using full attack mode")
end

if player:getFightMode() == 1 then
printf("Player are using full attack mode")
end
 
Last edited:
OP
OP
Mjmackan

Mjmackan

Mapper ~ Writer
Premium User
Joined
Jul 18, 2009
Messages
1,390
Solutions
14
Reaction score
160
Location
Sweden
what are you trying to achieve here?, you will get 1-3 depending what attack mode you have in client
3TWfnZZ.png

FIGHTMODE_ATTACK = 1,
FIGHTMODE_BALANCED = 2,
FIGHTMODE_DEFENSE = 3,

this command player:getFightMode() only show number 1, 2 or 3.

Lua:
if player:getFightMode() == FIGHTMODE_ATTACK then
printf("Player are using full attack mode")
end

if player:getFightMode() == 1 then
printf("Player are using full attack mode")
end
Im only recieving a 1 no matter what If i put full attack, deff or balanced thats the problem.

Nvm, I have no clue but it didnt seem to change when I put it in a login script, but now it does when using it in a onhealthchange script..
 
Solution
Top