Uridium Posted October 20, 2008 Posted October 20, 2008 Ok before i start this is quite complicated coz ive edited quite a few files for this too work. Files that need editing are streets.php attack.php attacktake.php So what does it do well its like the conventional streets or steps what ever you want to call it expect that you can be attacked by NPC's The layout is a 600x600 image grid with 60x60 selectable segments Basically its an image map ;) heres a screen shot Once ive got all my Edits together i will post the scripts on here in a few. The Layout was tested by myself and Colonel which i am greatful for his support :) Quote
toufail Posted October 20, 2008 Posted October 20, 2008 Re: [uPGRADE] V2 streets.php includes image + ability to fight NPCS Wicked weh do we get to test it out :wink: Quote
Uridium Posted October 20, 2008 Author Posted October 20, 2008 Re: [uPGRADE] V2 streets.php includes image + ability to fight NPCS Once ive gathered all the scripts together and seeing as we cant EDIT posts anymore i have to make sure its right first time so theres no need for Edits,,, Quote
Uridium Posted October 20, 2008 Author Posted October 20, 2008 Re: [uPGRADE] V2 streets.php includes image + ability to fight NPCS This will be in Several Edits as its quite large you will have to alter an Inventory items and the NPC id to that of your chosing all so you will need to edit the Descriptive text. Call this file streets.php this file is PART 1 (sections will be joined together) You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. Quote
Uridium Posted October 20, 2008 Author Posted October 20, 2008 Re: [uPGRADE] V2 streets.php includes image + ability to fight NPCS streets.php PART 2 (Joined to PART 1) You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. Quote
Uridium Posted October 20, 2008 Author Posted October 20, 2008 Re: [uPGRADE] V2 streets.php includes image + ability to fight NPCS streets.php PART 3 ( Joined to PART 2 ) You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. Quote
Uridium Posted October 20, 2008 Author Posted October 20, 2008 Re: [uPGRADE] V2 streets.php includes image + ability to fight NPCS streets.php PART 4 ( Joined to PART 3 ) You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. Quote
Uridium Posted October 20, 2008 Author Posted October 20, 2008 Re: [uPGRADE] V2 streets.php includes image + ability to fight NPCS streets.php PART 5 ( Joined to PART 4 ) You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. Quote
Uridium Posted October 20, 2008 Author Posted October 20, 2008 Re: [uPGRADE] V2 streets.php includes image + ability to fight NPCS at the BOTTOM of PART 5 you will need again to ADD PARTS 2,3,4 once youve done that add this to the final part of the streets.php scriipt  You're unable to view this code. Viewing code within this forum requires registration, you can register here for free.  and your Images and also >>> <<< There is an image there its just Transparent Quote
Uridium Posted October 20, 2008 Author Posted October 20, 2008 Re: [uPGRADE] V2 streets.php includes image + ability to fight NPCS Ok regards your attack.php put it in an editor and name it attack3.php make sure your $hosp rand is set to 0,0 as you will need the NPC to be able to stay in the game also you will need to edit the hospital Query so that its zero $db->query("UPDATE users SET hp=0, hospital=hospital=0 on the part that say what do you want to do with this person just make it so users have to leave them You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. Now open attacktake in your editor and rename it attacktake2.php All you need to ammend on here is again setting the hospital time to zero and comment out this line so that the BOT isnt recorded as a challenge You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. and thats it Quote
Decepti0n Posted October 21, 2008 Posted October 21, 2008 Re: [uPGRADE] V2 streets.php includes image + ability to fight NPCS Why don't you use a loop for the grid? Quote
Uridium Posted October 21, 2008 Author Posted October 21, 2008 Re: [uPGRADE] V2 streets.php includes image + ability to fight NPCS Coz too be honest i dont know how to :) so if you could do that. it would be a lot less work for others :) Quote
Colonel Posted October 21, 2008 Posted October 21, 2008 Re: [uPGRADE] V2 streets.php includes image + ability to fight NPCS This is a pretty cool script, I know illusions has spent a long time on it and it works very well! Quote
castle Posted October 21, 2008 Posted October 21, 2008 Re: [uPGRADE] V2 streets.php includes image + ability to fight NPCS looks amazing Quote
avguste Posted October 21, 2008 Posted October 21, 2008 Re: [uPGRADE] V2 streets.php includes image + ability to fight NPCS Looks great. I will attempt to install it and run it. Quote
avguste Posted October 21, 2008 Posted October 21, 2008 Re: [uPGRADE] V2 streets.php includes image + ability to fight NPCS where do I find "$hosp rand" in the attack file at? How about "$db->query("UPDATE users SET hp=0, hospital=hospital=0" Both of those edits are supposed to be in the attack3 file,correct? Also,I just ran the file,without the above edits and I got the following "You dont have enough steps to explore the streets jackass, come back at newday" "You have -1 Left" Quote
Floydian Posted October 21, 2008 Posted October 21, 2008 Re: [uPGRADE] V2 streets.php includes image + ability to fight NPCS You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. Naturally, you would need to modify that to suit your setup. I.e., change the image link, and change the way the click event is handled (i.e., I used a transparent image, wrapped in an A tag linked to a javascript deal. (My search is ajax based, otherwise I would have used a regular link) ) Your styles might need to be edited as well. Quote
avguste Posted October 21, 2008 Posted October 21, 2008 Re: [uPGRADE] V2 streets.php includes image + ability to fight NPCS This gets me even more lost :( Quote
Uridium Posted October 21, 2008 Author Posted October 21, 2008 Re: [uPGRADE] V2 streets.php includes image + ability to fight NPCS You will need the STREETS setup already on your game for this to work the cron that was posted for the streets should update your TURNS each day. You can manually alter your TURNS via your PHPMYADMIN panel under USERS / TURNS Rgerads the Hosp time there is one mention of it in the attack.php and also attacktake.php You will notice on my script the NPCS are set to 666 and 9 this is because on my database 666 and 9 are relevant to user_level 0 which is an NPC so you would need to alter these numbers on your script to correspond to two of your own NPCS that you have ni your game.. Quote
avguste Posted October 21, 2008 Posted October 21, 2008 Re: [uPGRADE] V2 streets.php includes image + ability to fight NPCS Hmm I just checked and the turns have not been updated. Could you please repost the cron job for it?I assume I need to add that to the cron_day file,correct? As far as hosp,I found it in attacktake.php,but for some reason,I don't see it in attack.php What is the exact wording I am looking for? Quote
Uridium Posted October 21, 2008 Author Posted October 21, 2008 Re: [uPGRADE] V2 streets.php includes image + ability to fight NPCS Hmm I just checked and the turns have not been updated. Could you please repost the cron job for it?I assume I need to add that to the cron_day file,correct? As far as hosp,I found it in attacktake.php,but for some reason,I don't see it in attack.php What is the exact wording I am looking for? to loocate the settings for hospital just do your search guery as hosp Regards the Cron for the above open up cron_day.php and add this You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. By the way i also forgot to mention on the streets.php all jail and hospital times are set to 0,0 as i was testing this so you would need to given a random Sentence for each example $db->query("UPDATE users SET hospital=0 WHERE userid=$userid",$c); hospital=0 would need to be changed to the time you want them hospitalised and again for jail times $db->query("UPDATE users SET jail=0 WHERE userid=$userid",$c); Quote
Ishraq Posted October 21, 2008 Posted October 21, 2008 Re: [uPGRADE] V2 streets.php includes image + ability to fight NPCS thanks illusions it works really fine and looks good thanks for helping. UR DA BEST Quote
avguste Posted October 22, 2008 Posted October 22, 2008 Re: [uPGRADE] V2 streets.php includes image + ability to fight NPCS isnt't there supposed to be also an SQL code to run? Quote
avguste Posted October 22, 2008 Posted October 22, 2008 Re: [uPGRADE] V2 streets.php includes image + ability to fight NPCS hmm Stupid question,but this thread is named "upgrade",so I assume there is a version 1 somewhere?correct? Could you please post a link to it? Thanks Quote
radio_active Posted October 22, 2008 Posted October 22, 2008 Re: [uPGRADE] V2 streets.php includes image + ability to fight NPCS You would have to put a query in to reset the NPCs health so lets say you have even 5 people online and they all start vsing the NPC at the same time? I think there would be some problems there? Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.