Raised This Month: $51 Target: $400
 12% 

[EXTENSION] Weapon Model


Post New Thread Reply   
 
Thread Tools Display Modes
zeroibis
Veteran Member
Join Date: Jun 2007
Old 05-26-2011 , 03:12   Re: [EXTENSION] Weapon Model
Reply With Quote #71

well you could just make the clients view 3rd person then they can see it too lol. Hey you never know...
__________________
zeroibis is offline
Benjamin1995
SourceMod Donor
Join Date: May 2009
Location: Germany
Old 05-26-2011 , 11:22   Re: [EXTENSION] Weapon Model
Reply With Quote #72

I know thats possible. But I want to set the viewmodel oO
__________________
Benjamin1995 is offline
Send a message via Skype™ to Benjamin1995
klausenbusk
AlliedModders Donor
Join Date: Jan 2011
Old 05-26-2011 , 11:29   Re: [EXTENSION] Weapon Model
Reply With Quote #73

Look in this eventscript code:
http://forums.eventscripts.com/viewtopic.php?t=26334

Code:
    # Set viewmodel properties

    es.setindexprop(viewModelIndex, 'CBaseViewModel.m_nModelIndex', index)

    es.setindexprop(viewModelIndex, 'CBaseViewModel.m_nViewModelIndex', index)
klausenbusk is offline
xbatista
Veteran Member
Join Date: Mar 2008
Location: Lithuania
Old 05-27-2011 , 02:14   Re: [EXTENSION] Weapon Model
Reply With Quote #74

klausenbusk that will not work on sourcemod
__________________
xbatista is offline
Send a message via Skype™ to xbatista
Mecha the Slag
Veteran Member
Join Date: Jun 2009
Location: Denmark
Old 05-27-2011 , 07:21   Re: [EXTENSION] Weapon Model
Reply With Quote #75

but it's easily convertible.
__________________
Mecha the Slag is offline
Benjamin1995
SourceMod Donor
Join Date: May 2009
Location: Germany
Old 05-27-2011 , 09:39   Re: [EXTENSION] Weapon Model
Reply With Quote #76

But if you set it your weapon is invisible.
__________________
Benjamin1995 is offline
Send a message via Skype™ to Benjamin1995
Mecha the Slag
Veteran Member
Join Date: Jun 2009
Location: Denmark
Old 05-27-2011 , 18:35   Re: [EXTENSION] Weapon Model
Reply With Quote #77

No. Depending on the game it has different behaviours. In ep1 games, it works like a charm. In Orange Box games, it flashes between the original and the newly defined.

Chances are you're setting the netprop wrong. The index is the value returned from PrecacheModel.
__________________
Mecha the Slag is offline
Paparazziv2
Senior Member
Join Date: Feb 2011
Location: Chile, La Serena
Old 09-14-2011 , 16:15   Re: [EXTENSION] Weapon Model
Reply With Quote #78

this yes can works? or not? :s please a link with all in one file for the download, i not understand.
__________________
Sorry for the bad english please.

Paparazziv2 is offline
Send a message via MSN to Paparazziv2
Blowst
Senior Member
Join Date: Feb 2011
Location: Korea, Republic of
Old 09-15-2011 , 07:53   Re: [EXTENSION] Weapon Model
Reply With Quote #79

Quote:
Originally Posted by Paparazziv2 View Post
this yes can works? or not? :s please a link with all in one file for the download, i not understand.

this may not working.

just use this

http://forums.alliedmods.net/showpos...6&postcount=70

please add to friend(qwe7310 <- steam id) to get info about viewmodel.
(because i'm new member )
__________________
Sorry about my poor English


Last edited by Blowst; 09-15-2011 at 07:58.
Blowst is offline
rodrigo286
Veteran Member
Join Date: Sep 2010
Location: Brazil, São Paulo
Old 10-04-2011 , 10:49   Re: [EXTENSION] Weapon Model
Reply With Quote #80

Quote:
This is from Andersso:
Quote:
PHP Code:
#include <sourcemod>
#pragma semicolon 1
new g_iWorldModel;

public 
OnMapStart()
{
g_iWorldModel PrecacheModel("models/weapons/w_crowbar.mdl"true);
}

public 
Action:OnPlayerRunCmd(iClient, &iButtons, &ImpulseFloat:fVelocity[3], Float:fAngles[3], &iWeapon)
{
new 
iActiveWeapon GetEntPropEnt(iClientProp_Data"m_hActiveWeapon");

if (
iActiveWeapon != -1)
{
decl String:sWeapon[64];
GetEdictClassname(iActiveWeaponsWeaponsizeof(sWeapon));

if (
StrEqual(sWeapon"weapon_knife"))
{
SetEntProp(iActiveWeaponProp_Send"m_iWorldModelIndex"g_iWorldModel);
}
}

This only replaces the Worldmodel!!!
Is there any way to change the player model?

Thanks!

Last edited by rodrigo286; 10-04-2011 at 11:15.
rodrigo286 is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 09:59.


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