Item random spawn
#1

How to make that The Item Arrmor/HP/Gun can random spawn ?
Reply
#2

https://sampwiki.blast.hk/wiki/CreatePickup
https://sampwiki.blast.hk/wiki/AddStaticPickup
Reply
#3

hmm ye i check but how i can script that ? so i need that the item will random spawn at cords x y z or x y z or x y z etc how to make that ?

EDIT: Atm i just make that the item spawn somewhere but i need random spawns. ...
Reply
#4

Why don't you just make like:
new RND;
RND=random(sizeof(Xcoords));
CreatePickup(model,type,Xcoords[RND],Ycoords[RND],Zcoords[RND]);
Or for smaller sys
new RND
RND=random(TOTALnumberOFrandomOptions)
switch(RND)
{
case 1:CreatePickup(model,type,X,Y,Z);
case 2:CreatePickup(model,type,X,Y,Z);
case 3:CreatePickup(model,type,X,Y,Z);
}
Reply
#5

ow i think i need this one but can u explain this : TOTALofRANDOM... idk what u say lol

edit: this one RND=random(TOTALnumberOFrandomOptions) - TOTALnumberOFrandomOptions
Reply
#6

This is the number of different pickup coords you have.
Reply
#7

look into some other maps how they make random spawns.. lol
Reply
#8

ty i will try
Reply
#9

oh sry fpr dubble post but i forget to ask i should put this udner on player pickup pickup ?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)