• Log in or sign up for an account here: https://www.sythe.org/login

Help!!!!! (adding objects)

  • Thread starter Thread starter SilverPotato
  • Start date Start date
S

SilverPotato

Guest
OK, my friend and I are trying out making a server, and we wanna add some objects. I know about all the tuts out there but they are no help and look like this one...

=====================================

(Posted by Olan14)
Ok search

Code:
/* OBJECTS MAIN */

. Ok add this void possibly under it if you want to be organized.


Code:
public void makeGlobalObject(int x, int y, int typeID, int orientation, int tileObjectType){ //Makes Global objects
		for (Player p : server.playerHandler.players){
			if(p != null){
				client person = (client)p;
			if((person.playerName != null || person.playerName != "null")){
				if(person.distanceToPoint(x, y) <= 60){
					person.createNewTileObject(x, y, typeID, orientation, tileObjectType);
				}
			}
		}
	}
	}

Ok now add this void under it :

Code:
public void NewObjects() {

Now heres teh base for what you add underneath it


Code:
makeGlobalObjects(x coord,y coord,direction to be facing,height(10 is ground lvl)) //And put maybe a description of it here

Ok... tht should work... Oh and close off the NewObjects void with a


Code:
 }

=====================================

Here is the problem all the red, bolded words are confusing me, It changes like 3 times and I have no idia what it changes to



This kind of tutorial gave us this end result...

Code:
/* OBJECTS MAIN */
public void makeGlobalObject(int x, int y, int typeID, int orientation, int tileObjectType){ //Makes Global objects
		for (Player p : server.playerHandler.players){
			if(p != null){
				client person = (client)p;
			if((person.playerName != null || person.playerName != "null")){
				if(person.distanceToPoint(x, y) <= 60){
					person.createNewTileObject(x, y, typeID, orientation, tileObjectType);
				}
			}
		}
	}
}
	public void NewObjects() {
 	     /* makeGlobalObject(Xcor, Ycor, object#, orientaion, tile/objecttype); */
		     makeGlobalObject(2093, 3225, 2469, 0, 0);//portal
	}

this didn't work! and i did exactly as i read on that tutorial


Please do me a favor post a good tutorial that shows all the parts, and then at the end post what the FULL end result of all this should be

thanks
 
Runescape Gamblingrunescape gambling
Back
Top