#CSO Weapons

1 messages Β· Page 3 of 1

obsidian chasm
#

which is the next gun to be coded?

digital night
#

i tried to make a list of the author of every map i had a bsp for and it was impossible

#

granted i had a lot of stuf fmixed it from other games

stuck crow
#

I hope this

obsidian chasm
#
Counter Strike Online Wiki

A weapon is an instrument or device used for many purposes: mostly to harm, damage, destroy or annihilate a target in specific. There are several main weapon types in Counter-Strike Online...

stuck crow
#

imo there's no point in coding vanilla guns at all, since there are already two plugins (CS and CSCZ) with these weapons

obsidian chasm
#

maybe just borrow that code from them πŸ˜›

stuck crow
#

btw I want to see more smgs since there's only 2

obsidian chasm
#

mmm, most of the smgs are normal weapons, so maybe those weird ones are best pickings

stuck crow
#

and grenades
imagine killing gargantua or big momma with that thing aaagaben

obsidian chasm
#

ah yes, grenades, there is no grenades here mm

#

chain grenade seems fun, michael bay style, double explosion

austere dock
#

nasi lemak packaging is literally that

stuck crow
#

killing bastards with rice and water

half tendon
#

Void Avenger

stuck crow
austere dock
obsidian chasm
#

i think the choices should be weapons with interesting effects and stuff

#

the volcanus idk what it does but does it say it spawns more barrels to shoot from?

austere dock
obsidian chasm
#

ah lame D:

austere dock
#

it has dynamic dmg, from low to high dmg as the round consumed the mag

#

as for balrog3, uh.. this one doesnt make sense but still in ok weapon for me. its alt attack is the gun consume the whole ammo instead of mag lol

#

35 | 170 <--- alt attack consume this one lmao, not the 35

stuck crow
#

it's useful when there's a horde of mfuckers

austere dock
#

im in ok with special cso weapons, my only interest is svdex tbh. so yeah

obsidian chasm
#

what about the spear gun

#

gae bolg

austere dock
#

VSK is kinda nice too.

stuck crow
austere dock
#

make it challenging AYAYA

stuck crow
#

well, I'm talking about my experience in Misfire, but sure

austere dock
#

ah i see mb

stuck crow
obsidian chasm
#

or the hammer, wasnt the hammer ported already?

stuck crow
#

nah

obsidian chasm
#

meh melee weapons arent that good i see

digital night
#

why is this reddish in first person but yellow in third?

#

the v model doesnt have any red in it

stuck crow
#

that's why I shared remapped version as a separated file

#

maybe somehow it's possible to make recolorable lighting and third-person model with a script, but I'm not a scripter at all

digital night
#

did someone post a sven arms version without the color remap?

#

once a texture designates that it will do the color remap thing i dont know how to override that or replace the textures

stuck crow
#

oh, it's simply in this case

#

just rename all "remap*_" (except hands texture) to whatever you want via HLAM

#

or just replace this model to model from archive

digital night
#

ah i use a different model viewer that doesnt let me do much

digital night
#

@stuck crowi dont understand the logic of it but i converted the textures to grayscale and it made them not be able to change color but somehow its yellow despite there not being a yellow texture anymore

bitter valve
digital night
stuck crow
#

from that archive

#

@digital night

#

sry, I'm at work right now and kinda busy
so I could just send you the file 😒

digital night
#

Oh thanks.

stuck crow
#

at least it's not such a mess like previous one with separated files

obsidian chasm
#

Nice thank you, this is canon now πŸ˜›

stuck crow
#

I just have a broken mouse at work and the middle button sometimes keeps pushing kernnotlike

#

and it pissed me off

obsidian chasm
#

my middle one is dead, and the left click 50% chance to triple click at once

#

I must change it D:

obsidian chasm
#

