Graal Forums

Graal Forums (https://forums.graalonline.com/forums/index.php)
-   Tech Support (https://forums.graalonline.com/forums/forumdisplay.php?f=7)
-   -   weapons (https://forums.graalonline.com/forums/showthread.php?t=134266623)

InuKaT 06-11-2012 02:14 AM

weapons
 
For some reason, on the server Dudoria, custom made weapons arent working.
I have
if (playerenters){
toweapons Weapon;
}
if weaponfired {
randomshitgoeshere
}
The weapon sometime works on offline (say, this HUD i have, but when i put it online, it doesnt even transfer to the player)
How do i fix this?

Tricxta 06-11-2012 04:23 AM

You need to be using GS2
To add a weapon to a player through a player entering a level you have to remember to call it serverside.
PHP Code:

function onPlayerenters(){
  
player.addweapon("something");


The through rc you can define your weapon:
PHP Code:

//#CLIENTSIDE
function onWeaponfired(){
  
//do things


I can't remember if onweaponfired() is also called serverside, definately works on the clientside however.


All times are GMT +2. The time now is 12:42 AM.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.