[FilterScript] Zombeydere (Simple Zombie creation)
#1

Introduction

I'm in process of creating one of these zombie servers, the thing I have fought the most with was the creation of the zombies, it is hard to make it work as intended, so, to save time for these people creating the same themed gamemode, I provide this piece of code.

Note that I started learning sa-mp from about 3 months ago, the code could be better somehow. Feel free to insult me, but while you're at it, point at me what did I do wrong.

Media

https://www.youtube.com/watch?v=5LGANGw7VLs

Features

Quote:

- About 120 zombie areas in both LV and LS.
- The zombies will follow (running) the nearest player with the lower ID.
- The zombies will attack the nearest player (not very accurate but they try atleast).
- The zombies are killable in every way but by car crash and fire (RPG/grenades)
- Zombie Area system, if there's no player in an area, zombies of that area will be returned to the pool.
- NPC pool for fast-access to the NPCs.
- Optimized NPC management. They die, they're returned to the pool.
- If the player is in a different latitude level than the zombies, they will stop following (if the player gets in a rooftop, so the zombies won't fly)
- Customizable NPC damage.
- Fully controllable and easy script to make your own modifications.

Known Issues/Bugs

Quote:

- Zombie's aim is not accurate.
- Zombies will go through walls if needed.
- Zombies don't know where the floor is (not using MapAndreas), so they may step below the floor.
- All of the Zombies will be online all the time, this consumes player slots and may make your server run slower
- This has not been tested with lot of people.
- Tons of fucking recordings in your npcmodes/recordings folder
- There must be other unknown bugs.

How to use

You must have RNPC and Icognito's Streamer plugins in order for this filterscript to work.

Quote:

- Open the Zombeydere.pwn file and compile it in your filterscript folder.
- Add the following line on top of your gamemode's OnPlayerConnect and OnPlayerSpawn callbacks.
Code:
if(IsPlayerNPC(playerid)) return 1;
- Add the following to the filterscript line in your server.cfg file
Code:
Zombeydere
- Modify the line ackslimit in your server.cfg file (if it does not exist, create it)
Code:
ackslimit 4000
- Start your server.

How to configure

Quote:

Open the Zombeydere.pwn file and find the following:

Code:
#define DUMMY_QUANT
#define MAX_ZOMBEY
#define MAX_ZOMBEY_PER_AREA
Although their names can give you a hint, i'll explain what each one of these settings do:

DUMMY_QUANT is the quantity of dummy npcs that will connect to your server before the actual NPCs (zombies). This is made in order to keep player IDs and NPC IDs separated from eachother. Default is 100. There's no limit set but keep the MAX below 400.

MAX_ZOMBEY is the quantity of zombeys that will connect to your server. They connect once the filterscript starts and will be kept in a pool of zombies until called to spawn in a certain zone. Default is 100. There's no limit set but keep the MAX below 400.

MAX_ZOMBEY_PER_AREA is the number of zombeys that will spawn in the areas. Default is 10. There's no limit set but keep the MAX below 20.

Quote:

To add more zones, create a new entry in the ZombeySpawns declaration on top of the filterscript.
Use {X,Y,Z,rotation} (the last is not in use yet though)

Download

Icognito's Streamer: https://sampforum.blast.hk/showthread.php?tid=102865

Mauzen's RNPC: https://sampforum.blast.hk/showthread.php?tid=355849

Zombeydere:
https://github.com/Troydere/Zombeydere
http://pastebin.com/1vjjFYeh
Reply
#2

Good job
Reply
#3

Awesome! +Rep
Reply
#4

It's exactly the same way I use my zombies on Dayz, but I used MapAndreas but they now get on buildings when you are under a building, what a surprise? lol

Good job.
Reply
#5

Very good fs the bugs list is troubling but the features are also good
Quote:

The zombies are killable in every way but by car crash and fire (RPG/grenades)

You mean " but not by car crash or fire? "
Reply
#6

Maybe post a video, so we can see the script in action?
Reply
#7

Quote:
Originally Posted by Freaksken
View Post
Maybe post a video, so we can see the script in action?
Gotcha. I'm not good at all doing videos, though.

https://www.youtube.com/watch?v=5LGANGw7VLs
Reply
#8

Umm help please.
Quote:

[18:11:45] Loading filterscript 'zombies.amx'...
[18:11:45] Error: Function not registered: 'RNPC_AddMovement'
[18:11:45] Error: Function not registered: 'RNPC_FinishBuild'
[18:11:45] Error: Function not registered: 'RNPC_CreateBuild'
[18:11:45] Error: Function not registered: 'RNPC_SetWeaponID'
[18:11:45] Error: Function not registered: 'RNPC_SetSpecialAction'
[18:11:45] Error: Function not registered: 'RNPC_SetAngleQuats'
[18:11:45] Error: Function not registered: 'RNPC_AddPause'
[18:11:45] Error: Function not registered: 'RNPC_SetKeys'
[18:11:45] Loaded 4 filterscripts.

Reply
#9

Quote:
Originally Posted by JaakAmigo
View Post
Umm help please.
Quote:

You must have RNPC and Icognito's Streamer plugins in order for this filterscript to work.

Download the RNPC package from https://sampforum.blast.hk/showthread.php?tid=355849
Reply
#10

Interesting!
Reply
#11

Looks nice, could have a few tweaks and so. But oh well, good job.
Reply
#12

Quote:
Originally Posted by Toroi
View Post
Oh... i thought i had it but i had FCNPC instead.. my bad
Thanks
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)