@bitter valve in this map https://discord.com/channels/170051548284583937/1239114856305524776
I have used awp, m134hero and usas12.
In the current version v1b of the maps, I no longer crash but in v1 I kept crashing randomly on map load.
A user in the comments has pinned down his crashing to the m134hero weapon script.
If anything, I fixed 99% of crashing by just tweaking osprey pathing, so maybe the gun is conflicting with something in the ospreys? or anything else at all? I don't know, i'm out of ideas maybe its 2 separate cases... but just to let you know so you can check the code on that weapon and see if anything seems to be wrong maybe

bitter valve
#

Maybe the cooldown bar hud thingy?
or the ScreenShake ?

obsidian chasm
#

Nevermind

#

I was maybe using an old version of your script or not, but this line is what was causing the problems

    ~weapon_m134hero()
    {
            self.m_fInReload = false;
            SetThink(null);
            m_iState = STATE_NONE;
            m_bOverheated = false;
            m_bRapidMode = false;
            g_PlayerFuncs.HudToggleElement( m_pPlayer, CSOW_HUD_CHANNEL_CD, false );
    }
bitter valve
#

Oh, yeah that shouldn't be in there any more ayaya

obsidian chasm
#

btw any reason why do this?

const string SPRITE_HUD = "custom_weapons/cso/progressbar.spr"
g_Game.PrecacheGeneric( "sprites/" + SPRITE_HUD );

#

it also says from @teal harbor kernnotlike

#

this makes resguy think the file is missing, and at the same time i think its not necessary to split the path like that?

bitter valve
#

It's for customization ayaya

#

And I was gonna make me own bar, but sprites in gsource are a pain the the aaaaassssss pinkieOwMyHead aRage

obsidian chasm
#

but... the crashing was all about you πŸ˜›

teal harbor
#

The script object might be destroyed first before the entity so theres a danger here

bitter valve
#

Yeah as was said; old version ayaya

teal harbor
#

oh

#

okay πŸ˜ƒ

small thistle
#

2100th message

austere dock
#

damn, even ddoser come to the script showcase thread as well. what a boring lad

stuck crow
#

oh no, he's gonna ddos the servers that use those guns kernnotlike

small thistle
#

to be honest relatable

obsidian chasm
#

whats up in sinaloa?

small thistle
#

hello

austere dock
stuck crow
#

oh no

small thistle
#

only

digital night
small thistle
#

and why?

digital night
#

What is the significance of jew faq?

#

Seems random

small thistle
#

wdym by that

digital night
#

What's so significant about jewfaq that you feel it's worth it?

small thistle
#

not only this site

#

9 more

digital night
#

Ah okay

#

So you have a list

small thistle
#

yeah

austere dock
digital night
#

Ddosing jewish websites because they don't like the CSO weapon pack seems kind of extreme, no?

digital night
#

Benjamin Netanyahu did make a formal declaration about the banning of the Thanatos9 but it was strictly for issues of national security.

obsidian chasm
#

But there are no jeweish sven servers plus this is korean

#

||If you have to ddos jewish webs youre gonna have a rude awakening... all govts and most rich companies are jewish. Its sadly you against the world. I'm with you but taking on the pentagon, cocacola, israel, and every single thing would be impossible unless youre superman||

#

||But wait I have an idea. I'm from argentina, jewish president now, hes destroying everything. First thing he did was support israel and go meet his rabine and elon musk. Argentina has the worst security that exists, mostly because ppl here are idiots and also outdated. Its free pickings, easy target. Several times govt pages get hacked so easy. Its your chance||

#

||I sometimes believe they created hitler to do all that stuff and create antisemitism so every time they do evil things they just pull up that card. Either that or they took the opportunity. I believe there must be good jewish people but their religion got hijacked by a bloodline of psychopaths that are now majority||

#

Ok yeah this is cso weapon thread haha

scenic zealot
#

the CSNS can be modded since anti-cheat Doesn't Detect modifing/loading Fixtrike to CSNZ/data folder. But not on other region KR, TW and CN they Detect fixtrike as 3rd party apps according from ZxAnugrah.

lofty lark
tame fog
#

@bitter valve
Missing files:
Error: server failed to transmit file 'events/cso/muzzle_skull11_1.txt'
Error: server failed to transmit file 'events/cso/muzzle_skull11_2.txt'
Error: server failed to transmit file 'sound/custom_weapons/cs16/usas_draw.wav'

