• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[Pawn] [OMP] Errors compiling
#1
Hello, I tried to compile samp gamemode with open.mp and encountered errors and warning that I can't find anywhere in docs

public OnPlayerKeyStateChange(playerid, newkeys, oldkeys) ------> error 025: function heading differs from prototype
                                                                                                                      warning 213: tag mismatch: expected tag "t_KEY", but found none ("_")

public OnPlayerWeaponShot(playerid, weaponid, hittype, hitid, Float:fX, Float:fY, Float:fZ) ----------> error 025: function heading differs from prototype

GivePlayerWeapon(playerid, 31, 15); ------------------> warning 213: tag mismatch: expected tag "t_WEAPON", but found none ("_")
  Reply
#2
The first one use:

PHP Code:
public OnPlayerKeyStateChange(playeridKEY:newkeysKEY:oldkeys

The second one I'm not sure, the code looks correct. Double-check by copying this:

PHP Code:
public OnPlayerWeaponShot(playeridweaponidhittypehitidFloat:fXFloat:fYFloat:fZ

IF that doesn't work it could be a library incorrectly hooking the calback.

PHP Code:
GivePlayerWeapon(playeridWEAPON_M415
  Reply
#3
PHP Code:
public OnPlayerWeaponShot(playeridWEAPON:weaponidBULLET_HIT_TYPE:hittypehitidFloat:fXFloat:fYFloat:fZ
  Reply
#4
Ребята вы красавчики!Спасибо вам за старания!
  Reply


Forum Jump: