Created
January 30, 2016 14:17
-
-
Save jameslkingsley/5de5dd6ef4632d994a1b to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/////////// HPP /////////////////////////// | |
void add_weapon_item(const object& obj_, const std::string& weapon_name_, const std::string& item_name_); | |
void add_weapon_item(const object& obj_, const std::string& weapon_name_, const std::string& item_name_, int ammo_count_ = 1, const std::string& muzzle_name_ = ""); | |
/////////// CPP /////////////////////////// | |
void add_weapon_item(const object& obj_, const std::string& weapon_name_, const std::string& item_name_) { | |
game_value params({ | |
weapon_name_, | |
item_name_ | |
}); | |
host::functions.invoke_raw_binary(client::__sqf::binary__addweaponitem__object__array__ret__nothing, obj_, params); | |
} | |
void add_weapon_item(const object& obj_, const std::string& weapon_name_, const std::string& item_name_, int ammo_count_, const std::string& muzzle_name_) { | |
game_value params({ | |
weapon_name_, | |
game_value({ | |
item_name_, | |
ammo_count_, | |
muzzle_name_ | |
}) | |
}); | |
host::functions.invoke_raw_binary(client::__sqf::binary__addweaponitem__object__array__ret__nothing, obj_, params); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment