Weapon Variables: what do they do?
Moderator: Moderators
- FoeOfTheBee
- Posts: 557
- Joined: 12 May 2005, 18:26
Weapon Variables: what do they do?
I've made a wiki page modeled on the FBI variable descriptions page. Spring weapons have diverged enough from OTA that Maestro's tutorial doesn't seem adequate anymore.
I only filled in a few variables - if you know about weapons variables, please go by and share some info.
http://taspring.clan-sy.com/wiki/Weapon ... scriptions
I only filled in a few variables - if you know about weapons variables, please go by and share some info.
http://taspring.clan-sy.com/wiki/Weapon ... scriptions
-
- MC: Legacy & Spring 1944 Developer
- Posts: 1948
- Joined: 21 Sep 2004, 08:25
The wiki is looking good but it is a giant clusterfuck and is very confusing... there are absolutely no descriptions about what kind of variable is needed (ie if the tagline is boolean and requires only a 1 for yes or 0 for no, or whether it requires a specific number, what do those numbers mean, etc)
EDIT: Yes, I meant to say 1 or 0 not 1 or 2...
EDIT: Yes, I meant to say 1 or 0 not 1 or 2...
Last edited by SpikedHelmet on 13 Sep 2006, 03:13, edited 1 time in total.
-
- Posts: 501
- Joined: 18 May 2006, 21:19
-
- MC: Legacy & Spring 1944 Developer
- Posts: 1948
- Joined: 21 Sep 2004, 08:25
-
- Posts: 197
- Joined: 04 Nov 2004, 00:33
- FoeOfTheBee
- Posts: 557
- Joined: 12 May 2005, 18:26
I´ve had the same experience with lasers - either 0 or 1 work.Caydr wrote:Starting to wonder if, in most cases, Spring ignores the rendertype and just makes a best-guess based on the weapon's attributes. For instance, rendertype 0 or 1 apparently work with lasers, even though only 0 should work.
And there's this in WeaponDefHandler.h:
Code: Select all
#define WEAPON_RENDERTYPE_MODEL 1
#define WEAPON_RENDERTYPE_LASER 2
#define WEAPON_RENDERTYPE_PLASMA 3
#define WEAPON_RENDERTYPE_FIREBALL 4
Code: Select all
if(weaponDefs[id].name.find("disintegrator")!=string::npos){ //fulhack
weaponDefs[id].visuals.renderType = WEAPON_RENDERTYPE_FIREBALL;}
else if(weaponDefs[id].visuals.modelName.compare("")!=0){
weaponDefs[id].visuals.renderType = WEAPON_RENDERTYPE_MODEL;}
else if(beamweapon){
weaponDefs[id].visuals.renderType = WEAPON_RENDERTYPE_LASER;}
else{
weaponDefs[id].visuals.renderType = WEAPON_RENDERTYPE_PLASMA;}
Last edited by FoeOfTheBee on 13 Sep 2006, 20:57, edited 2 times in total.
- FoeOfTheBee
- Posts: 557
- Joined: 12 May 2005, 18:26
-
- Posts: 197
- Joined: 04 Nov 2004, 00:33
-
- Posts: 197
- Joined: 04 Nov 2004, 00:33