AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   Engine to Fakemeta ?? (https://forums.alliedmods.net/showthread.php?t=98802)

5c0r-|3i0 07-29-2009 12:57

Engine to Fakemeta ??
 
I want to convert my code from engine to fakemeta because I don't want to use lots of modules :D...Can I convert from engine to fakemeta..??
btw,which one is better , fakemeta or engine...?? :oops::oops:

SnoW 07-29-2009 13:00

Re: Engine to Fakemeta ??
 
Engine is faster in most cases and it doesn't matter if you use much modules, one of your other plugins uses engine anyway. I'm lazy so I never convert anything and you shouldn't either.

fysiks 07-29-2009 13:04

Re: Engine to Fakemeta ??
 
Basically, if it can be done with engine, do it with engine. If it can't be done with engine, use the next best thing (which is likely fakemeta or even Ham).

Arkshine 07-29-2009 14:03

Re: Engine to Fakemeta ??
 
Quote:

if it can be done with engine, do it with engine
Well, I prefer to use set_pev()/pev() for readability and to code/maintain more fastly. The difference with engine is trivial. Same others things but just some exception. Anyway I agree with you.

5c0r-|3i0 07-29-2009 22:14

Re: Engine to Fakemeta ??
 
Why engine and fakemeta is so difference...>"<...I'll try to convert my plugin from engine to fakemeta
PHP Code:

   entity_set_string(idEV_SZ_viewmodel"models/v_mp5m203.mdl")
   
entity_set_string(idEV_SZ_weaponmodel"models/p_9mmar.mdl"

to
PHP Code:

set_pev(pev_viewmodel,...)
set_pev(pev_weaponmodel,...) 

When I use a weapon that call this function..my server crash :(... [MOdel....not precached or something ??]

is pev_viewmodel2 or pev_viewmodel ??....And why fakemeta have those >"<....I really n0ob about this..

Exolent[jNr] 07-30-2009 00:27

Re: Engine to Fakemeta ??
 
Quote:

Originally Posted by fysiks (Post 884949)
Basically, if it can be done with engine, do it with engine. If it can't be done with engine, use the next best thing (which is likely fakemeta or even Ham).


Arkshine 07-30-2009 06:00

Re: Engine to Fakemeta ??
 
@5c0r-|3i0: Using fakemeta, you have to allocate string if using pev_viewmodel/pev_weaponmodel ( with EngFunc_AllocString ), and you can directly put the string with pev_viewmodel2/pev_weaponmodel2 ( the string is allocated automatically )

hleV 07-30-2009 08:40

Re: Engine to Fakemeta ??
 
I'll give you one question and I hope it will be answered before anyone really helps you.

Why do you want to convert Engine to Fakemeta?

5c0r-|3i0 07-30-2009 08:54

Re: Engine to Fakemeta ??
 
Ah.....optimize my code....So I think maximum is 3-4 modules :D...[Sorry for my stupid thought..]

xPaw 07-30-2009 08:57

Re: Engine to Fakemeta ??
 
thats not optimizing


All times are GMT -4. The time now is 18:28.

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