obsidian chasm
#

no sven hands? sacrilege

austere dock
#

Waiting for nero to continue this pack, since he's still working on CNPC (no pressure though, nero).

obsidian chasm
#

i'm not very good with scripting but I'm mixing and matching stuff to create the unreal tournament weapons, some of them at least. I will use the plasmagun for the pulse rifle, and the duke nukem rocketlauncher for the rpg for example. Nero has already done the biorifle, and takkedeppo made the razor

bitter valve
#

I've uploaded the sven hands, but I haven't tested them or anything.
That'll take more time than I have atm. hehe

obsidian chasm
#

this is on current 5.26

#

maybe precaches are not going through very well

austere dock
#

because that sprites doesnt exist in the custom_weapons/cso folder thus why. 5.26 version seems doesnt ignore the code that the file missing unlike the previous 5.25 version.

#

plus i believe it should be there inside nero's current cso weapons files. because i have it in my folder. its weird if you dont have it.

obsidian chasm
#

I have them just fine

#

weird

#

maybe I'll just replace those weapons in that map

austere dock
#

check your Precache() for the current weapon you use in the code.

obsidian chasm
#

i dont see any precache in that script

#

nero will have to fix all precaches that arent precaching ha 😦

austere dock
#

usually i'll do this if stuff like this occur. i'll start to write these in any space in csocommon.as code.

void CSOCommonSpritesPrecache()
{
g_Game.PrecacheModel( "sprites/custom_weapons/cso/smoke_thanatos9.spr" );
g_Game.PrecacheModel( "sprites/custom_weapons/cso/wall_puff1.spr" );
g_Game.PrecacheModel( "sprites/custom_weapons/cso/wall_puff2.spr" );
g_Game.PrecacheModel( "sprites/custom_weapons/cso/wall_puff3.spr" );
g_Game.PrecacheModel( "sprites/custom_weapons/cso/wall_puff4.spr" );
}

then i will put it in the MapInit() by calling that void function in custom weapons register file.

void MapInit()
{
    cso::CSOCommonSpritesPrecache();
}
#

or you can also do something like nero did in svd code.

void CSOCommonSpritesPrecache()
{
for( uint i = 1; i < pSmokeSprites.length(); ++i )
    g_Game.PrecacheModel( pSmokeSprites[i] );
}

then do the same as registering it in MapInit()

void MapInit()
{
    cso::CSOCommonSpritesPrecache();
}

choose which one you want i think.

obsidian chasm
#

oh nice, will try that

#

it strangely only crashes with other players

#

maybe it crashes everyone if 1 player does not have the sprite

austere dock
#

it crash the server if the hoster doesnt have the sprite files for it or doesnt register it the way i explained that. they'll directly either send back to the menu or crashed like that. usually the hoster's game will crash while the other players that play the server will be sent back to the menu.

obsidian chasm
#

mmm i just tried the precache, without the files and still crashes. I guess I'll have to wing it since it probably needs both precache and files to not crash

austere dock
#

try change PrecacheGeneric to PrecacheModel , if it's still broken, i'm not sure.

obsidian chasm
#

ah wait, now it works, with the second method, the one from the svd

austere dock
#

Yeah, i think should use PrecacheModel instead for that sprites.

obsidian chasm
#

Thanks, I will keep this in mind next time I use cso wepaons

quartz forge
#

how do i get them in game

austere dock
# quartz forge how do i get them in game
  1. Download the plugin repo in the github (the one with green highlight stating "Code", and choose Download Zip option)
  2. Once the files done downloading, extract the files in your Sven Co-op/svencoop_addon folder.
  3. Afterwards, go to Sven Co-op/svencoop folder, find a file called default_plugins.txt, then write this inside it:
    "plugin"
{
    "name" "Counter-Strike: Online Weapons"
    "script" "custom_weapons-cso"
}
  1. Then open your game, open any map you want to play. you can spawn any of the weapons inside the console by writing give weapon_<insert weapon name based on its code classname here> and it will spawn you the weapon you want.

Side note:

  • This plugin doesn't run any BuyMenu plugin as Nero0 just create only the weapons only. You can run BuyMenu script if you know how scripting works and you can also check how the guide to include them inside BuyMenu with weapons in that github installation guide that Nero stated.
  • If you don't have any default_plugins.txt, you can make your own default_plugins.txt by basically create a new one of your own.
quartz forge
#

i'll try it, thanks.

stuck crow
#

You can run BuyMenu script if you know how scripting works and you can also check how the guide to include them inside BuyMenu with weapons in that github installation guide that Nero stated.
or you can just use Ecco instead, if you don't know/want to learn how to make your BuyMenu script

quartz forge
#

why do they replace custom ammo instead of vanilla?

austere dock
#

iirc Nero code almost all CSO weapons here to use vanilla/sven default ammo instead of using custom one like Insurgency weapons, CoF weapons and CS16 weapons.

stuck crow
#

well, you can just replace these custom ammos with vanilla

austere dock
#

yeah, you can do that as well. usually it has its own ammo type name. check on the void Register() function in each weapons script and you can see there's line something like:

g_ItemRegistry.RegisterWeapon( "<insert weapon classname here>", "<insert weapon's sprite file path>", "<insert primary ammo type here>", "<insert secondary ammo type here if exists>", "<insert primary ammo string (optional)>", "<insert secondary ammo string (optional)>" );

or something like that, you can change the primary ammo type of the gun.
List of Half-Life/Sven Co-op default hardcoded weapons ammo type:

medkit
9mm
buckshot
357
bolts
556
ARgrenades
rockets
uranium
Hand Grenade
Snarks
m40a1
Satchel Charge
Trip Mine
hornet
sporeclip

for example here (this is my version):

g_ItemRegistry.RegisterWeapon( "weapon_svdex", "custom_weapons/cso", "556", "ARgrenades", "ammo_556clip", "ammo_ARgrenades" );
austere dock
#

code this using Nero's base code. I hope Nero come back to this project at some point.

stuck crow
digital night
#

Fitsma on my server found a strange issue with the failnaught bow. When you charge it up it causes the client to have their ping go up to 500 because it attempts to render sprites for every enemy in the direction it is looking, even through walls. Then the weapon gets stuck in alt fire charge up mode and will not fire.

#

yeah i can replicate it

obsidian chasm
stuck crow
#

he left the discord afaik, he's now chilling in reddit

obsidian chasm
#

cmon man why

stuck crow
#

dunno, guess here's so much cunts

austere dock
main mason
#

Nero needs to come back to discord, right now

austere dock
#

me hope he will come back too

#

πŸ€‘

obsidian chasm
austere dock
#

damage done by a traceline currently, not sure if i should create Radius Damage for it as well

obsidian chasm
#

when i made the richard boderbot shock rifle i used an invisible explosion at the hit area for splash damage :P, might go with the idea of that gun too

obsidian chasm
#

deleted user 😒 sven has lost an elite member

stuck crow
#

*sven discord

#

but not the sven itself

#

he's still active in reddit

obsidian chasm
#

Why did he leave? Makes no sense

#

One would think leaving here is leaving the game

atomic magnet
obsidian chasm
#

ok so its a beef with discord xd

obsidian chasm
#

Nero needs some help finding out how we can open this to make these sprites work with goldsrc. I think they are like a specific .spr file version for CSO that no tools that we have (or that i know of) can open. Any ideas?

unreal cove
#

interesting

#

you need to slowhack the thing

mint heron
#

i believe i got it

#

through some hex editing and noesis fuckery

#

kinda late to the party tho xd

#

couldn't open it as a .spr in any way, every traditional sprite related software just throws a tantrum

but i opened it in HxD, copied and pasted some stuff into a new file with the .dds extension

#

and there it is, i was able to open the .dds file with noesis

#

exporting as .spr, the problem persists, i can't open it with anything. but the image itself can be exported

#

sprites aren't my fortΓ© but at least a proper .spr could be made from the image, kinda painful if there's too many sprites that need to have this procedure done

obsidian chasm
#

Hey thats a bit complicated but if it works its an alternative

#

A guy is making a tool that can do this automatically πŸ™‚

mint heron
#

unfortunately i wasn't able to open the file in a more simple way πŸ™

mint heron
obsidian chasm
#

Doing this for hundreds of sprites is a nono i think xd

mint heron
#

absolutely catlaugh

obsidian chasm
#

So whats the step by step? Get HxD and then?

#

I'll send it to nero

mint heron
#

gimme a moment i'll write down the steps

#

do you have any other CSO sprite at hand? so i can verify this works with all spr from that game

#

nah fuck it i'll download the game and check, don't worry

#
  1. open muzzleflash207.spr with HxD
  2. in the column "Decoded Text", select everything from the start of "DDS" to the end of the file and copy
#
  1. still in HxD, go to File -> New (or CTRL+N) to open a new tab
  2. paste what you copied previously, it should look like this
  3. File -> save as -> save it as muzzleflash207**.dds**
#
  1. open Noesis, go to File -> open file and open the previously saved .dds file and there it will show the image that's inside the thing
#

from there, right click the file -> export

#

you'll get this window where you can choose various formats

mint heron
obsidian chasm
#

Ok this is great man, massive bro

mint heron
#

the program allows to export it as .spr but it still won't be able to be opened with traditional spr software

#

it's not a hard process but as we were saying before, if there are too many files that need to have this done, it can be painful

mint heron
obsidian chasm
#

Ill send this to nero thanks

#

The game files are in pak and nar files

#

You need any pak explorer. But the nar files need the nar tools

#

But. The bastards have yet another version of pak or something in the latest updates. So you need the leaked cso tool we shared. Cant find it now

#

Maybe we should upload the entire extracted files somewhere hehe

obsidian chasm
#

nero has received the guide, thanks

mint heron
#

anytime Garompa yes

graceful cedar
#

a lot of weapons seem to crash my game due to stuff like models n sprite not being precached

obsidian chasm
#

when maps are packed, resguy doesn't detect some of the files because nero used a lot of alias methods instead of direct links to the files

#

in short, instead of
PrecacheModel ("sprites/whatever.spr")

he used something like this:
SPRITE_WHATEVER = "sprites/whatever.spr"
PrecacheModel (SPRITE_WHATEVER)

and so resguy can't find the precache file. Even worse, he has done things like this:
SPRITE_WHATEVER = "sprites/" + WHATEVER + ".spr"
WHATEVER = whatever

#

It is a good practice, for coding, but bad for this current specific case of this game and its packing. Imagine now that you have a hundred guns with scripts like this. It would be a nightmare to create a .res file for it manually, so you use a tool. But that tool can't read this, i don't believe any tool would be able to or well, maybe the author could make a miracle. I'll point it out to him in case he is willing

visual kettle
# graceful cedar a lot of weapons seem to crash my game due to stuff like models n sprite not bei...

It has to do with some of the weapon brass/clip eject using a default model that may be replaced by GMR and unprecached, like the w_9mmclip, laserbeam and shotgunshell are using default provided model. You can fix this by copying them as distinct file in another path and use that, so GMR won't be involved.
For example, this is AOM gmr settings that could crash multiple unmodified cso on shoot/reload.

obsidian chasm
# visual kettle It has to do with some of the weapon brass/clip eject using a default model that...

are you sure? i dont remember gmr crashing the game.

  • gmr precaches both models (original and replace)
  • if model does not appear ingame nothing happens
  • if a script precaches it, nothing happens

all I can think of is what i said above, that the script precaches the thing but the repacker does not detect aliases, so there may be maps that come with scripts that are missing files and you would never detect them

visual kettle
#

That is in singleplayer case, GMR doesn't precache both in server setup, it is why GMR last change do not allow replacing "sprites/error.spr", "models/error.mdl" and "models/player.mdl". It doesn't have anything to do with how string defined in the script itself.

#

