AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Module Coding (https://forums.alliedmods.net/forumdisplay.php?f=9)
-   -   Hamsandwich Updating (https://forums.alliedmods.net/showthread.php?t=159814)

Arkshine 04-12-2014 14:37

Re: Hamsandwich Updating
 
Thanks, fixed in git3792, but that's not really the place for that. Don't hesitate to PM me directly next time.

Arkshine 05-02-2014 04:10

Re: Hamsandwich Updating
 
Bot without "player" classname is now supported by Ham in git3805+.

This can't be enabled by default considering existing workaround used by plugins and to avoid unexpected behavior.

A new "specialbot" param has been added to RegisterHam. On false by default.
A stock has been added as well named "RegisterHamPlayer" where you don't need provide "player" classname and specialbot is set to true already. Just to make code more intuitive.

yokomo 05-02-2014 04:57

Re: Hamsandwich Updating
 
Quote:

Originally Posted by Arkshine (Post 2132359)
Bot without "player" classname is now supported by Ham in git3805+.

This can't be enabled by default considering existing workaround used by plugins and to avoid unexpected behavior.

A new "specialbot" param has been added to RegisterHam. On false by default.
A stock has been added as well named "RegisterHamPlayer" where you don't need provide "player" classname and specialbot is set to true already. Just to make code more intuitive.

Arkshine how to see the full changes log on current dev build? it seems the web page is updated, last time it easy to see changes log.

**Edited**
Typo detected:
Code:

/**
 * Hooks the virtual table for the player class.
 * An example would be: RegisterHam(Ham_TakeDamage, "player_hurt");
 * Look at the Ham enum for parameter lists.
 *
 * @param function        The function to hook.
 * @param callback        The forward to call.
 * @param post            Whether or not to forward this in post.
 * @return                Returns a handle to the forward.  Use EnableHamForward/DisableHamForward to toggle the forward on or off.
 */
stock HamHook:RegisterHamPlayer(Ham:function, const Callback[], Post=0)
{
    return RegisterHam(function, "player", Callback, Post, .specialbot = true);
}

Error:
Code:

* An example would be: RegisterHam(Ham_TakeDamage, "player_hurt");
Should be:
Code:

* An example would be: RegisterHamPlayer(Ham_TakeDamage, "player_hurt");

Arkshine 05-02-2014 05:04

Re: Hamsandwich Updating
 
Quote:

it seems the web page is updated, last time it easy to see changes log.
Not sure to understand this.

Anyway, there is no changelog like a clean list, you will have to read each commit from there : https://labs.alliedmods.net/am/amxmodx/commits/master

yokomo 05-02-2014 05:22

Re: Hamsandwich Updating
 
Quote:

Originally Posted by Arkshine (Post 2132378)
Not sure to understand this.

Anyway, there is no changelog like a clean list, you will have to read each commit from there : https://labs.alliedmods.net/am/amxmodx/commits/master

Ok thanks, that is what i mean. Now i can track what has been done on each build.

By the way tested your new "RegisterHamPlayer" it working, but not sure about it stability. Hope it not giving any random crash.

Arkshine 05-02-2014 05:30

Re: Hamsandwich Updating
 
Why would it give random crash? Do you have some issue with it? Please elaborate.

yokomo 05-02-2014 05:41

Re: Hamsandwich Updating
 
Quote:

Originally Posted by Arkshine (Post 2132389)
Why would it give random crash? Do you have some issue with it? Please elaborate.

At this moment no issue yet, i was talked about the modified ham module by someone name Slywes.. what ever his name not remember :) his version give random crash. I cant figure what cause it, but when i change default ham module server is ok.

Arkshine 05-02-2014 05:59

Re: Hamsandwich Updating
 
Oh. Well, if it happens, don't hesitate to tell here and try to keep in memory what you've done.

Oh˛, one thing which could be related to a crash, is he was freeing a string pointer wrongly (like using delete instead of delete[]). It's possible after map change, it could have fucked up things.

bibu 05-02-2014 20:01

Re: Hamsandwich Updating
 
So this should be closed then?
Any reports should be reported under the amxx issue if I am right...


All times are GMT -4. The time now is 14:29.

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