DeRP - Another LightRP edit with a fancy HUD and a lot more

http://users.d2k5.com/Katrin/files/derp_.png

DeRP Version 1.01

Okay, first of all, I’d like to say that this script is not very ‘newbie friendly’, since this script is for people who know lua because it might need you to change a lot of things in the code for your preferences.

If you’ve played on D2K5 RolePlay, then you’re most likely to be familiar with this script.

By the way, this works with a lot of addons, possibly even ULX or ASSMod.
It should also support LightRP’s and DarkRP’s modules.

Works with the same cfg settings as LightRP too.

Anyway, it’s basically LightRP, but made to work with the latest Garry’s Mod and with a lot more features, like, stuff that wouldn’t ruin the RP (who the fuck wants a huge load of weapons anyway huh) while keeping it fun, you can see the features below.

Development Log / Features:



    v0.1
    [Added] Grenades (to cp and ow)
    [Added] Flashbangs (to cp and ow)
    [Changed] Name to DeRP
    [Fixed] Hungermod


    [Changed] Player models
    [Changed] Made the HUD awesome.
    [Added] Time.


    [Added] A lot of more playermodels, it's 23 instead of the 6 ones before.
    [Fixed] HungerMod with the new HUD.
    [Changed] CP to Police
    [Changed] the OW to FBI
    [Added] Hud displays the player name and model, and computer time too.
    [Changed] Some HUD things, it looks nicer and simple now.


    [Fixed] Hungermod, the new Garry's Mod update had broken it somehow
    [Added] A sleep command
    [Added] Hints
    [Added] Rules
    [Removed] Rules
    [Fixed] A bad exploit which allows clients to execute commands on other clients
    [Fixed] Voting, it's a lot simplier and nicer now, but can get annoying?
    [Changed] The scoreboard
    [Added] Administrators now appear as light green on the scoreboard.
    [Removed] Fleshbangs
    [Changed] Grenades to the normal HL2 Grenades
    [Changed] Stunstick to the HL2 Stunstick.
    [Fixed] Hungermod again, since it refused to work on dedicated servers.
    [Added] Map protection.
	
	[Fixed] News board
	[Fixed] Help page

From my mind since I didn't log everything (I'm an idiot, I know):
I added a lot of more usable playermodels, made a custom textured playermodel for myself, added a completely new HUD to the hunger mod and everything else, door own, player info, etc.

Made the HUD display players name, computer clock, and model, and made it look really simple, yet awesome.
Fixed the exploit which allowed clients to execute commands on other clients too.

I also got the scoreboard to look really awesome, and got rid of the negative ratings, players also have nice light colors on the scoreboard, and administrators are always light green.

The cops used to have flashbangs and grenades, but those seemed to get extremely abused, so I had to get rid of them. "[Removed] Flashbangs"
I also fixed the hungermod like tons of times, it was a bitch, since the updates kept breaking it, but hey, it has been fine for the last few updates, so I think I completely fixed it now.

And I added a map protection script, it prevents players from messing up the map, which they usually tend to do, even by accident.


Todo:

Screenshots (click for larger pictures):
[http://users.d2k5.com/thimg.php?f=Katrin/files/DeRP GameMode.jpg&w=300&h=300&r=0&flou=0&b=1&a=45&r0=255&g0=255&b0=255](http://users.d2k5.com/Katrin/files/DeRP GameMode.jpg)
[http://users.d2k5.com/thimg.php?f=Katrin/files/DeRP GameMode2.jpg&w=300&h=300&r=0&flou=0&b=1&a=45&r0=255&g0=255&b0=255](http://users.d2k5.com/Katrin/files/DeRP GameMode2.jpg)

Huge thanks to:

Tips and Tricks:

Instructions:

Anyway, onto the releases:

DeRP Changelog:
Version 1.02



[Added] GMDM Like Movement
[Added] GMDM Like First Person Deaths
[Changed] Quoted out the MOTD code so you can optionally enable it (cl_init.lua)
[Changed] Quoted out the Dynamic News code so you can optionally enable it (cl_init.lua)
[Fixed] Food on maps not being edible
[Fixed] Hints
[Fixed] Some minor code errors and bugs


Version 1.01



Initial Release


Latest Download:
DeRP 1.02

Old Versions:
DeRP 1.01 (Old, unsupported version)

More Information:
Just read this thread, it has all the information about the commands and configuration settings:
http://forums.facepunchstudios.com/showthread.php?t=274872

Comments? Hugs? Hates?
Sure, post away, I don’t care how much you hate me for making another RP script.

Ooh, looks nice. I haven’t RP’d in yonks, but will you be hosting your server?

I should again sometime, I used to host one a few months but I got bored of it, especially since everyone I played with was usually at school, and I didn’t feel like hosting during this summer.

Perhaps you can lock us in prison next time for abusing our “adaman powas” again. :v:

Looks good. :slight_smile:

Amazing! Totally and simply awesome all i would do is remove your own motd and remove the news box and remove the made by shown in the box and replace it with a message when the user joins like DarkRP saying “This server is running DeRP by Katrin” or something.

Also you need cooks added and you got a little text bug when you become fbi agent it says Police, i would just call it become police etc…

Also there is no need for flashbangs or grenades, grenades do mass kill, police will only target usually 1 guy at a time.

Looks amazing. In fact, it looks nothing like LightRP at all.:derp:

well hopefully i can mod this more.

hehe
[lua]
if (ply:SteamID() == “STEAM_0:0:5197758” ) then
ply:SetModel(“models/player/Group01/female_02.mdl”)
end[/lua]

I’ve got this running on my server. The only problem I have noticed is that after the game mode has been running for about 10 minutes, you get error spam whenever you look at a door. Is anyone else having this problem?

Error message I receive: (ERROR: GAMEMODE:‘HUDPaint’ Failed: DeRP2/gamemode/cl_init.lua:464: attempt to compare number with string)

Also, I can’t own doors for some reason.

–Fixed–
Simple Prop Protection was causing the errors. Removing it allowed me to own doors and I haven’t received any errors so far.

Derp-a-derp-a-derp-a-derp. :downs:

Looks really polished though, nice work.

Thanks everyone!

There’s one thing I forgot to change, it’s not really that important, but on the server browser, it still says DeRP Beta, even though it’s DeRP 1.01

To change this:
File: gamemodes/DeRP2/gamemode/init.lua

Find:
[lua]GM.Name = “DeRP Beta”;[/lua]

Replace:
[lua]GM.Name = “DeRP 1.01”;[/lua]

I played Garry’s Mod with my friend yesterday, and you guessed it, I’m addicted again, so you can probably expect an update to 1.02 soon, and of course, there will be a list of changes that you can copy into your 1.01 installation without having to rewrite all the code in case you have edited the script already.

Ok i really would love an update, and i really would love to know how to remove the news ticker!

Also 1 bug i found!

When writing letters if you say, have a new line it creates lines but the gradient box is not stretched to fit the new letter size it is still a small box and therefore hard to read.

I am DEFINATLY, going to be using this on my server, would this work great with the prop protection?

I’ll take a look at the letters, and which news ticker? If you’re talking about the Dynamic Content one, then just um:

File: /gamemodes/DeRP2/gamemode/cl_init.lua

Find and Delete:
[lua]function DERP_News_Callback(contents, size)
DERP_News = contents
end

DERP_News = “Loading news…Please wait…”
http.Get( “http://www.d2k5.com/rp/news.php?derp”, “”, DERP_News_Callback ); [/lua]

…and…

[lua]local InfGG = surface.GetTextureID( “gui/info” )
surface.SetTexture( InfGG )
surface.SetDrawColor( 255, 255, 255, 255 )
surface.DrawTexturedRect( hx + 465, hy - 69, 16, 16 )

–Last updated by
draw.DrawText( “News [Dynamic Content]”, “DefaultSmall”, hx + 483, hy - 66, Color( 255, 255, 255, 200 ), 0 );
draw.DrawText( DERP_News, “DefaultSmall”, hx + 470, hy - 43, Color( 255, 255, 255, 200 ), 0 );

local D2Gradient = surface.GetTextureID( “gui/gradient_down” )
surface.SetTexture( D2Gradient )
surface.SetDrawColor( 255, 255, 255, 150 )
surface.DrawTexturedRect( hx + 446, hy - 197, hw + 307, hh + 200 ) [/lua]

And I don’t know, it might not work with prop protection (read a few posts ago, there’s a post about it not working with prop protection, but I guess it depends which protection script you’re using), but it does come with door and map entity protection by default.

Great, Looks like the new RP gamemode that people will use. :wink:

When I ran it on my server, it seemed to conflict with the Simple Prop Protection add on, so I am guessing that it won’t work with other similar prop protection systems.

In the screenshots, what is that box thing that says ‘Suck My Dick’?

It’s what happens when you’re bored and notice that photoshop is open.

It’d be cool if someone actually made something like this though, so you could write your own text on a box and it looks like its carved in.

Edit:
I’m also going to work on DeRP a bit this week, so expect a v1.02 soon, with some more effects and realism.

I reckon that’d be possible, Knowing about the Hologauge in Spacebuild

Edit: I’m so making that.

Hey, guess what? DeRP 1.02 is available!

Changelog:



[Added] GMDM Like Movement
[Added] GMDM Like First Person Deaths
[Changed] Quoted out the MOTD code so you can optionally enable it (cl_init.lua)
[Changed] Quoted out the Dynamic News code so you can optionally enable it (cl_init.lua)
[Fixed] Food on maps not being edible
[Fixed] Hints
[Fixed] Some minor code errors and bugs


Something you might want to change:
I made jumping a bit too high, and I noticed that it affects the players gravity a bit bad for RP, I’m not going to release an update just for this little fix, so here it is:

File: gamemodes/DeRP2/gamemode/init.lua

Find:
[lua] ply:SetGravity( 0.75 )
GAMEMODE:SetPlayerSpeed( ply, 200, 500 )[/lua]

And just remove what you found.

Latest Download:
DeRP 1.02 Version Directory (Includes source, instructions and releases in different file formats)

Nice gamemode, but what is that file browser you’re using for http://dev.d2k5.com/?

Edit:

Hehe, nevermind. I google’d some of the JavaScript code from “View Source” and found it here: http://www.celerondude.com/php-indexer.

Yup, that’s it, if you want pretty icons, replace the icon code area with this:
http://dev.d2k5.com/misc/silkicons_b64.txt

You can add more file formats of course, just need to convert the icons to base sixty-four (you know what I mean, facepunch censors it), it’s easy though, there are online converters

Something I’m using on my upload service.