There's a way to fix this GMR mess, either you have your own common files to use for your plugins only to avoid GMR stuff, or request a fix to the devs on how Plugin script execution should be prioritized last after Map script, this was noticeable when plugin from MapInit was called first then MapInit from map-scripts later. It is unusual behavior tho so far, only @tardy minnow has reported this finding before.

obsidian chasm
#

I still dont understand. So im guessing. So, you are saying that if the script uses a default clip model, and you have a gmr replacing it... but the map you play does not have the entity that uses that model so the precache is not made there but instead only made by the script so the gmr precache is ignored?, then the game crashes

#

This means you cant gmr any script precached model?

visual kettle
#

No its the reverse, while GMR has rules what models/sprites/sounds is unreplaceable (most of it we're sounds) some like lazerbeam.spr and w_9mmclip that used in brass/clip eject sequence Nero CSO uses will not be precached since the modelindex are replaced. To avoid this just duplicate it in different folder "models/cso/common/[default_provided_sprite/mdl]" to avoid GMR do stuff to what your weapon needed from vanilla files. I took care a server that uses nero weapons, and they have the most heaviest maplist that aggresively uses GMR because of classic concept of the server, so this is a headache when it happens.

tardy minnow
#

I made a fix for this in metamod

#

They have the list of precaches there and doesnt try to check if valid, i had to hook some methods just to set error mdl/spr to everything that is missing

visual kettle
#

That would be nice, since I can only assume how it happen, I believe if the plugin and map script execution was reversed where map is first and plugin second, this GMR stuff won't happen since logically GMR parsing execution would happen at the same scope within Map execution priority.

obsidian chasm
#

Oh so this is a plugin issue

#

In servers

#

Sorry its just hard to read you

#

I was keeping an eye out in case this happens with cso map scripts, not the plugin version

#

Since i am replacing 9mmclip in one

#

Would adding them to a custom_precache entity also work?

tardy minnow
#

I strongly believe map scripts had priority in before

obsidian chasm
#

@visual kettle btw are you from gamesaba? (cause of the saba thing)

obsidian chasm
#

What about doing this. Would this help?

{
"origin" "180 -4606 2680"
"classname" "custom_precache"
"netname" "anticrash_for_csoscript_1"
"model_1" "models/hornet.mdl"
"model_2" "models/w_medkit.mdl"
"model_3" "models/w_battery.mdl"
"model_4" "models/w_9mmclip.mdl"
"model_6" "models/w_357ammo.mdl"
"model_7" "models/w_357ammobox.mdl"
"model_5" "models/w_9mmarclip.mdl"
"model_8" "sprites/bigspit.spr"
"model_9" "sprites/blood.spr"
}
{
"origin" "180 -4584 2680"
"classname" "custom_precache"
"netname" "anticrash_for_csoscript_2"
"model_1" "sprites/tinyspit.spr"
"model_2" "sprites/mommspit.spr"
"model_4" "sprites/shockwave.spr"
"model_5" "sprites/laserbeam.spr"
"model_3" "sprites/mommspout.spr"
"model_6" "sprites/muz1.spr"
"model_7" "sprites/muz4.spr"
"model_8" "sprites/muz8.spr"
"model_9" "sprites/xspark4.spr"
}

tardy minnow
#

How is it used anyways

#

If the weapon gets the model by using precache its a bad design

#

CModelFuncs i think it was? Has a Get by ID method, though ideally the id would be a variable set once

visual kettle
# obsidian chasm What about doing this. Would this help? > { > "origin" "180 -4606 2680" > "clas...

No thats a bit to overkill, the screenshot I send was just gmr example of AOM Classic, replacing 9mmclip and laserbeam that was used for clip eject and traceline effect in certain weapon (M95 Tiger, AUG EX GL, etc.), and doing that wouldn't help either as GMR would replace them as well. Here's a screenshot example of what nero CSO's weapon uses for certain sequences that often get replaced by bunch's of map's GMR that I duplicate as its own common files.

obsidian chasm
#

so we precache those and the models that are replaced with using gmr, in the custom precache. what about then?