AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   [Orpheu] Problem with signature. (https://forums.alliedmods.net/showthread.php?t=146709)

Owner123 12-31-2010 05:06

[Orpheu] Problem with signature.
 
Can anyone help me to write correct this sig ? :
Code:

{
    "name" : "PlaybackEvent",
    "library" : "engine",
    "arguments" :
    [
        {
            "type" : "int"
        },
        {
            "type" : "edict_t *"
        },
        {
            "type" : "unsigned short"
        },
        {
            "type" : "float"
        },
        {
            "type" : "float"
        },
        {
            "type" : "float"
        },
        {
            "type" : "float"
        },
        {
            "type" : "float"
        },
        {
            "type" : "int"
        },
        {
            "type" : "int"
        },
        {
            "type" : "int"
        },
        {
            "type" : "int"
        }
    ]
}


Arkshine 12-31-2010 06:41

Re: [Orpheu] Problem with signature.
 
Replace unsigned short by int, it should work.

By the way, unless you have a specific reason to use it, it exists already in fakemeta.

Owner123 12-31-2010 06:46

Re: [Orpheu] Problem with signature.
 
But in fakemeta this is executed after this. I want to block this function for fire sounds.
BTW. Dont work.
I get this error:
Quote:

L 12/31/2010 - 12:49:52: [ORPHEU] Invalid function structure "PlaybackEvent"
L 12/31/2010 - 12:49:52: [AMXX] Displaying debug trace (plugin "orpheu_block.amxx")
L 12/31/2010 - 12:49:52: [AMXX] Run time error 10: native error (native "OrpheuCreateFunction")
L 12/31/2010 - 12:49:52: [AMXX] [0] orpheu_stocks.inc::OrpheuGetEngineFunction (line 34)
L 12/31/2010 - 12:49:52: [AMXX] [1] orpheu_block.sma::plugin_init (line 10)

Arkshine 12-31-2010 07:03

Re: [Orpheu] Problem with signature.
 
Change also edict_t * to edict_s *

By the way, FM_* are just wrappers to engine calls, so it's the same and you can't block fire sound because there are played client side.

Owner123 12-31-2010 07:34

Re: [Orpheu] Problem with signature.
 
I know, block fire sounds is possible because i play on server which block this sounds :S

This still dont work.

Arkshine 12-31-2010 08:15

Re: [Orpheu] Problem with signature.
 
No that's not possible. You can block the whole weapon and make your own weapon + sounds etc, but for the default weapon you can't block just the sounds because played client-side and so unhookable.

If you replace unsigned short -> int and edict_t -> edict_s, the sig works and the forward well called, but superceding will do nothing.

Owner123 12-31-2010 08:32

Re: [Orpheu] Problem with signature.
 
Hmmm, but i have plugin which changing weapon models etc. but when i want play custom fire sound, old sound play too. I want to block thats old fire sounds.

What about sig, I still have error which I post up.

Arkshine 12-31-2010 08:35

Re: [Orpheu] Problem with signature.
 
You have no choice to redo the whole weapon if you want custom sounds and such.

Owner123 12-31-2010 08:58

Re: [Orpheu] Problem with signature.
 
Ehh, thanks for info.


All times are GMT -4. The time now is 01:57.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.