mirror of
https://github.com/dhewm/dhewm3-sdk.git
synced 2025-04-23 01:31:32 +00:00
Fix alternatively the crash of when player picks up an item, something is wrong with calling a script object in a function
This commit is contained in:
parent
e1f6760620
commit
e6b192d3d2
1 changed files with 3 additions and 2 deletions
|
@ -587,9 +587,10 @@ bool idItem::GiveToPlayer( idPlayer *player ) {
|
|||
if ( val ) {
|
||||
if ( spawnArgs.GetString( "scriptobject" ) != "" ) {
|
||||
if ( !g_noPickupNotification.GetBool() && !spawnArgs.GetBool( "dontNotifyOnPickup" ) ) {
|
||||
CallFunc( "pickup_message" );
|
||||
// CallFunc( "pickup_message" ); // doesn't work in dhewm3, crashes
|
||||
player->ShowHudMessage( va("You got the %s\n", spawnArgs.GetString( "inv_name" )) );
|
||||
}
|
||||
CallFunc( "pickup_effect" );
|
||||
// CallFunc( "pickup_effect" ); // doesn't work in dhewm3, crashes
|
||||
}
|
||||
|
||||
gameLocal.SetPersistentRemove( name.c_str() );
|
||||
|
|
Loading…
Reference in a new issue