Page 1 of 3 123 LastLast
Results 1 to 10 of 26

Thread: Unknown command give

  1. #1

    Default Unknown command give

    ok so in spearhead i have a working swap rifles mod but im trying to convert it over to MOHAA the only thing is the give function is not allowed in MOHAA so whats the replace for such code?

    Example - But not allowed in AA works in SH
    Code:
    local.player give "models/weapons/enfield.tik"

  2. #2

    Default

    "give" does work in mohaa
    "giveweapon" is another alternative e.g. local.player giveweapon "models/weapons/mp44.tik"

    but give alone should work just fine
    post more info and the context of your script to see what's the error

  3. #3

    Default

    Quote Originally Posted by Zappa View Post
    "give" does work in mohaa
    "giveweapon" is another alternative e.g. local.player giveweapon "models/weapons/mp44.tik"

    but give alone should work just fine
    post more info and the context of your script to see what's the error


    both give and giveweapon come up as unknown command for me but alternatively

    I was able to fix the issue with the line of code: local.player weapon "models/weapons/kar98.tik" instead of local.player give and now it works perfect.

    another thing i noticed is that bash does not work for MOHAA? or do u need to edit mike torso?
    Last edited by assasin5469; October 27th, 2022 at 11:34 PM.

  4. #4

    Default

    Quote Originally Posted by assasin5469 View Post
    both give and giveweapon come up as unknown command for me
    Are you running mohaa 1.11 with the reborn patch or another version?
    that "unknown command" message shouldn't even be a thing unless you are running a version that doesn't have them (no idea if 1.0 have them or not)

    Quote Originally Posted by assasin5469 View Post
    another thing i noticed is that bash does not work for MOHAA? or do u need to edit mike torso?
    Only the pistols have bash animations in mohaa

  5. #5

    Default

    That unknown command shouldnt happend unless is not a player you are sending that command.
    Last edited by DoubleKill; October 30th, 2022 at 10:49 AM.

  6. #6

    Default

    Quote Originally Posted by DoubleKill View Post
    That unknown command shouldnt happend unless is not a player you are sending that command.
    I don't understand. Do you mean when local.player is NIL/NULL?

    When that happens you get a message like this: "Script Error: command 'give' applied to NIL/NULL listener"

    But when a command literally does not exist in the game, for example, if you write "giv3" instead of "give",
    you get a message like this:
    "unknown command: giv3"
    and then a "Script file compile error"


    That's why my theory is that he is using a different version without the give command, or maybe the server binaries got corrupted

  7. #7

    Default

    I mean he is tryng to use that command in a different entity.

  8. #8

    Default

    Quote Originally Posted by DoubleKill View Post
    I mean he is tryng to use that command in a different entity.
    I don't think so

    assasin said his script works in spearhead but not in mohaa
    and when he replaced the "give" command with the "weapon" command the script worked well. So local.player is definitely a valid Player entity on his swap rifles mod

  9. #9

    Default

    We need to see the script to check what is causing this issue.

  10. #10

    Default

    Quote Originally Posted by Zappa View Post
    Are you running mohaa 1.11 with the reborn patch or another version?
    that "unknown command" message shouldn't even be a thing unless you are running a version that doesn't have them (no idea if 1.0 have them or not)


    Only the pistols have bash animations in mohaa
    be honest i have not a clue im fresh to reborn and what it its i just installed like i use to cd patch 2.15 for spearhead etc... lol seems alot has been dont over the years

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •