I can’t seem to fix this error with calling this RPC.
The error is : RPC call failed because the function ‘AddjustCurrentHealth’ does not exist in any script attached to’NetworkMaster’
Attack Script
EnemyHealth eh = (EnemyHealth)target.GetComponent("EnemyHealth");
eh.GetComponent<NetworkView>().RPC
("AddjustCurrentHealth", RPCMode.All, meleebase);
EnemyHealth Script
[RPC]
public void AddjustCurrentHealth(int adj){
curHealth -= adj;
if (curHealth < 0)
curHealth = 0;
if (curHealth <= 0) {
Dead ();
}
if (curHealth > maxHealth)
curHealth = maxHealth;
if (maxHealth < 1)
maxHealth = 1;
}