i have these pages right:
Classes.php
<?php
class attack
{
function bow()
{
include "/attack_bow.php";
$bow = new bow;
$i = $bow->calc_distance();
return $i;
}
}
?>
attack_bow.php
<?php
class bow
{
function calc_distance()
{
function stuff goes here
return $variable
}
function him()
{
function stuff goes here;
return $variable;
}
}
?>
test.php
<?php include "classes.php"; $h = new attack; $h->bow(); ?>
Now my question is, can i call the him function with like
$h->bow()->$bow->him();
or will i have to add variables.if statements and all that
Thanks Aaron1178

New Topic/Question
Reply




MultiQuote





|