Re: [hlcoders] Getting commands in an alias (autoexec.cfg)

2010-04-10 Thread Janek
Hi all,

First of all, I'd like to thank you for your help as now I know how to
address my problem even if the solution is very different from what I was
imagining at the beginning.

Look at the way this thread was moving:

- First I asked for a solution allowing me to hook commands sent to the
engine after it has been explored meaning that for an alias commands inside
it must be exploded before being sent to the engine. The answer sounds to be
that it is not possible as the command (including alias and script) is sent
to the engine in its raw form as it is analysed (exploded) by the engine
itself.

- Second, as the first solution was not possible I asked a way to get an
access to the list of aliases (alias name and relevant commands) which is
obviously somewhere in memory. There had no real answer: no way were given
to directly access this list

- Third, there had this way to hook alias command proposed by both Sergi and
Skillet (with this very good piece of code, thank you very much Skillet for
making this part a reality). The problem is that it is hooking "alias" when
"alias" command is executed but not when an alias is executed. BUT the good
news is that using this hook I can manage my own alias list which was my
second idea so finally it is good to me.

Interesting to see how such a subject can drive you to something you were
not imagining.

Thank you agaon for your very appreciated help.

Cheers,

J.

2010/4/9 Skillet 

> Yep, I just added a couple of functions to the ConCommand class in tier1
> for
> accessing m_fnCommandCallback.
> http://hlcoders.pastebin.com/MB749bGE
>
> On Fri, Apr 9, 2010 at 1:34 PM, Tony "omega" Sergi  >wrote:
>
> > You have the source to tier1 and can rebuild it. It's a lib, not a dll.
> > You could add additional functionality to it.
> >
> > For example; one thing that I did in an orange box mod was add the
> ability
> > to unregister console commands, so that I could replace them with my own.
> > -Tony
> >
> >
> > On Sat, Apr 10, 2010 at 2:08 AM, Janek  wrote:
> >
> > > Looking at this if 0 it seems you 're right. But we should have a way
> to
> > > access this alias list or being able to handle it. I'm crossing my
> > fingers.
> > > I think, only Valve can answer.
> > >
> > > J.
> > >
> > > 2010/4/9 Olly 
> > >
> > > > Looks like all of this has been moved from Tier1/commandbuffer.cpp
> into
> > > the
> > > > engine. Doesn't look like there is a way to access aliases from
> outside
> > > the
> > > > engine.
> > > >
> > > > On 9 April 2010 16:35, Janek  wrote:
> > > >
> > > > > From what I understand, alias list is stored in memory bu I don't
> > know
> > > > how
> > > > > to get access to this list. Is there anybody (even in Valve
> Software)
> > > to
> > > > > explain how to access it ?
> > > > >
> > > > > J.
> > > > >
> > > > > 2010/4/9 Janek 
> > > > >
> > > > > > In fact I found this InstallGlobalChangeCallback but can't use it
> > coz
> > > > I'm
> > > > > > not able to get this alias as a ConCommand. There's probably
> > > somethiing
> > > > > > different to a standard ConCommand.
> > > > > >
> > > > > > J.
> > > > > >
> > > > > > 2010/4/9 Janek 
> > > > > >
> > > > > > I try to find where this callback could be hook for any alias but
> > > > didn't
> > > > > >> succeed ;-( Still searching.
> > > > > >>
> > > > > >> 2010/4/9 Skillet 
> > > > > >>
> > > > > >> I don't know if checking at "runtime" whether commands are being
> > > > > executed
> > > > > >>> in
> > > > > >>> a batch as an alias command is possible but it certainly is
> > > possible
> > > > to
> > > > > >>> change the callback for the engine alias ConCommand so you can
> > > check
> > > > > the
> > > > > >>> contents before it is fed to the engine.  If you're trying to
> > > > disallow
> > > > > >>> the
> > > > > >>> use of particular primitive commands in aliases, that's the way
> > to
> > > > go.
> > > > > >>>
> > > > > >>> On Thu, Apr 8, 2010 at 4:41 PM, Janek 
> wrote:
> > > > > >>>
> > > > > >>> > Hi,
> > > > > >>> >
> > > > > >>> > In Source, you can write alias in autoexec.cfg file ala :
> alias
> > > > > >>> > "name_of_alias" "cmd1; cmd2; cmd3".
> > > > > >>> >
> > > > > >>> > I'd like to be able to check each command in the alias when
> > this
> > > > > alias
> > > > > >>> is
> > > > > >>> > executed. I thought it was possible by studying
> > pszCurrentBinding
> > > > in
> > > > > >>> int
> > > > > >>> > CInput::KeyEvent( int down, ButtonCode_t code, const char
> > > > > >>> > *pszCurrentBinding
> > > > > >>> > ) in in_main.cpp but it failt as pszCurrentBinding is
> > containing
> > > > the
> > > > > >>> alias
> > > > > >>> > "name_of_alias" and not the primitive command.
> > > > > >>> > As it is returning 1, it is up to the engine to process this
> > > > command.
> > > > > I
> > > > > >>> > imagine that the engine is able to properly parse the
> primitive
> > > > > >>> commands.
> > > > > >>> > I'd like to know if there is an other location to get these
> > > > primitive
> > > > > >>> > command

Re: [hlcoders] Getting commands in an alias (autoexec.cfg)

2010-04-09 Thread Skillet
Yep, I just added a couple of functions to the ConCommand class in tier1 for
accessing m_fnCommandCallback.
http://hlcoders.pastebin.com/MB749bGE

On Fri, Apr 9, 2010 at 1:34 PM, Tony "omega" Sergi wrote:

> You have the source to tier1 and can rebuild it. It's a lib, not a dll.
> You could add additional functionality to it.
>
> For example; one thing that I did in an orange box mod was add the ability
> to unregister console commands, so that I could replace them with my own.
> -Tony
>
>
> On Sat, Apr 10, 2010 at 2:08 AM, Janek  wrote:
>
> > Looking at this if 0 it seems you 're right. But we should have a way to
> > access this alias list or being able to handle it. I'm crossing my
> fingers.
> > I think, only Valve can answer.
> >
> > J.
> >
> > 2010/4/9 Olly 
> >
> > > Looks like all of this has been moved from Tier1/commandbuffer.cpp into
> > the
> > > engine. Doesn't look like there is a way to access aliases from outside
> > the
> > > engine.
> > >
> > > On 9 April 2010 16:35, Janek  wrote:
> > >
> > > > From what I understand, alias list is stored in memory bu I don't
> know
> > > how
> > > > to get access to this list. Is there anybody (even in Valve Software)
> > to
> > > > explain how to access it ?
> > > >
> > > > J.
> > > >
> > > > 2010/4/9 Janek 
> > > >
> > > > > In fact I found this InstallGlobalChangeCallback but can't use it
> coz
> > > I'm
> > > > > not able to get this alias as a ConCommand. There's probably
> > somethiing
> > > > > different to a standard ConCommand.
> > > > >
> > > > > J.
> > > > >
> > > > > 2010/4/9 Janek 
> > > > >
> > > > > I try to find where this callback could be hook for any alias but
> > > didn't
> > > > >> succeed ;-( Still searching.
> > > > >>
> > > > >> 2010/4/9 Skillet 
> > > > >>
> > > > >> I don't know if checking at "runtime" whether commands are being
> > > > executed
> > > > >>> in
> > > > >>> a batch as an alias command is possible but it certainly is
> > possible
> > > to
> > > > >>> change the callback for the engine alias ConCommand so you can
> > check
> > > > the
> > > > >>> contents before it is fed to the engine.  If you're trying to
> > > disallow
> > > > >>> the
> > > > >>> use of particular primitive commands in aliases, that's the way
> to
> > > go.
> > > > >>>
> > > > >>> On Thu, Apr 8, 2010 at 4:41 PM, Janek  wrote:
> > > > >>>
> > > > >>> > Hi,
> > > > >>> >
> > > > >>> > In Source, you can write alias in autoexec.cfg file ala : alias
> > > > >>> > "name_of_alias" "cmd1; cmd2; cmd3".
> > > > >>> >
> > > > >>> > I'd like to be able to check each command in the alias when
> this
> > > > alias
> > > > >>> is
> > > > >>> > executed. I thought it was possible by studying
> pszCurrentBinding
> > > in
> > > > >>> int
> > > > >>> > CInput::KeyEvent( int down, ButtonCode_t code, const char
> > > > >>> > *pszCurrentBinding
> > > > >>> > ) in in_main.cpp but it failt as pszCurrentBinding is
> containing
> > > the
> > > > >>> alias
> > > > >>> > "name_of_alias" and not the primitive command.
> > > > >>> > As it is returning 1, it is up to the engine to process this
> > > command.
> > > > I
> > > > >>> > imagine that the engine is able to properly parse the primitive
> > > > >>> commands.
> > > > >>> > I'd like to know if there is an other location to get these
> > > primitive
> > > > >>> > commands. How would you proceed ?
> > > > >>> >
> > > > >>> > Thank you in advance for your help.
> > > > >>> >
> > > > >>> > ---
> > > > >>> > j...@nek
> > > > >>> > ___
> > > > >>> > To unsubscribe, edit your list preferences, or view the list
> > > > archives,
> > > > >>> > please visit:
> > > > >>> > http://list.valvesoftware.com/mailman/listinfo/hlcoders
> > > > >>> >
> > > > >>> >
> > > > >>> ___
> > > > >>> To unsubscribe, edit your list preferences, or view the list
> > > archives,
> > > > >>> please visit:
> > > > >>> http://list.valvesoftware.com/mailman/listinfo/hlcoders
> > > > >>>
> > > > >>>
> > > > >>
> > > > >>
> > > > >> --
> > > > >> ---
> > > > >> j...@nek
> > > > >>
> > > > >
> > > > >
> > > > >
> > > > > --
> > > > > ---
> > > > > j...@nek
> > > > >
> > > >
> > > >
> > > >
> > > > --
> > > > ---
> > > > j...@nek
> > > > ___
> > > > To unsubscribe, edit your list preferences, or view the list
> archives,
> > > > please visit:
> > > > http://list.valvesoftware.com/mailman/listinfo/hlcoders
> > > >
> > > >
> > > ___
> > > To unsubscribe, edit your list preferences, or view the list archives,
> > > please visit:
> > > http://list.valvesoftware.com/mailman/listinfo/hlcoders
> > >
> > >
> >
> >
> > --
> > ---
> > j...@nek
> > ___
> > To unsubscribe, edit your list preferences, or view the list archives,
> > please visit:
> > http://list.valvesoftware.c

Re: [hlcoders] Getting commands in an alias (autoexec.cfg)

2010-04-09 Thread Tony "omega" Sergi
You have the source to tier1 and can rebuild it. It's a lib, not a dll.
You could add additional functionality to it.

For example; one thing that I did in an orange box mod was add the ability
to unregister console commands, so that I could replace them with my own.
-Tony


On Sat, Apr 10, 2010 at 2:08 AM, Janek  wrote:

> Looking at this if 0 it seems you 're right. But we should have a way to
> access this alias list or being able to handle it. I'm crossing my fingers.
> I think, only Valve can answer.
>
> J.
>
> 2010/4/9 Olly 
>
> > Looks like all of this has been moved from Tier1/commandbuffer.cpp into
> the
> > engine. Doesn't look like there is a way to access aliases from outside
> the
> > engine.
> >
> > On 9 April 2010 16:35, Janek  wrote:
> >
> > > From what I understand, alias list is stored in memory bu I don't know
> > how
> > > to get access to this list. Is there anybody (even in Valve Software)
> to
> > > explain how to access it ?
> > >
> > > J.
> > >
> > > 2010/4/9 Janek 
> > >
> > > > In fact I found this InstallGlobalChangeCallback but can't use it coz
> > I'm
> > > > not able to get this alias as a ConCommand. There's probably
> somethiing
> > > > different to a standard ConCommand.
> > > >
> > > > J.
> > > >
> > > > 2010/4/9 Janek 
> > > >
> > > > I try to find where this callback could be hook for any alias but
> > didn't
> > > >> succeed ;-( Still searching.
> > > >>
> > > >> 2010/4/9 Skillet 
> > > >>
> > > >> I don't know if checking at "runtime" whether commands are being
> > > executed
> > > >>> in
> > > >>> a batch as an alias command is possible but it certainly is
> possible
> > to
> > > >>> change the callback for the engine alias ConCommand so you can
> check
> > > the
> > > >>> contents before it is fed to the engine.  If you're trying to
> > disallow
> > > >>> the
> > > >>> use of particular primitive commands in aliases, that's the way to
> > go.
> > > >>>
> > > >>> On Thu, Apr 8, 2010 at 4:41 PM, Janek  wrote:
> > > >>>
> > > >>> > Hi,
> > > >>> >
> > > >>> > In Source, you can write alias in autoexec.cfg file ala : alias
> > > >>> > "name_of_alias" "cmd1; cmd2; cmd3".
> > > >>> >
> > > >>> > I'd like to be able to check each command in the alias when this
> > > alias
> > > >>> is
> > > >>> > executed. I thought it was possible by studying pszCurrentBinding
> > in
> > > >>> int
> > > >>> > CInput::KeyEvent( int down, ButtonCode_t code, const char
> > > >>> > *pszCurrentBinding
> > > >>> > ) in in_main.cpp but it failt as pszCurrentBinding is containing
> > the
> > > >>> alias
> > > >>> > "name_of_alias" and not the primitive command.
> > > >>> > As it is returning 1, it is up to the engine to process this
> > command.
> > > I
> > > >>> > imagine that the engine is able to properly parse the primitive
> > > >>> commands.
> > > >>> > I'd like to know if there is an other location to get these
> > primitive
> > > >>> > commands. How would you proceed ?
> > > >>> >
> > > >>> > Thank you in advance for your help.
> > > >>> >
> > > >>> > ---
> > > >>> > j...@nek
> > > >>> > ___
> > > >>> > To unsubscribe, edit your list preferences, or view the list
> > > archives,
> > > >>> > please visit:
> > > >>> > http://list.valvesoftware.com/mailman/listinfo/hlcoders
> > > >>> >
> > > >>> >
> > > >>> ___
> > > >>> To unsubscribe, edit your list preferences, or view the list
> > archives,
> > > >>> please visit:
> > > >>> http://list.valvesoftware.com/mailman/listinfo/hlcoders
> > > >>>
> > > >>>
> > > >>
> > > >>
> > > >> --
> > > >> ---
> > > >> j...@nek
> > > >>
> > > >
> > > >
> > > >
> > > > --
> > > > ---
> > > > j...@nek
> > > >
> > >
> > >
> > >
> > > --
> > > ---
> > > j...@nek
> > > ___
> > > To unsubscribe, edit your list preferences, or view the list archives,
> > > please visit:
> > > http://list.valvesoftware.com/mailman/listinfo/hlcoders
> > >
> > >
> > ___
> > To unsubscribe, edit your list preferences, or view the list archives,
> > please visit:
> > http://list.valvesoftware.com/mailman/listinfo/hlcoders
> >
> >
>
>
> --
> ---
> j...@nek
> ___
> To unsubscribe, edit your list preferences, or view the list archives,
> please visit:
> http://list.valvesoftware.com/mailman/listinfo/hlcoders
>
>


-- 
-Tony
___
To unsubscribe, edit your list preferences, or view the list archives, please 
visit:
http://list.valvesoftware.com/mailman/listinfo/hlcoders



Re: [hlcoders] Getting commands in an alias (autoexec.cfg)

2010-04-09 Thread Janek
Looking at this if 0 it seems you 're right. But we should have a way to
access this alias list or being able to handle it. I'm crossing my fingers.
I think, only Valve can answer.

J.

2010/4/9 Olly 

> Looks like all of this has been moved from Tier1/commandbuffer.cpp into the
> engine. Doesn't look like there is a way to access aliases from outside the
> engine.
>
> On 9 April 2010 16:35, Janek  wrote:
>
> > From what I understand, alias list is stored in memory bu I don't know
> how
> > to get access to this list. Is there anybody (even in Valve Software) to
> > explain how to access it ?
> >
> > J.
> >
> > 2010/4/9 Janek 
> >
> > > In fact I found this InstallGlobalChangeCallback but can't use it coz
> I'm
> > > not able to get this alias as a ConCommand. There's probably somethiing
> > > different to a standard ConCommand.
> > >
> > > J.
> > >
> > > 2010/4/9 Janek 
> > >
> > > I try to find where this callback could be hook for any alias but
> didn't
> > >> succeed ;-( Still searching.
> > >>
> > >> 2010/4/9 Skillet 
> > >>
> > >> I don't know if checking at "runtime" whether commands are being
> > executed
> > >>> in
> > >>> a batch as an alias command is possible but it certainly is possible
> to
> > >>> change the callback for the engine alias ConCommand so you can check
> > the
> > >>> contents before it is fed to the engine.  If you're trying to
> disallow
> > >>> the
> > >>> use of particular primitive commands in aliases, that's the way to
> go.
> > >>>
> > >>> On Thu, Apr 8, 2010 at 4:41 PM, Janek  wrote:
> > >>>
> > >>> > Hi,
> > >>> >
> > >>> > In Source, you can write alias in autoexec.cfg file ala : alias
> > >>> > "name_of_alias" "cmd1; cmd2; cmd3".
> > >>> >
> > >>> > I'd like to be able to check each command in the alias when this
> > alias
> > >>> is
> > >>> > executed. I thought it was possible by studying pszCurrentBinding
> in
> > >>> int
> > >>> > CInput::KeyEvent( int down, ButtonCode_t code, const char
> > >>> > *pszCurrentBinding
> > >>> > ) in in_main.cpp but it failt as pszCurrentBinding is containing
> the
> > >>> alias
> > >>> > "name_of_alias" and not the primitive command.
> > >>> > As it is returning 1, it is up to the engine to process this
> command.
> > I
> > >>> > imagine that the engine is able to properly parse the primitive
> > >>> commands.
> > >>> > I'd like to know if there is an other location to get these
> primitive
> > >>> > commands. How would you proceed ?
> > >>> >
> > >>> > Thank you in advance for your help.
> > >>> >
> > >>> > ---
> > >>> > j...@nek
> > >>> > ___
> > >>> > To unsubscribe, edit your list preferences, or view the list
> > archives,
> > >>> > please visit:
> > >>> > http://list.valvesoftware.com/mailman/listinfo/hlcoders
> > >>> >
> > >>> >
> > >>> ___
> > >>> To unsubscribe, edit your list preferences, or view the list
> archives,
> > >>> please visit:
> > >>> http://list.valvesoftware.com/mailman/listinfo/hlcoders
> > >>>
> > >>>
> > >>
> > >>
> > >> --
> > >> ---
> > >> j...@nek
> > >>
> > >
> > >
> > >
> > > --
> > > ---
> > > j...@nek
> > >
> >
> >
> >
> > --
> > ---
> > j...@nek
> > ___
> > To unsubscribe, edit your list preferences, or view the list archives,
> > please visit:
> > http://list.valvesoftware.com/mailman/listinfo/hlcoders
> >
> >
> ___
> To unsubscribe, edit your list preferences, or view the list archives,
> please visit:
> http://list.valvesoftware.com/mailman/listinfo/hlcoders
>
>


-- 
---
j...@nek
___
To unsubscribe, edit your list preferences, or view the list archives, please 
visit:
http://list.valvesoftware.com/mailman/listinfo/hlcoders



Re: [hlcoders] Getting commands in an alias (autoexec.cfg)

2010-04-09 Thread Olly
Looks like all of this has been moved from Tier1/commandbuffer.cpp into the
engine. Doesn't look like there is a way to access aliases from outside the
engine.

On 9 April 2010 16:35, Janek  wrote:

> From what I understand, alias list is stored in memory bu I don't know how
> to get access to this list. Is there anybody (even in Valve Software) to
> explain how to access it ?
>
> J.
>
> 2010/4/9 Janek 
>
> > In fact I found this InstallGlobalChangeCallback but can't use it coz I'm
> > not able to get this alias as a ConCommand. There's probably somethiing
> > different to a standard ConCommand.
> >
> > J.
> >
> > 2010/4/9 Janek 
> >
> > I try to find where this callback could be hook for any alias but didn't
> >> succeed ;-( Still searching.
> >>
> >> 2010/4/9 Skillet 
> >>
> >> I don't know if checking at "runtime" whether commands are being
> executed
> >>> in
> >>> a batch as an alias command is possible but it certainly is possible to
> >>> change the callback for the engine alias ConCommand so you can check
> the
> >>> contents before it is fed to the engine.  If you're trying to disallow
> >>> the
> >>> use of particular primitive commands in aliases, that's the way to go.
> >>>
> >>> On Thu, Apr 8, 2010 at 4:41 PM, Janek  wrote:
> >>>
> >>> > Hi,
> >>> >
> >>> > In Source, you can write alias in autoexec.cfg file ala : alias
> >>> > "name_of_alias" "cmd1; cmd2; cmd3".
> >>> >
> >>> > I'd like to be able to check each command in the alias when this
> alias
> >>> is
> >>> > executed. I thought it was possible by studying pszCurrentBinding in
> >>> int
> >>> > CInput::KeyEvent( int down, ButtonCode_t code, const char
> >>> > *pszCurrentBinding
> >>> > ) in in_main.cpp but it failt as pszCurrentBinding is containing the
> >>> alias
> >>> > "name_of_alias" and not the primitive command.
> >>> > As it is returning 1, it is up to the engine to process this command.
> I
> >>> > imagine that the engine is able to properly parse the primitive
> >>> commands.
> >>> > I'd like to know if there is an other location to get these primitive
> >>> > commands. How would you proceed ?
> >>> >
> >>> > Thank you in advance for your help.
> >>> >
> >>> > ---
> >>> > j...@nek
> >>> > ___
> >>> > To unsubscribe, edit your list preferences, or view the list
> archives,
> >>> > please visit:
> >>> > http://list.valvesoftware.com/mailman/listinfo/hlcoders
> >>> >
> >>> >
> >>> ___
> >>> To unsubscribe, edit your list preferences, or view the list archives,
> >>> please visit:
> >>> http://list.valvesoftware.com/mailman/listinfo/hlcoders
> >>>
> >>>
> >>
> >>
> >> --
> >> ---
> >> j...@nek
> >>
> >
> >
> >
> > --
> > ---
> > j...@nek
> >
>
>
>
> --
> ---
> j...@nek
> ___
> To unsubscribe, edit your list preferences, or view the list archives,
> please visit:
> http://list.valvesoftware.com/mailman/listinfo/hlcoders
>
>
___
To unsubscribe, edit your list preferences, or view the list archives, please 
visit:
http://list.valvesoftware.com/mailman/listinfo/hlcoders



Re: [hlcoders] Getting commands in an alias (autoexec.cfg)

2010-04-09 Thread Janek
>From what I understand, alias list is stored in memory bu I don't know how
to get access to this list. Is there anybody (even in Valve Software) to
explain how to access it ?

J.

2010/4/9 Janek 

> In fact I found this InstallGlobalChangeCallback but can't use it coz I'm
> not able to get this alias as a ConCommand. There's probably somethiing
> different to a standard ConCommand.
>
> J.
>
> 2010/4/9 Janek 
>
> I try to find where this callback could be hook for any alias but didn't
>> succeed ;-( Still searching.
>>
>> 2010/4/9 Skillet 
>>
>> I don't know if checking at "runtime" whether commands are being executed
>>> in
>>> a batch as an alias command is possible but it certainly is possible to
>>> change the callback for the engine alias ConCommand so you can check the
>>> contents before it is fed to the engine.  If you're trying to disallow
>>> the
>>> use of particular primitive commands in aliases, that's the way to go.
>>>
>>> On Thu, Apr 8, 2010 at 4:41 PM, Janek  wrote:
>>>
>>> > Hi,
>>> >
>>> > In Source, you can write alias in autoexec.cfg file ala : alias
>>> > "name_of_alias" "cmd1; cmd2; cmd3".
>>> >
>>> > I'd like to be able to check each command in the alias when this alias
>>> is
>>> > executed. I thought it was possible by studying pszCurrentBinding in
>>> int
>>> > CInput::KeyEvent( int down, ButtonCode_t code, const char
>>> > *pszCurrentBinding
>>> > ) in in_main.cpp but it failt as pszCurrentBinding is containing the
>>> alias
>>> > "name_of_alias" and not the primitive command.
>>> > As it is returning 1, it is up to the engine to process this command. I
>>> > imagine that the engine is able to properly parse the primitive
>>> commands.
>>> > I'd like to know if there is an other location to get these primitive
>>> > commands. How would you proceed ?
>>> >
>>> > Thank you in advance for your help.
>>> >
>>> > ---
>>> > j...@nek
>>> > ___
>>> > To unsubscribe, edit your list preferences, or view the list archives,
>>> > please visit:
>>> > http://list.valvesoftware.com/mailman/listinfo/hlcoders
>>> >
>>> >
>>> ___
>>> To unsubscribe, edit your list preferences, or view the list archives,
>>> please visit:
>>> http://list.valvesoftware.com/mailman/listinfo/hlcoders
>>>
>>>
>>
>>
>> --
>> ---
>> j...@nek
>>
>
>
>
> --
> ---
> j...@nek
>



-- 
---
j...@nek
___
To unsubscribe, edit your list preferences, or view the list archives, please 
visit:
http://list.valvesoftware.com/mailman/listinfo/hlcoders



Re: [hlcoders] Getting commands in an alias (autoexec.cfg)

2010-04-09 Thread Janek
In fact I found this InstallGlobalChangeCallback but can't use it coz I'm
not able to get this alias as a ConCommand. There's probably somethiing
different to a standard ConCommand.

J.

2010/4/9 Janek 

> I try to find where this callback could be hook for any alias but didn't
> succeed ;-( Still searching.
>
> 2010/4/9 Skillet 
>
> I don't know if checking at "runtime" whether commands are being executed
>> in
>> a batch as an alias command is possible but it certainly is possible to
>> change the callback for the engine alias ConCommand so you can check the
>> contents before it is fed to the engine.  If you're trying to disallow the
>> use of particular primitive commands in aliases, that's the way to go.
>>
>> On Thu, Apr 8, 2010 at 4:41 PM, Janek  wrote:
>>
>> > Hi,
>> >
>> > In Source, you can write alias in autoexec.cfg file ala : alias
>> > "name_of_alias" "cmd1; cmd2; cmd3".
>> >
>> > I'd like to be able to check each command in the alias when this alias
>> is
>> > executed. I thought it was possible by studying pszCurrentBinding in int
>> > CInput::KeyEvent( int down, ButtonCode_t code, const char
>> > *pszCurrentBinding
>> > ) in in_main.cpp but it failt as pszCurrentBinding is containing the
>> alias
>> > "name_of_alias" and not the primitive command.
>> > As it is returning 1, it is up to the engine to process this command. I
>> > imagine that the engine is able to properly parse the primitive
>> commands.
>> > I'd like to know if there is an other location to get these primitive
>> > commands. How would you proceed ?
>> >
>> > Thank you in advance for your help.
>> >
>> > ---
>> > j...@nek
>> > ___
>> > To unsubscribe, edit your list preferences, or view the list archives,
>> > please visit:
>> > http://list.valvesoftware.com/mailman/listinfo/hlcoders
>> >
>> >
>> ___
>> To unsubscribe, edit your list preferences, or view the list archives,
>> please visit:
>> http://list.valvesoftware.com/mailman/listinfo/hlcoders
>>
>>
>
>
> --
> ---
> j...@nek
>



-- 
---
j...@nek
___
To unsubscribe, edit your list preferences, or view the list archives, please 
visit:
http://list.valvesoftware.com/mailman/listinfo/hlcoders



Re: [hlcoders] Getting commands in an alias (autoexec.cfg)

2010-04-08 Thread Janek
I try to find where this callback could be hook for any alias but didn't
succeed ;-( Still searching.

2010/4/9 Skillet 

> I don't know if checking at "runtime" whether commands are being executed
> in
> a batch as an alias command is possible but it certainly is possible to
> change the callback for the engine alias ConCommand so you can check the
> contents before it is fed to the engine.  If you're trying to disallow the
> use of particular primitive commands in aliases, that's the way to go.
>
> On Thu, Apr 8, 2010 at 4:41 PM, Janek  wrote:
>
> > Hi,
> >
> > In Source, you can write alias in autoexec.cfg file ala : alias
> > "name_of_alias" "cmd1; cmd2; cmd3".
> >
> > I'd like to be able to check each command in the alias when this alias is
> > executed. I thought it was possible by studying pszCurrentBinding in int
> > CInput::KeyEvent( int down, ButtonCode_t code, const char
> > *pszCurrentBinding
> > ) in in_main.cpp but it failt as pszCurrentBinding is containing the
> alias
> > "name_of_alias" and not the primitive command.
> > As it is returning 1, it is up to the engine to process this command. I
> > imagine that the engine is able to properly parse the primitive commands.
> > I'd like to know if there is an other location to get these primitive
> > commands. How would you proceed ?
> >
> > Thank you in advance for your help.
> >
> > ---
> > j...@nek
> > ___
> > To unsubscribe, edit your list preferences, or view the list archives,
> > please visit:
> > http://list.valvesoftware.com/mailman/listinfo/hlcoders
> >
> >
> ___
> To unsubscribe, edit your list preferences, or view the list archives,
> please visit:
> http://list.valvesoftware.com/mailman/listinfo/hlcoders
>
>


-- 
---
j...@nek
___
To unsubscribe, edit your list preferences, or view the list archives, please 
visit:
http://list.valvesoftware.com/mailman/listinfo/hlcoders



Re: [hlcoders] Getting commands in an alias (autoexec.cfg)

2010-04-08 Thread Skillet
I don't know if checking at "runtime" whether commands are being executed in
a batch as an alias command is possible but it certainly is possible to
change the callback for the engine alias ConCommand so you can check the
contents before it is fed to the engine.  If you're trying to disallow the
use of particular primitive commands in aliases, that's the way to go.

On Thu, Apr 8, 2010 at 4:41 PM, Janek  wrote:

> Hi,
>
> In Source, you can write alias in autoexec.cfg file ala : alias
> "name_of_alias" "cmd1; cmd2; cmd3".
>
> I'd like to be able to check each command in the alias when this alias is
> executed. I thought it was possible by studying pszCurrentBinding in int
> CInput::KeyEvent( int down, ButtonCode_t code, const char
> *pszCurrentBinding
> ) in in_main.cpp but it failt as pszCurrentBinding is containing the alias
> "name_of_alias" and not the primitive command.
> As it is returning 1, it is up to the engine to process this command. I
> imagine that the engine is able to properly parse the primitive commands.
> I'd like to know if there is an other location to get these primitive
> commands. How would you proceed ?
>
> Thank you in advance for your help.
>
> ---
> j...@nek
> ___
> To unsubscribe, edit your list preferences, or view the list archives,
> please visit:
> http://list.valvesoftware.com/mailman/listinfo/hlcoders
>
>
___
To unsubscribe, edit your list preferences, or view the list archives, please 
visit:
http://list.valvesoftware.com/mailman/listinfo/hlcoders



[hlcoders] Getting commands in an alias (autoexec.cfg)

2010-04-08 Thread Janek
Hi,

In Source, you can write alias in autoexec.cfg file ala : alias
"name_of_alias" "cmd1; cmd2; cmd3".

I'd like to be able to check each command in the alias when this alias is
executed. I thought it was possible by studying pszCurrentBinding in int
CInput::KeyEvent( int down, ButtonCode_t code, const char *pszCurrentBinding
) in in_main.cpp but it failt as pszCurrentBinding is containing the alias
"name_of_alias" and not the primitive command.
As it is returning 1, it is up to the engine to process this command. I
imagine that the engine is able to properly parse the primitive commands.
I'd like to know if there is an other location to get these primitive
commands. How would you proceed ?

Thank you in advance for your help.

---
j...@nek
___
To unsubscribe, edit your list preferences, or view the list archives, please 
visit:
http://list.valvesoftware.com/mailman/listinfo/hlcoders