Author Topic: Weapon Generator Script  (Read 1965 times)

Basically it works the same way like it does in Borderlands 2, all the weapons and name types are generated randomly, each weapon featuring a unique feature of its own. Each weapon would have different stats, strengths and abilities. And the community could offer preset names that could go into the generator. It could go with an event like 'OnPlayerTouch > GenerateWeapon' and such.

The generated weapons could be made up of modelled parts which can belong to any kind of weapon group (basically you could end up with a pistol shotgun)

Types of parts would include

Stocks

Grips

Receivers

Magazines

Barrels

Sights

Stats would include

Weapon Damage

Weapon Speed

Weapon Weight

Reload speeds



As the above is just an shallow idea, I figured maybe we could try to take the next step and go as far as to cover almost all the mechanics of the gun itself internally. Such as:

Trigger type

Spring type/strength

Material

Ammunition type

Smooth or Bored barrels

and there's probably a lot more we could think of.



We could set it up to where we can add acceptable user created parts and updates for the database so that the uniqueness of the weapons expands farther and father.

Personally I think this would set up an entirely new burrow for a modeler to dig into, such as perfecting and creating new weapon parts.

This is probably too complex for Blockland, but I figured I'd get the idea out.

from what i know this literally seems impossible
how would you even go about putting different part models and stuff lol

it's not

it's actually possible, it'll only take a lot of work

I can see how you could code the stats without creating extra datablocks and such, but I dunno about models, whether or not you can somehow mount parts to them.

The randomised stats are easily possible, but models would be extremely hacky, if possible in Blockland alone at all.

lol mount a bot model to your hand and unhide nodes for parts of it, create an entirely new weapon system

lol mount a bot model to your hand and unhide nodes for parts of it, create an entirely new weapon system
this
fully possible, would just be a huge pain in the ass to make with very limited application


I doubt this will happen but it seems like a really cool idea.

/support

Kinda like Borderlands

I guess this would work, eventually like the minifig does.
But yeah, lots lots of work and I don't see how it could be implemented for the use of an user. How exactly would spawning a weapon work.

But yeah, lots lots of work and I don't see how it could be implemented for the use of an user. How exactly would spawning a weapon work.

There'd probably be like a sort of base gun where there's a sort of universal model for the item datablock; for example, an AK47 model for any randomly generated AK-type weapons, be it a shotgun or an SMG. That being said, every weapon would probably end up having to have a base gun for it, probably based off real life weapons like the AK47 mentioned before and AR15s, AR18s, etc.

however, when you equip it, a script runs with the "Activate" sequence that randomizes the gun by hiding/unhiding different nodes (if the bot approach is taken) and randomizes the stats accordingly, as well as saving the randomizations, however that'd be done, and changing and saving a variable to check whether the gun has been randomized already or not, so that the gun is the same when it's dropped and picked up.

if the gun gets a sight as a random modification then whatever statistics would carry over to the sighted-in datablock with whatever necessary variable changes such as decreased spread, etc.

There'd probably be like a sort of base gun where there's a sort of universal model for the item datablock; for example, an AK47 model for any randomly generated AK-type weapons, be it a shotgun or an SMG. That being said, every weapon would probably end up having to have a base gun for it, probably based off real life weapons like the AK47 mentioned before and AR15s, AR18s, etc.

however, when you equip it, a script runs with the "Activate" sequence that randomizes the gun by hiding/unhiding different nodes (if the bot approach is taken) and randomizes the stats accordingly, as well as saving the randomizations, however that'd be done, and changing and saving a variable to check whether the gun has been randomized already or not, so that the gun is the same when it's dropped and picked up.

if the gun gets a sight as a random modification then whatever statistics would carry over to the sighted-in datablock with whatever necessary variable changes such as decreased spread, etc.
when they pick it ip not on the activate sequence, cause then it would change everytime they equipped it

when they pick it ip not on the activate sequence, cause then it would change everytime they equipped it

no but a script would be stated that would determine if the weapon is randomized already or not, which then it would randomize it, save the randomizations, and a miscellaneous variable that's checked to see whether the weapon was randomized or not. this would all happen with the activate sequence when you first equip the gun.

unless, however, there's a onpickup function sort of thing
which sounds way better anyway lol