Raised This Month: $ Target: $400
 0% 

Create shield entity to block damage?!


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
HoLLyWooD
Senior Member
Join Date: Nov 2010
Location: Ukraine Krivoy Rog
Old 01-17-2011 , 02:02   Create shield entity to block damage?!
Reply With Quote #1

Hi! That entity trying to make a shield for the player.

Is a model of the shield (attached below).

I have the server will be the VIP players. Each round they will get a shield. This panel will have 500-700 to block the loss of life and in the back until the break. Upon receipt of damage or destruction of the shield should be given a sound yet.

Who is able to help? The task will be interesting and useful for beginners who read the topic. I myself have recently started working with the objects themselves.

Here is my code to create a shield:
but it just hangs the shield on the back of the player without blocking the damage and not getting hit.
PHP Code:
public set_vip_shield(id){
    
usr_shield[id] = engfunc(EngFunc_CreateNamedEntityengfunc(EngFunc_AllocString"info_target"));
    
set_pev(usr_shield[id], pev_classname"vip_shield")
    
set_pev(usr_shield[id], pev_movetypeMOVETYPE_FOLLOW)
    
set_pev(usr_shield[id], pev_solid1)
    
set_pev(usr_shield[id], pev_aimentid)
    
set_pev(usr_shield[id], pev_health,100)
    
set_pev(usr_shield[id], pev_rendermodekRenderNormal)
    
engfunc(EngFunc_SetModelusr_shield[id], vip_shield)

I do not know how to do that until the shield on his back, the damage got a shield.

Well the mud as a shield destroyed = (
Attached Files
File Type: zip cashield.zip (32.3 KB, 126 views)
__________________

You do not know what to tell? Keep silent! You will look cleverer!
Не знаешь что сказать? Промолчи! Будешь выглядеть умней!
Статьи по скриптингу: НА РУССКОМ
HoLLyWooD is offline
 



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 02:06.


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