Garry's Mod

Garry's Mod

[E2] PlyCore
 此主题已被置顶,因此可能具有重要性
Sir Papate  [开发者] 2014 年 1 月 13 日 下午 5:39
Suggestion box!
If you have any suggestions of commands or of project, write down!
最后由 Sir Papate 编辑于; 2014 年 1 月 13 日 下午 6:32
< >
正在显示第 1 - 15 条,共 24 条留言
[SUAFT] Chammy 2014 年 6 月 13 日 下午 11:48 
You have a function for forcing a player to spawn, perhaps you could have a function similar to runOnTick(), but be runOnSpawn(E), where E is a player entity? Then it would run the expression every time that player respawns.

If this is possible, respawnClk() may also be an ideal function, for returning 1 when the exrpession is triggered by a respawn.
Sir Papate  [开发者] 2014 年 6 月 17 日 下午 7:32 
I'm going to work, it should be done in a few days.

You can use this code to do it:
@persist LastPlySpawn:entity [AliveD LastAliveTick]:array runOnTick(1) function number spawnClk(){ foreach( I, Ply:entity = players() ){ AliveD[I,number] = LastAliveTick[I,number] - Ply:isAlive() LastAliveTick[I,number] = Ply:isAlive() if( Ply:isAlive() & AliveD[I,number] & !first() ){ LastPlySpawn = Ply return 1 } } return 0 } function entity lastSpawn(){ return LastPlySpawn } ##Example if( spawnClk() ){ if( lastSpawn() == owner() ){ owner():plySetSpeed( 500 ) } }
最后由 Sir Papate 编辑于; 2014 年 6 月 17 日 下午 7:37
[SUAFT] Chammy 2014 年 6 月 17 日 下午 10:01 
Awesome! Glad you saw my comment, and thanks for the response! I look forward eagerly to the update! Modders like you rock.
Sir Papate  [开发者] 2014 年 6 月 23 日 上午 8:18 
it's done!
[SUAFT] Chammy 2014 年 6 月 23 日 上午 11:32 
Awesome! I'm sure I'll be on Gmod at some point today, if anything goes wrong, I'll let you know! Thanks for the quick and excellent work!
zamboni 2014 年 7 月 20 日 下午 5:41 
Could you possibly create a function that will nocollide the player with a specified entity? For instance, I have a forcefield E2, and currently the way it's set up is it toggles the solid state of the prop, which allows other people through if someone on the whitelist is close enough.

I just need something like E:plyNoCollide() where in the parentheses I could maybe reference a table of steamIDs

My example:
if(Pos <=80 & T[Targ:team():teamName(),number] == 1){
entity():isWeldedTo():plyNoCollide(Target)
}

that's obviously not the entire E2, but the basic use of it.

Sorry if I didn't explain it very well.
最后由 zamboni 编辑于; 2014 年 7 月 20 日 下午 5:44
bigdogmat 2015 年 11 月 5 日 下午 11:31 
Remove the has access checks from functions such as plyInGod, mainly because their's no reason to have it on such functions and they'll just return an invalid result.
OUIIJM GUIITPS 2016 年 1 月 13 日 下午 12:56 
What about a plyInNoclip
returns 1 if the player is in noclip mode
bigdogmat 2016 年 1 月 14 日 上午 6:11 
InNoclip is already in default E2
OUIIJM GUIITPS 2016 年 1 月 14 日 上午 11:58 
derp
spook_rose 2019 年 7 月 25 日 上午 8:32 
hey @Sir Papate is it possible to add plyStrip() to stip all a players weapons please?

this can be done without it but its a serious job to do so and its a lot of hastle to get it working so i thaught maybe asking u to make a function for that so it would be a lot easier
Sir Papate  [开发者] 2019 年 7 月 28 日 上午 11:26 
引用自 ๖ۣۜpaul_rose
hey @Sir Papate is it possible to add plyStrip() to stip all a players weapons please?

this can be done without it but its a serious job to do so and its a lot of hastle to get it working so i thaught maybe asking u to make a function for that so it would be a lot easier

Thanks for your suggestion, but this function is already available in the WeaponCore with E:plyStripWeapons()
spook_rose 2019 年 7 月 28 日 上午 11:34 
thankyou =) i diddnt realise there was a core for weapons, il be sure to try it!
Sanders 2019 年 7 月 28 日 下午 2:00 
引用自 ๖ۣۜpaul_rose
thankyou =) i diddnt realise there was a core for weapons, il be sure to try it!

it works well i use it in a server (making a safespace kind of thing)
foreskin cottage cheese 2020 年 8 月 12 日 上午 9:24 
add a function plyCanNoclip() "number=entity:PlyCanNoclip()" (checks if the player can noclip using the noclip bind not ulx)
< >
正在显示第 1 - 15 条,共 24 条留言
每页显示数: 1530 50