![]() |
"hidden" Variable for Weapons
It would be greatly appreciate if a built-in "hidden" variable was added so weapons can be made invisible to the default weapons menu without adding a negative in the weapon name. Doing so makes it a hassle when calling a public function on a hidden weapon since you must use the makevar() function due to the negative, it would be must easier to not have to use it.
|
PHP Code:
|
Quote:
|
Quote:
|
You don't get it, I don't want to have to use any type of function to access the weapon.
just WeaponName.function() instead of findweapon(weaponname).function(); It just looks better the first way. Quote:
While serverside global variables work fine, clientside global variables work sometimes and sometimes not, i'm not exactly sure on the reason. However this topic is about having a weapon.hidden variable not the findweapon() function, everything you all said was completely useless. |
I support Invy.
-Munches on his bri-- cookie.- |
Quote:
Quote:
|
Quote:
|
Quote:
|
Anyways, adding a negative before a weapon name just looks bad to me, thats mostly why I wont the weapon.hidden variable.
|
Quote:
Also, I don't get how so many people misspell 'want' with 'wont' o_O a and o are on opposite sides of the keyboard |
Quote:
And in respose to the first statement, I'm the NPC Admin, I see it all the damn time when i'm scripting and have to work around it to. Just having to use a function to get around the negative in the weapon name annoys me, even if I only have to use it once for a global variable, I just don't want to have to do it at all. I also think there should be a nodelete flag for weapons instead of putting the * before the weapon name. |
Quote:
Also, it has been said that findWeapon("") is a better way to do it anyway, so why not just use that? :| [edit] re-reading my post it seems like that 'some people's scripting habits' was directed at you, take note that it wasn't. It was just a generalised assumption.[/edit] |
Quote:
|
Doesn't the 'protectedweapons' server option prevent NPCs from being deleted?
|
Quote:
After reading another thread I think an alternative to using a hidden variable would be to have a checkbox in the window where you set the weapon name for making it hidden and one for the no-delete. That way the server would know, and you wouldn't need a hidden variable. |
Quote:
|
| All times are GMT +2. The time now is 11:38 AM. |
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.