Redux v2 - Official 5065 Classic Source

03/29/2014 17:35 pro4never#1186
Quote:
Originally Posted by -Zo View Post
Sometimes if i hunt it tells me that a meteor has been dropped but i didn't see one.. what's wrong with that code?=O

Code:
            if (Common.PercentSuccess(DropManager.CHANCE_METEOR))
            {
                var killer = Map.Search<Player>(_killer);
                if (killer != null && killer.Character.LuckyTimeExpires > DateTime.Now)
                {
                    DropItemByID(1088001, _killer);
                    killer.Send(new TalkPacket(ChatType.Whisper, "[LuckyTime] Meteor has been dropped!"));
                }
            }


Is the ground already coated in items?

If so then you're triggering the drop but the item cannot successfully drop on the ground because it's already covered in items.


Not sure if I made DropitemByID a bool but logically it should be (because it can fail).

If so you just need to check if it succeeds before sending the message.
03/29/2014 22:38 Ism3lawy#1187
halos system. any ideas ? :D
03/29/2014 23:04 pro4never#1188
Quote:
Originally Posted by Ism3lawy View Post
halos system. any ideas ? :D
Pretty sure halo effects didn't exist in 5065. If they did then it's no different from new versions and is simply a status effect. If it lets you apply the status effect then good, you're done. If not then you're out of luck.
03/29/2014 23:14 Ism3lawy#1189
Quote:
Originally Posted by pro4never View Post
Pretty sure halo effects didn't exist in 5065. If they did then it's no different from new versions and is simply a status effect. If it lets you apply the status effect then good, you're done. If not then you're out of luck.
umm, thats good. what about rednames/blacknames ,
if you are 400pk points and hit anybody .. flashing blue seccy
and back again to white zD

idk how ... !

another question , rednames drop gears system ?

--------------------------------
dc and 100000 laaaaaaaaag :d

during hunt in birdisland
[Only registered and activated users can see links. Click Here To Register...]
03/30/2014 03:41 InsomniacPro#1190
Quote:
Originally Posted by pro4never View Post
Pretty sure halo effects didn't exist in 5065. If they did then it's no different from new versions and is simply a status effect. If it lets you apply the status effect then good, you're done. If not then you're out of luck.
Not too hard to add some as stateffs actually.
03/30/2014 03:44 Aceking#1191
Quote:
Originally Posted by pro4never View Post
Pretty sure it already supports dynamic maps in this map system. Just need to convert it to load maps from the maps table rather than the game map file (only needed to export the original tinymap compressed resources).

The map table creates a list of mapIDs and links them to dmapIDs for lack of a better term. Standard maps such as twin city in this setup would have the same mapID as dmapID but maps which are duplicates would be be missmatched (just linking map ID used for spawns/portals/commands with the map file)



So yes, just find where the source loads its list of maps to be loaded and convert that to be using the maps table (which is already loaded by the server iirc)
Actually its even easier than that.
There technically already is dynamic map support in there. And there is even a field in the maps table for the dynamic ID.

You just need to change the map object class to take a dynamic ID in the constructor and then load the tinymap files by the dynamic ID.

Quote:
Originally Posted by -Zo View Post
Sometimes if i hunt it tells me that a meteor has been dropped but i didn't see one.. what's wrong with that code?=O

Code:
            if (Common.PercentSuccess(DropManager.CHANCE_METEOR))
            {
                var killer = Map.Search<Player>(_killer);
                if (killer != null && killer.Character.LuckyTimeExpires > DateTime.Now)
                {
                    DropItemByID(1088001, _killer);
                    killer.Send(new TalkPacket(ChatType.Whisper, "[LuckyTime] Meteor has been dropped!"));
                }
            }
That code should work as long as there is a valid location for the item to drop. Might wanna check that
03/30/2014 05:36 InsomniacPro#1192
Quote:
Originally Posted by Ism3lawy View Post
another question , rednames drop gears system ?
Very simple actually. Do a random.next to define how many pieces of equipment can be dropped at most. For example, I do 3.
int Amount = Common.Random.Next(0, 3);

Then, do a for loop for Amount.
Then pick the random item location.
this.Equipment.GetItemBySlot((ItemLocation)Common. Random.Next(0, 8));

Do a null check, to ensure there is in fact an item in the slot.

Then get a valid location for the items to drop, and do checks to ensure the location is valid.

Unequip item from that slot, delete from owners inventory, add it to the ground.

Easy nuff.
03/30/2014 09:38 Ism3lawy#1193
laag + freezing monsters in hunting spots !!
[Only registered and activated users can see links. Click Here To Register...]
03/30/2014 10:20 InsomniacPro#1194
Quote:
Originally Posted by Ism3lawy View Post
laag + freezing monsters in hunting spots !!
[Only registered and activated users can see links. Click Here To Register...]
Ah, is that the problem with the mobs not despawning after being killed?
03/30/2014 12:26 -Zo#1195
Quote:
Originally Posted by Aceking View Post
Actually its even easier than that.
There technically already is dynamic map support in there. And there is even a field in the maps table for the dynamic ID.

You just need to change the map object class to take a dynamic ID in the constructor and then load the tinymap files by the dynamic ID.
i don' t get it :|
03/30/2014 13:47 Ism3lawy#1196
how create new map like tc arena :(

here is codes working 100%
[Only registered and activated users can see links. Click Here To Register...]

sql
[Only registered and activated users can see links. Click Here To Register...]

trying to enter the map and console says no such map with this id 1711 :D

idk how, plz help me zD ~
03/30/2014 15:45 pro4never#1197
Quote:
Originally Posted by InsomniacPro View Post
Not too hard to add some as stateffs actually.
Yes, you could add new stateffs but this project has no intention of supporting newer patch features. He's welcome to add them himself of course just that I don't remember them existing in 5065.
03/30/2014 19:02 XDestroyer2011#1198
How To add a new map ? , and making it Arena Like ! map ?
03/30/2014 19:20 -Zo#1199
Ahh and btw. idk who coded the pkp system but i noticed that pk points don't drop if ur a ghost, but usually they should :)
03/30/2014 20:57 Y u k i#1200
Quote:
Originally Posted by InsomniacPro View Post
Ah, is that the problem with the mobs not despawning after being killed?
Nah its the Native Class. memset / memcpy fucks up after a while... a little later there are stackoverflows @ memcpy. I couldnt track them down when I was fixing specy's source so i recoded the entire class to use managed code instead. Then the sockets also showed some stackoverflows on disconnect.. after we fixed those nhibernate started to cause stackoverflows. That was the day when we shift + del it and used COPSv6 while coding a scratch source.